diff --git a/gst/matroska/matroska-demux.c b/gst/matroska/matroska-demux.c index 010a2216c5..aaa60a94dc 100644 --- a/gst/matroska/matroska-demux.c +++ b/gst/matroska/matroska-demux.c @@ -4900,7 +4900,16 @@ gst_matroska_demux_video_caps (GstMatroskaTrackVideoContext * case GST_MAKE_FOURCC ('A', 'Y', 'U', 'V'): format = GST_VIDEO_FORMAT_AYUV; break; - + case GST_MAKE_FOURCC ('Y', '8', '0', '0'): + case GST_MAKE_FOURCC ('Y', '8', ' ', ' '): + format = GST_VIDEO_FORMAT_GRAY8; + break; + case GST_MAKE_FOURCC ('R', 'G', 'B', 24): + format = GST_VIDEO_FORMAT_RGB; + break; + case GST_MAKE_FOURCC ('B', 'G', 'R', 24): + format = GST_VIDEO_FORMAT_BGR; + break; default: GST_DEBUG ("Unknown fourcc %" GST_FOURCC_FORMAT, GST_FOURCC_ARGS (videocontext->fourcc)); diff --git a/gst/matroska/matroska-mux.c b/gst/matroska/matroska-mux.c index 3763cfec19..d0958d1d73 100644 --- a/gst/matroska/matroska-mux.c +++ b/gst/matroska/matroska-mux.c @@ -126,7 +126,7 @@ static GstStaticPadTemplate videosink_templ = "video/x-vp8, " COMMON_VIDEO_CAPS "; " "video/x-raw, " - "format = (string) { YUY2, I420, YV12, UYVY, AYUV }, " + "format = (string) { YUY2, I420, YV12, UYVY, AYUV, GRAY8, BGR, RGB }, " COMMON_VIDEO_CAPS "; " "video/x-wmv, " "wmvversion = (int) [ 1, 3 ], " COMMON_VIDEO_CAPS) ); @@ -1021,6 +1021,12 @@ skip_details: fstr = gst_structure_get_string (structure, "format"); if (fstr && strlen (fstr) == 4) videocontext->fourcc = GST_STR_FOURCC (fstr); + else if (!strcmp (fstr, "GRAY8")) + videocontext->fourcc = GST_MAKE_FOURCC ('Y', '8', '0', '0'); + else if (!strcmp (fstr, "BGR")) + videocontext->fourcc = GST_MAKE_FOURCC ('B', 'G', 'R', 24); + else if (!strcmp (fstr, "RGB")) + videocontext->fourcc = GST_MAKE_FOURCC ('R', 'G', 'B', 24); } else if (!strcmp (mimetype, "video/x-huffyuv") /* MS/VfW compatibility cases */ ||!strcmp (mimetype, "video/x-divx") || !strcmp (mimetype, "video/x-dv")