mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-26 11:41:09 +00:00
Add caps list test that shows incorrect behavior
Original commit message from CVS: Add caps list test that shows incorrect behavior
This commit is contained in:
parent
90dc6ded4d
commit
0d48f56c8f
2 changed files with 60 additions and 0 deletions
|
@ -86,6 +86,33 @@ GST_CAPS_FACTORY (rawcaps5,
|
|||
);
|
||||
*/
|
||||
|
||||
GST_CAPS_FACTORY(rawcaps6,
|
||||
GST_CAPS_NEW (
|
||||
"videotestsrc_src",
|
||||
"video/raw",
|
||||
"format", GST_PROPS_FOURCC(GST_MAKE_FOURCC('I','4','2','0'))
|
||||
),
|
||||
GST_CAPS_NEW (
|
||||
"videotestsrc_src",
|
||||
"video/raw",
|
||||
"format", GST_PROPS_FOURCC(GST_MAKE_FOURCC('Y','U','Y','V'))
|
||||
)
|
||||
)
|
||||
|
||||
GST_CAPS_FACTORY(rawcaps7,
|
||||
GST_CAPS_NEW (
|
||||
"xvideosink_sink",
|
||||
"video/raw",
|
||||
"format", GST_PROPS_FOURCC(GST_MAKE_FOURCC('I','4','2','0'))
|
||||
),
|
||||
GST_CAPS_NEW (
|
||||
"xvideosink_sink",
|
||||
"video/raw",
|
||||
"format", GST_PROPS_FOURCC(GST_MAKE_FOURCC('Y','V','1','2'))
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
int
|
||||
main (int argc, char *argv[])
|
||||
{
|
||||
|
@ -120,5 +147,8 @@ main (int argc, char *argv[])
|
|||
testret = gst_caps_is_always_compatible (GST_CAPS_GET (rawcaps), GST_CAPS_GET (rawcaps));
|
||||
g_print ("2 <-> 2 == %d (valid, same caps)\n", testret);
|
||||
|
||||
testret = gst_caps_is_always_compatible (GST_CAPS_GET (rawcaps6), GST_CAPS_GET (rawcaps7));
|
||||
g_print ("6 <-> 7 == %d (invalid, second caps doesn't fit)\n", testret);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
|
@ -86,6 +86,33 @@ GST_CAPS_FACTORY (rawcaps5,
|
|||
);
|
||||
*/
|
||||
|
||||
GST_CAPS_FACTORY(rawcaps6,
|
||||
GST_CAPS_NEW (
|
||||
"videotestsrc_src",
|
||||
"video/raw",
|
||||
"format", GST_PROPS_FOURCC(GST_MAKE_FOURCC('I','4','2','0'))
|
||||
),
|
||||
GST_CAPS_NEW (
|
||||
"videotestsrc_src",
|
||||
"video/raw",
|
||||
"format", GST_PROPS_FOURCC(GST_MAKE_FOURCC('Y','U','Y','V'))
|
||||
)
|
||||
)
|
||||
|
||||
GST_CAPS_FACTORY(rawcaps7,
|
||||
GST_CAPS_NEW (
|
||||
"xvideosink_sink",
|
||||
"video/raw",
|
||||
"format", GST_PROPS_FOURCC(GST_MAKE_FOURCC('I','4','2','0'))
|
||||
),
|
||||
GST_CAPS_NEW (
|
||||
"xvideosink_sink",
|
||||
"video/raw",
|
||||
"format", GST_PROPS_FOURCC(GST_MAKE_FOURCC('Y','V','1','2'))
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
int
|
||||
main (int argc, char *argv[])
|
||||
{
|
||||
|
@ -120,5 +147,8 @@ main (int argc, char *argv[])
|
|||
testret = gst_caps_is_always_compatible (GST_CAPS_GET (rawcaps), GST_CAPS_GET (rawcaps));
|
||||
g_print ("2 <-> 2 == %d (valid, same caps)\n", testret);
|
||||
|
||||
testret = gst_caps_is_always_compatible (GST_CAPS_GET (rawcaps6), GST_CAPS_GET (rawcaps7));
|
||||
g_print ("6 <-> 7 == %d (invalid, second caps doesn't fit)\n", testret);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue