I have a Jetson TX2 and am using Gstreamer to capture frames from my camera. I want to stream this via rtsp and receive it on another computer, for example with vlc.
I want to enter an URL into vlc and then see my stream. I got it working with an sdp file but want to use only an url that works without an sdp file.
I looked into it and found something called gst-rtsp-server. I installed it according to this stackoverflow comment:
the example works flawlessly. I can start it with:
./test-launch "( videotestsrc ! x264enc ! rtph264pay name=pay0 pt=96 )"
And then i can see it via vlc, even on an ipad where you can’t even open sdp files.
But i am having trouble using this with my existing setup. I have a cpp file where i already have a pipeline and a mainloop that feeds frames into it. I can’t do that in commandline arguments as they did with the ‘test-launch’ example.
Is there a way where i can do the following?
// ... g_streamer_pipeline_string = ("appsrc ! video/x-raw, format=BGR ! queue ! videoconvert ! video/x-raw, format=BGRx ! nvvidconv \ ! nvv4l2h264enc bitrate=1600000 maxperf-enable=1 \ ! MAGIC_SINK", 0, 40, cv::Size (width, height)); // ...
and then use this with the example of gst-rtsp-server:
./test-launch "( MAGIC_SOURCE ! rtph264pay name=pay0 pt=96 )"
Where MAGIC_SOURCE and MAGIC_SINK are the magic glue i need to connect the two Gstreamer pipes. Basically i want my cpp code to stream into some sort of sink that i can pick up with another pipe in another process.
Is that possible ?