3 GstStaticCaps rawcaps1 = GST_STATIC_CAPS(
5 "fourcc:fourcc=\"YUYV\", "
8 "framerate:float=30.0; "
10 "fourcc:fourcc=\"I420\", "
13 "framerate:float=30.0"
16 GstStaticCaps rawcaps2 = GST_STATIC_CAPS(
20 GstStaticCaps rawcaps3 = GST_STATIC_CAPS(
21 "video/x-raw-yuv, height=(int) [ 0, MAX ]"
24 GstStaticCaps rawcaps4 = GST_STATIC_CAPS(
25 "video/x-raw-yuv, format=(fourcc)YUY2; video/x-raw-yuv, format=(fourcc)UYVY"
28 GstStaticCaps rawcaps5 = GST_STATIC_CAPS(
29 "video/x-raw-yuv, format=(fourcc)YUY2, framerate=(double)[0,1.79769e+308], width=(int)[0,2147483647], height=(int)[0,2147483647]; video/x-raw-yuv, format=(fourcc)UYVY, framerate=(double)[0,1.79769e+308], width=(int)[0,2147483647], height=(int)[0,2147483647]"
32 GstStaticCaps rawcaps6 = GST_STATIC_CAPS(
33 "video/x-raw-yuv, format=(fourcc)YUY2, width=(int)320, height=(int)240"
36 GstStaticCaps rawcaps7 = GST_STATIC_CAPS(
37 "video/x-raw-yuv, format=(fourcc)YUY2, width=(int)[0,2147483647], height=(int)[0,2147483647], framerate=(double)[0,1.79769e+308]"
40 GstStaticCaps rawcaps8 = GST_STATIC_CAPS(
41 "video/x-raw-yuv, format=(fourcc)YUY2, width=(int)320, height=(int)240"
46 main (int argc, char *argv[])
54 gst_init (&argc, &argv);
56 caps1 = gst_caps_copy( gst_static_caps_get (&rawcaps1));
57 caps2 = gst_caps_new_full (gst_structure_copy ( gst_caps_get_structure (
58 gst_static_caps_get (&rawcaps1), 0)), NULL);
61 gst_caps_set(caps1, "height", GST_PROPS_INT(640));
62 gst_caps_set(caps1, "width", GST_PROPS_INT(480));
63 gst_caps_set(caps1, "framerate", GST_PROPS_FLOAT(30.0));
66 caps = gst_caps_intersect(caps1, caps2);
67 g_print("caps %s\n", gst_caps_to_string(caps));
68 if (gst_caps_is_empty (caps)) return 1;
72 caps1 = gst_caps_copy( gst_static_caps_get (&rawcaps2));
73 caps2 = gst_caps_copy( gst_static_caps_get (&rawcaps3));
74 caps = gst_caps_intersect(caps1, caps2);
75 g_print("caps %s\n", gst_caps_to_string(caps));
76 if (gst_caps_is_empty (caps)) return 1;
80 caps1 = gst_caps_copy( gst_static_caps_get (&rawcaps4));
81 caps2 = gst_caps_copy( gst_static_caps_get (&rawcaps5));
82 caps3 = gst_caps_copy( gst_static_caps_get (&rawcaps6));
83 caps4 = gst_caps_intersect(caps1, caps2);
84 caps = gst_caps_intersect(caps3, caps4);
85 g_print("caps4 %s\n", gst_caps_to_string(caps4));
86 g_print("caps %s\n", gst_caps_to_string(caps));
92 caps1 = gst_caps_copy( gst_static_caps_get (&rawcaps7));
93 caps2 = gst_caps_copy( gst_static_caps_get (&rawcaps8));
94 caps = gst_caps_intersect(caps1, caps2);
95 g_print("caps %s\n", gst_caps_to_string(caps));
96 if (gst_caps_is_empty (caps)) return 1;