summaryrefslogtreecommitdiffstats
path: root/ext/raw1394/gstdv1394src.c
diff options
context:
space:
mode:
authorJan Schmidt <thaytan@mad.scientist.com>2004-05-07 16:17:25 +0000
committerJan Schmidt <thaytan@mad.scientist.com>2004-05-07 16:17:25 +0000
commite9d760851b7902d955720288b8cc300e07f37d2c (patch)
tree3a5139e7e8723e8f190dc3c7186ba9b207398c9c /ext/raw1394/gstdv1394src.c
parent69127d320cca53e3ca4d31fcba0ac30989df03a6 (diff)
ext/dv/gstdvdec.c: Fix caps nego and pad templates. RGB mode caps should work now.
Original commit message from CVS: * ext/dv/gstdvdec.c: (gst_dvdec_video_link): Fix caps nego and pad templates. RGB mode caps should work now. * ext/dvdnav/gst-dvd: Move mpeg2dec inside the thread because otherwise the queue rejects cap changes mid-stream * ext/mpeg2dec/gstmpeg2dec.c: (gst_mpeg2dec_get_type), (gst_mpeg2dec_flush_decoder): For mpeg2dec > 0.4.0, call the flush function instead of manually extracting all in-flight frames. * ext/raw1394/gstdv1394src.c: (gst_dv1394src_factory), (gst_dv1394src_init), (gst_dv1394src_iso_receive): Change mime type video/dv go video/x-dv to match the rest of gst-plugins
Diffstat (limited to 'ext/raw1394/gstdv1394src.c')
-rw-r--r--ext/raw1394/gstdv1394src.c15
1 files changed, 8 insertions, 7 deletions
diff --git a/ext/raw1394/gstdv1394src.c b/ext/raw1394/gstdv1394src.c
index fcc93729..be9de56e 100644
--- a/ext/raw1394/gstdv1394src.c
+++ b/ext/raw1394/gstdv1394src.c
@@ -63,7 +63,7 @@ gst_dv1394src_factory (void)
GST_PAD_SRC,
GST_PAD_ALWAYS,
GST_STATIC_CAPS ("dv1394src",
- "video/dv",
+ "video/x-dv",
gst_props_new ("format", GST_PROPS_LIST (G_TYPE_STRING ("NTSC"),
G_TYPE_STRING ("PAL")
), NULL)
@@ -156,6 +156,7 @@ gst_dv1394src_init (GstDV1394Src * dv1394src)
{
dv1394src->srcpad = gst_pad_new ("src", GST_PAD_SRC);
gst_pad_set_get_function (dv1394src->srcpad, gst_dv1394src_get);
+ gst_pad_use_explicit_caps (dv1394src->srcpad);
gst_element_add_pad (GST_ELEMENT (dv1394src), dv1394src->srcpad);
dv1394src->card = 0;
@@ -252,9 +253,9 @@ gst_dv1394src_iso_receive (raw1394handle_t handle, int channel, size_t len,
// PAL
dv1394src->frameSize = PAL_FRAMESIZE;
GST_DEBUG ("PAL data");
- if (gst_pad_try_set_caps (dv1394src->srcpad,
- gst_caps_new_simple ("video/dv",
- "format", G_TYPE_STRING, "PAL", NULL)) <= 0) {
+ if (!gst_pad_set_explicit_caps (dv1394src->srcpad,
+ gst_caps_new_simple ("video/x-dv",
+ "format", G_TYPE_STRING, "PAL", NULL))) {
GST_ELEMENT_ERROR (dv1394src, CORE, NEGOTIATION, (NULL),
("Could not set source caps for PAL"));
return 0;
@@ -264,9 +265,9 @@ gst_dv1394src_iso_receive (raw1394handle_t handle, int channel, size_t len,
dv1394src->frameSize = NTSC_FRAMESIZE;
GST_DEBUG
("NTSC data [untested] - please report success/failure to <dan@f3c.com>");
- if (gst_pad_try_set_caps (dv1394src->srcpad,
- gst_caps_new_simple ("video/dv", "format", G_TYPE_STRING,
- "NTSC", NULL)) <= 0) {
+ if (!gst_pad_set_explicit_caps (dv1394src->srcpad,
+ gst_caps_new_simple ("video/x-dv", "format", G_TYPE_STRING,
+ "NTSC", NULL))) {
GST_ELEMENT_ERROR (dv1394src, CORE, NEGOTIATION, (NULL),
("Could not set source caps for NTSC"));
return 0;