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

Receiver functionality (sometimes-SrcPad) #5

Open
tuxuser opened this issue Oct 30, 2022 · 2 comments
Open

Receiver functionality (sometimes-SrcPad) #5

tuxuser opened this issue Oct 30, 2022 · 2 comments
Assignees
Labels
enhancement New feature or request

Comments

@tuxuser
Copy link
Contributor

tuxuser commented Oct 30, 2022

Hello

As mentioned in PR #4, I would like to use WebRtcRedux for a client implementation that receives video streams and pushes the rtp packets onto a Gst-Pipeline for further processing.

The WebRtcRedux element currently implements the "Sink"-pad. To accomodate the targeted flow, the GstPushSrc's sometimes-pad "src_%u" which exposes the incoming streams, would need to be implemented.

From my understanding, a GstPushSrc would be appropriate, as we are talking about a live-stream here.

Here is my attempt at doing so: tuxuser@282b8e7 (having issues with lifetimes and code-design here (the burden of every new rust dev I guess :P))

Maybe to reproduce better, I implemented the desired output API by creating a vp8-client.
Its basically a clone of the h264-browser example:

  • Takes the webcam/microphone stream from the browser and adds it to the PeerConnection
  • Takes the SDP offer from CLI and generates its answer
  • Answer is pasted back into the CLI and stream starts

Code is located here: https://github.com/tuxuser/gst-webrtcredux/tree/example/vp8_client/examples/vp8-client

Any help is ofc greatly appreciated :)

@ImTheSquid ImTheSquid self-assigned this Oct 30, 2022
@ImTheSquid ImTheSquid added the enhancement New feature or request label Oct 30, 2022
@ImTheSquid
Copy link
Owner

I think it's a good idea to add this functionality and you're on the right track, but there definitely needs to be some more work done on the code. From my cursory first look, the source pad template should split into audio and video to be consistent with the sink pad template, and the fill function needs to be implemented.

@ImTheSquid
Copy link
Owner

If you want you can take a look at my X11 capture plugin, it uses the same type of stuff with a complete implementation.

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

No branches or pull requests

2 participants