Commit a29e55f9 authored by Sebastian Dröge's avatar Sebastian Dröge

video: Fix creation of grayscale caps

The endianness was not set correctly before.

Fixes bug #646923.
parent e2844552
......@@ -707,14 +707,14 @@ gst_video_format_new_caps_raw (GstVideoFormat format)
break;
}
if (bpp > 8) {
if (bpp <= 8) {
caps = gst_caps_new_simple ("video/x-raw-gray",
"bpp", G_TYPE_INT, bpp, "depth", G_TYPE_INT, depth, NULL);
} else {
caps = gst_caps_new_simple ("video/x-raw-gray",
"bpp", G_TYPE_INT, bpp,
"depth", G_TYPE_INT, depth,
"endianness", G_TYPE_INT, G_BIG_ENDIAN, NULL);
"endianness", G_TYPE_INT, endianness, NULL);
}
return caps;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment