How to set GstEncodingProfile for a no container h264 output

qwu16 radjojo at gmail.com
Thu Aug 22 07:10:40 UTC 2019


Hi, i am new to Gstreamer, and we are plan to encode stream from I420 to H264
with no container. I tried following profile setting for encodebin:

GstEncodingProfile *prof;
GstCaps *caps;
caps = gst_caps_new_empty_simple ("video/x-h264");
prof = (GstEncodingProfile*) gst_encoding_video_profile_new (caps, NULL,
NULL, 0);
gst_caps_unref (caps);

g_object_set (encodebin, "profile", prof, NULL);

and then i use following method to request a pad for encodebin:

GstPad *vsinkpad = gst_element_get_request_pad(encode,"video_%u");

an error happened when requesting pad:

 encodebin gstencodebin.c:761:request_pad_for_stream:<encode>^[[00m Couldn't
find a compatible stream profile

I checked gstencodebin.c next_unused_stream_profile, it seems that NULL will
return if encodebin profile is not encoding container profile, so is there
any way to use encodebin to generate non-container stream? If not, any h264
encode plugin recommend for our non-container stream?

Thanks




--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/


More information about the gstreamer-devel mailing list