alphacolor: More fixes/cleanup

This commit is contained in:
Edward Hervey 2012-01-04 13:26:45 +01:00
parent 4b2a0aba06
commit 63ee1009c2
2 changed files with 5 additions and 25 deletions

View file

@ -122,20 +122,11 @@ gst_alpha_color_transform_caps (GstBaseTransform * btrans,
/* Remove any specific parameter from the structure */
gst_structure_remove_field (structure, "format");
gst_structure_remove_field (structure, "endianness");
gst_structure_remove_field (structure, "depth");
gst_structure_remove_field (structure, "bpp");
gst_structure_remove_field (structure, "red_mask");
gst_structure_remove_field (structure, "green_mask");
gst_structure_remove_field (structure, "blue_mask");
gst_structure_remove_field (structure, "alpha_mask");
gst_structure_remove_field (structure, "color-matrix");
gst_structure_remove_field (structure, "chroma-site");
gst_structure_set_name (structure, "video/x-raw-rgb");
gst_structure_set_name (structure, "video/x-raw");
gst_caps_append_structure (local_caps, gst_structure_copy (structure));
gst_structure_set_name (structure, "video/x-raw-yuv");
gst_caps_append_structure (local_caps, structure);
}
/* Get the appropriate template */

View file

@ -72,16 +72,11 @@ create_caps_rgb24 (void)
{
GstCaps *caps;
caps = gst_caps_new_simple ("video/x-raw-rgb",
caps = gst_caps_new_simple ("video/x-raw",
"width", G_TYPE_INT, 3,
"height", G_TYPE_INT, 4,
"bpp", G_TYPE_INT, 24,
"depth", G_TYPE_INT, 24,
"framerate", GST_TYPE_FRACTION, 0, 1,
"endianness", G_TYPE_INT, G_BIG_ENDIAN,
"red_mask", G_TYPE_INT, 0x00ff0000,
"green_mask", G_TYPE_INT, 0x0000ff00,
"blue_mask", G_TYPE_INT, 0x000000ff, NULL);
"format", G_TYPE_STRING, "RGB", NULL);
return caps;
}
@ -91,17 +86,11 @@ create_caps_rgba32 (void)
{
GstCaps *caps;
caps = gst_caps_new_simple ("video/x-raw-rgb",
caps = gst_caps_new_simple ("video/x-raw",
"width", G_TYPE_INT, 3,
"height", G_TYPE_INT, 4,
"bpp", G_TYPE_INT, 32,
"depth", G_TYPE_INT, 32,
"framerate", GST_TYPE_FRACTION, 0, 1,
"endianness", G_TYPE_INT, G_BIG_ENDIAN,
"red_mask", G_TYPE_INT, 0xff000000,
"green_mask", G_TYPE_INT, 0x00ff0000,
"blue_mask", G_TYPE_INT, 0x0000ff00,
"alpha_mask", G_TYPE_INT, 0x000000ff, NULL);
"format", G_TYPE_STRING, "RGBA", NULL);
return caps;
}