summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 300e6dc)
raw | patch | inline | side by side (parent: 300e6dc)
author | Jan Schmidt <thaytan@mad.scientist.com> | |
Mon, 28 Jul 2003 13:24:16 +0000 (13:24 +0000) | ||
committer | Jan Schmidt <thaytan@mad.scientist.com> | |
Mon, 28 Jul 2003 13:24:16 +0000 (13:24 +0000) |
Original commit message from CVS:
Merged the 2 video_%02d pad templates, since no plugin should have 2 pad
templates with the same name.
Added caps for the subtitle pad as a quickfix to stop it calling
try_set_caps with NULL caps
Merged the 2 video_%02d pad templates, since no plugin should have 2 pad
templates with the same name.
Added caps for the subtitle pad as a quickfix to stop it calling
try_set_caps with NULL caps
gst/mpegstream/gstmpegdemux.c | patch | blob | history |
index 4ddf3a4b39c91b7ee5125d8b919f9a9aa81b6648..132f8b6d5097ccf9448557855704792118e69692 100644 (file)
)
);
-GST_PAD_TEMPLATE_FACTORY (video_mpeg1_factory,
+GST_PAD_TEMPLATE_FACTORY (video_src_factory,
"video_%02d",
GST_PAD_SRC,
GST_PAD_SOMETIMES,
"video/mpeg",
"mpegversion", GST_PROPS_INT (1),
"systemstream", GST_PROPS_BOOLEAN (FALSE)
- )
-);
-
-GST_PAD_TEMPLATE_FACTORY (video_mpeg2_factory,
- "video_%02d",
- GST_PAD_SRC,
- GST_PAD_SOMETIMES,
+ ),
GST_CAPS_NEW (
"mpeg_demux_video_mpeg2",
"video/mpeg",
"subtitle_stream_%d",
GST_PAD_SRC,
GST_PAD_SOMETIMES,
- NULL /* FIXME! */
+ GST_CAPS_NEW (
+ "mpeg_demux_subtitle",
+ "unknown/unknown",
+ NULL
+ )
);
static void gst_mpeg_demux_class_init (GstMPEGDemuxClass *klass);
/* Video */
name = g_strdup_printf ("video_%02d", stream_id & 0x0F);
outstream = &mpeg_demux->video_stream[stream_id & 0x0F];
- if (!GST_MPEG_PARSE_IS_MPEG2 (mpeg_demux)) {
- newtemp = GST_PAD_TEMPLATE_GET (video_mpeg1_factory);
- } else {
- newtemp = GST_PAD_TEMPLATE_GET (video_mpeg2_factory);
- }
+ newtemp = GST_PAD_TEMPLATE_GET (video_src_factory);
} else {
GST_DEBUG ("unkown stream id %d", stream_id);
}
} else if (id >= 0xE0 && id <= 0xEF) {
/* video */
name = g_strdup_printf ("video_%02d", id - 0xE0);
- newtemp = GST_PAD_TEMPLATE_GET (video_mpeg2_factory);
+ newtemp = GST_PAD_TEMPLATE_GET (video_src_factory);
} else {
/* unkown */
name = g_strdup_printf ("unknown");
gst_element_factory_set_rank (factory, GST_ELEMENT_RANK_PRIMARY);
gst_element_factory_add_pad_template (factory, GST_PAD_TEMPLATE_GET (sink_factory));
- gst_element_factory_add_pad_template (factory, GST_PAD_TEMPLATE_GET (video_mpeg1_factory));
- gst_element_factory_add_pad_template (factory, GST_PAD_TEMPLATE_GET (video_mpeg2_factory));
+ gst_element_factory_add_pad_template (factory, GST_PAD_TEMPLATE_GET (video_src_factory));
gst_element_factory_add_pad_template (factory, GST_PAD_TEMPLATE_GET (private1_factory));
gst_element_factory_add_pad_template (factory, GST_PAD_TEMPLATE_GET (private2_factory));
gst_element_factory_add_pad_template (factory, GST_PAD_TEMPLATE_GET (pcm_factory));