Generating YUV test samples with GStreamer
If you need to generate test samples in different YUV formats you can use GStreamer's ffmpegcolorspace plugin like in the following snippet; for instance, in order to get an image in the NV12 raw format you can do:
gst-launch-0.10 -q \ filesrc location=my_image.jpg ! \ decodebin2 ! \ ffmpegcolorspace ! video/x-raw-yuv,format=\(fourcc\)NV12 ! \ filesink location=my_image_NV12.yuv
obviously you can use FFmpeg directly too.
Here is a script attached for me to use in the future.
Attached files:
Comments
Post new comment