Encoding H264 from appsrc example

I am trying to encode video

The input frame is from appsrc (format RGB) → encoding h264 → send over udp

I have working code that I can see on client on GSTREMAER BUT when I try to open it on VLC it doe not work

When I try to use videotestsrc as the src element I can see the video with VLC

  1. Is working code example how to push frames and send them as encoding video as udp?
  2. What can be the difference between videotestsrc and my appsrc?

Thanks

Eli

Hi Eli,
h264 encoder only supports NV12 or I420 input.
A post for reference:
[url]https://devtalk.nvidia.com/default/topic/1026106/jetson-tx1/usage-of-nvbuffer-apis/post/5219225/#5219225[/url]

Hi

My pipeline include convert between the appsrc and the encoder
The pipeline that I use jave the following elements:

appsrc->capfilter->videoconvert->omxh264enc->capsfilter->h264parse->rtph264pay->udpsink

So I assume that even if my appsrc is RGB format, the videoconvert will change the format so it will be appropriate to the h264 encoder

Eli

Hi Eli,
Please refer to
[url]https://devtalk.nvidia.com/default/topic/1026106/jetson-tx1/usage-of-nvbuffer-apis/post/5219225/#5219225[/url]

and check if the saved video file can be played.