Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

📹 Streaming Shared Video Source #86

Open
lauraporta opened this issue Jan 31, 2025 · 2 comments
Open

📹 Streaming Shared Video Source #86

lauraporta opened this issue Jan 31, 2025 · 2 comments

Comments

@lauraporta
Copy link

📹 Streaming Shared Video Source

It would be great to enable video input from a local camera or phone in Hydra. This should be achievable using Hydra’s built-in capabilities.

🔗 Relevant Hydra Docs: External Video Sources


🚧 Current Issues

s0.initCamera()

  • Only allows users to see themselves, which isn't ideal for shared input.

s0.initStream()

  • This would be the best option but currently doesn’t work due to server issues.
  • According to Hydra docs:

    "note: initStream() is currently broken in the Hydra editor due to server issues."


✅ OBS / Twitch Streaming (Temporary Workaround)

Until s0.initStream() is fixed, a functional alternative is using OBS and Twitch.

Requirements:

  • OBS installed
  • A computer connected to a video input (e.g., an iPhone camera via iCloud or a direct cable connection)
  • A single Twitch account (only one is needed for all participants)

Steps:

  1. Set up OBS: Connect it to your video input and streaming service.
  2. Start streaming.
  3. Open the Twitch streaming page and share the link with other participants.
  4. In Nudel Hydra, share the streaming screen via s0.initScreen().
    • ⚠️ For a common visual output, everyone must open the same webpage 😭
  5. Comment out s0.initScreen() to avoid repeated screen-sharing prompts.
  6. Use s0 as the source.

🎯 Goal

This workaround allows multiple users to share the same camera input across devices, but it requires coordination. If we can get s0.initStream() working, we can eliminate the need for OBS and Twitch!

Would love any insights or fixes on getting s0.initStream() back in action. 🚀

@fileneed
Copy link

fileneed commented Feb 1, 2025

Hydra also has a general init() function which can take, among other things, a HTML video element. hydra uses a regl texture to create these sources - so it looks like we could create a hidden video element with the stream and use that as a source, for a somewhat more integrated workaround. Maybe we could even use something like https://meet.jit.si/pastagangcameras as a simple streaming solution.

I found some issues relating to pb() and initStream() in hydra's issues : WebRTC issue on local server #292 WebRTC Deprecated? #286 - those could be of some help in investigating what the "server problem" is. The code seems to live here: patch-bay.

@lauraporta
Copy link
Author

I see, so via init() we could establish a permanent connection to meet.jit.si and have cameras / phones to join there as in any other virtual conference. Don't know yet how to make this happen but seams quicker than fixing initStream() and have a PR merged in hydra repo

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants