How can I set capabilities on videotestsrc?

Matthew Waters ystreet00 at gmail.com
Fri Jul 31 07:06:36 UTC 2020


Insert a capsfilter element after videotestsrc and set the caps on that
using g_object_set (capsfilter, "caps", caps, NULL);

On 31/7/20 5:05 pm, Psychesnet Hsieh wrote:
> Hi all,
>
> On my PC, I can run "gst-launch-1.0 videotestsrc pattern=1 !
> video/x-raw, width=1920, height=1080 ! autovideosink" to get
> correct result.
> But, if I use C language to write a sample code, not
> using gst_parse_launch, how can I set capabilities for videotestsrc?
> Thanks.
> caps  = gst_caps_new_simple ("video/x-raw",  
>             "width", G_TYPE_INT, 1920,
>              "height", G_TYPE_INT, 1080,
>              "framerate", G_TYPE_INT, 60,
>              NULL);
>
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20200731/79840241/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: OpenPGP digital signature
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20200731/79840241/attachment.sig>


More information about the gstreamer-devel mailing list