mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-20 08:41:07 +00:00
ffmpegcolorspace: video/x-raw-gray is the same as the YUV Y800 format
This commit is contained in:
parent
96b9ec4da0
commit
77bc4ff763
1 changed files with 11 additions and 1 deletions
|
@ -362,10 +362,17 @@ gst_ffmpeg_pixfmt_to_caps (enum PixelFormat pix_fmt, AVCodecContext * context)
|
|||
case PIX_FMT_AYUV4444:
|
||||
fmt = GST_MAKE_FOURCC ('A', 'Y', 'U', 'V');
|
||||
break;
|
||||
case PIX_FMT_GRAY8:
|
||||
case PIX_FMT_GRAY8:{
|
||||
GstCaps *tmp;
|
||||
|
||||
bpp = depth = 8;
|
||||
caps = gst_ff_vid_caps_new (context, "video/x-raw-gray",
|
||||
"bpp", G_TYPE_INT, bpp, "depth", G_TYPE_INT, depth, NULL);
|
||||
tmp = gst_ff_vid_caps_new (context, "video/x-raw-yuv",
|
||||
"format", GST_TYPE_FOURCC, GST_MAKE_FOURCC ('Y', '8', '0', '0'),
|
||||
NULL);
|
||||
gst_caps_append (caps, tmp);
|
||||
}
|
||||
break;
|
||||
default:
|
||||
/* give up ... */
|
||||
|
@ -632,6 +639,9 @@ gst_ffmpeg_caps_to_pixfmt (const GstCaps * caps,
|
|||
case GST_MAKE_FOURCC ('Y', '4', '4', '4'):
|
||||
context->pix_fmt = PIX_FMT_YUV444P;
|
||||
break;
|
||||
case GST_MAKE_FOURCC ('Y', '8', '0', '0'):
|
||||
context->pix_fmt = PIX_FMT_GRAY8;
|
||||
break;
|
||||
}
|
||||
}
|
||||
} else if (gst_structure_has_name (structure, "video/x-raw-rgb")) {
|
||||
|
|
Loading…
Reference in a new issue