diff --git a/ChangeLog b/ChangeLog index 7fa009aa40..299f5a94d4 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2005-01-15 Gergely Nagy + + Reviewed by: Ronald S. Bultje + + * gst/ffmpegcolorspace/gstffmpegcodecmap.c: + (gst_ffmpeg_caps_to_pixfmt): + Fix for depth = 15. Fixes #161675. + 2005-01-14 Ronald S. Bultje * sys/v4l/gstv4lsrc.c: (gst_v4lsrc_getcaps): diff --git a/gst/ffmpegcolorspace/gstffmpegcodecmap.c b/gst/ffmpegcolorspace/gstffmpegcodecmap.c index 84909cf915..1a16cfb6a2 100644 --- a/gst/ffmpegcolorspace/gstffmpegcodecmap.c +++ b/gst/ffmpegcolorspace/gstffmpegcodecmap.c @@ -482,7 +482,7 @@ gst_ffmpeg_caps_to_pixfmt (const GstCaps * caps, } } else if (strcmp (gst_structure_get_name (structure), "video/x-raw-rgb") == 0) { - gint bpp = 0, rmask = 0, endianness = 0, amask = 0; + gint bpp = 0, rmask = 0, endianness = 0, amask = 0, depth = 0; if (gst_structure_get_int (structure, "bpp", &bpp) && gst_structure_get_int (structure, "endianness", &endianness)) { @@ -514,8 +514,13 @@ gst_ffmpeg_caps_to_pixfmt (const GstCaps * caps, context->pix_fmt = PIX_FMT_RGB24; break; case 16: - if (endianness == G_BYTE_ORDER) + if (endianness == G_BYTE_ORDER) { context->pix_fmt = PIX_FMT_RGB565; + if (gst_structure_get_int (structure, "depth", &depth)) { + if (depth == 15) + context->pix_fmt = PIX_FMT_RGB555; + } + } break; case 15: if (endianness == G_BYTE_ORDER)