ionorg / ion-sdk-go

ion sdk for golang
MIT License
55 stars 46 forks source link

Gstreamer send example #43

Closed TannerGabriel closed 3 years ago

TannerGabriel commented 3 years ago

Description

Gstreamer-send is a simple application that shows how to send a video or audio stream to your ion-sfu using ion-sdk-go and GStreamer.

alexchern commented 3 years ago

Very useful sample, exactly what I needed (as a beginner). Question. I'm using transcoding pipeling ( udp to webrtc ) and a video quality is very low. How can I control the video bitrate?

Thanks,

Alex

leewardbound commented 3 years ago

Looks great @TannerGabriel, thanks for the contribution :)

TannerGabriel commented 3 years ago

@alexchern, I'm glad the example helped you out. I'm also still facing problems with the quality of the stream but currently do not have the time to go deeper into GStreamer settings to improve the quality. I think it will be best to merge the PR at this point and continue to update the example later once I have more time.

Also, if you find anything to improve, feel free to tell me or make a contribution yourself.

alexchern commented 3 years ago

Thanks for your response. I think it is not a Gstreamer settings, as its pipeline produces an uncompressed frames that later pushed to vp8 encoder, so the only quality related parameter is video resolution ( I tried to add a scaler to see if it changes something). Also, when I use a video test source, the quality is acceptable. This is because there is not much motion there and vp8 encoder can squeeze the video into low bitrate stream. So, I'm pretty sure the problem is a video bitrate, but I could not find a way to set it for vp8 encoder. I would love to contribute, but unfortunately I'm very new to golang, Gstreamer and webrtc :-) . I do have a good understanding of digital video, but it doesn't really help me here :-(

Thanks,

Alex

TannerGabriel commented 3 years ago

@alexchern Yes, that sounds logical. I will try to improve the script once I find the time to do so. If you require further help, I would recommend joining the pion Slack community, which is quite active. There are also a few people with a lot of GStreamer experience.