1
votes

I am new to GStreamer following is the issue I am facing

Pipeline 1

v4l2src device=/dev/video241 ! video/x-h264,height=720,width=1280,framerate=30/1 ! tvcameradmx name=demux demux.video_0 ! queue ! omx_h264dec ! xvimagesink

Pipeline 2

appsrc ! video/x-h264,height=720,width=1280,framerate=30/1 ! avimux ! filesink

I want to attach appsrc to the queue of pipeline 1

For this I am using appsrc in push mode.

  1. I have created a callback for "need-data" signal
  2. This callback is triggered when pipeline 2 goes from paused to playing state
  3. Now to push queue buffer I have to use gst_app_src_push_buffer.

My question is how can I retrieve the buffers from the queue ????

1
Do you still want the data to go through and be displayed to the xvimagesink? If so, you will need a Tee as just grabbing buffers from the queue will keep them from being sent down the line to the xvimagesinkBenjamin Trent

1 Answers

2
votes

If you're trying to go from v4l2, to a file sink and X, you'll want to use a tee, as JPS indicates. The pipeline would become something along these lines:

v4l2src device=/dev/video241 ! video/x-h264,height=720,width=1280,framerate=30/1 ! tvcameradmx name=demux demux.video_0 ! tee name=t ! queue ! omx_h264dec ! xvimagesink t. ! queue ! avimux ! filesink location=...

After creating a tee and naming it ("t" in this case), you can reference it again in the pipeline by appending "." after it. It then becomes a sort of new source element.