From: Wim Taymans Date: Mon, 9 May 2011 13:37:46 +0000 (+0200) Subject: visual: use CAPS event to configure caps X-Git-Tag: 1.19.3~511^2~7694 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=62536eaa6e1bfa4466fa5fc29310e7487190dca4;p=platform%2Fupstream%2Fgstreamer.git visual: use CAPS event to configure caps --- diff --git a/docs/plugins/gst-plugins-base-plugins.hierarchy b/docs/plugins/gst-plugins-base-plugins.hierarchy index a49dbfe..d28dd63 100644 --- a/docs/plugins/gst-plugins-base-plugins.hierarchy +++ b/docs/plugins/gst-plugins-base-plugins.hierarchy @@ -1,114 +1,119 @@ GObject - GstObject - GstPad - GstPadTemplate - GstPluginFeature - GstElementFactory - GstTypeFindFactory - GstIndexFactory - GstElement - GstBin - GstPipeline - GstPlayBaseBin - GstPlayBin - GstPlayBin2 - GstDecodeBin2 - GstURIDecodeBin - GstDecodeBin - GstPlaySink - GstSubtitleOverlay - GstEncodeBin - GstVorbisEnc - GstVorbisDec - GstVorbisParse - GstVorbisTag - GstVisual - GstVisualjess - GstVisualbumpscope - GstVisualcorona - GstVisualinfinite - GstVisualjakdaw - GstVisuallv_analyzer - GstVisuallv_scope - GstVisualoinksie - GstBaseSrc - GstPushSrc - GstCddaBaseSrc - GstCdParanoiaSrc - GstBaseAudioSrc - GstAudioSrc - GstAlsaSrc - GstVideoTestSrc - GstTCPClientSrc - GstTCPServerSrc - GstGioBaseSrc - GstGioSrc - GstGioStreamSrc - GstGnomeVFSSrc - GstAppSrc - GstAudioTestSrc - GstBaseSink - GstGioBaseSink - GstGioSink - GstGioStreamSink - GstBaseAudioSink - GstAudioSink - GstAlsaSink - GstGnomeVFSSink - GstVideoSink - GstXImageSink - GstXvImageSink - GstAppSink - GstTCPClientSink - GstMultiFdSink - GstTCPServerSink - GstTextOverlay - GstTimeOverlay - GstClockOverlay - GstTextRender - GstAlsaMixerElement - GstTheoraDec - GstTheoraEnc - GstTheoraParse - GstOggDemux - GstOggMux - GstOgmParse - GstOgmAudioParse - GstOgmVideoParse - GstOgmTextParse - GstOggParse - GstOggAviParse - GstAdder - GstBaseTransform - GstVideoFilter - GstVideoScale - GstFFMpegCsp - GstAudioFilter - GstVolume - GstAudioConvert - GstAudioResample - GstVideoRate - GstStreamSelector - GstGDPDepay - GstGDPPay - GstSubParse - GstSsaParse - GstAudioRate - GstBus - GstTask - GstTaskPool - GstClock - GstSystemClock - GstAudioClock - GstPlugin - GstRegistry - GstRingBuffer - GstAudioSrcRingBuffer - GstAudioSinkRingBuffer - GstSignalObject + GInitiallyUnowned + GstObject + GstPad + GstPadTemplate + GstPluginFeature + GstElementFactory + GstTypeFindFactory + GstIndexFactory + GstElement + GstBin + GstPipeline + GstPlayBaseBin + GstPlayBin + GstPlayBin2 + GstEncodeBin + GstDecodeBin + GstPlaySink + GstSubtitleOverlay + GstDecodeBin2 + GstURIDecodeBin + GstVisual + GstVisualjess + GstVisualbumpscope + GstVisualcorona + GstVisualinfinite + GstVisualjakdaw + GstVisuallv_analyzer + GstVisuallv_scope + GstVisualoinksie + GstBaseSrc + GstGnomeVFSSrc + GstGioBaseSrc + GstGioSrc + GstGioStreamSrc + GstPushSrc + GstCddaBaseSrc + GstCdParanoiaSrc + GstBaseAudioSrc + GstAudioSrc + GstAlsaSrc + GstV4lElement + GstV4lSrc + GstVideoTestSrc + GstTCPClientSrc + GstTCPServerSrc + GstAppSrc + GstAudioTestSrc + GstBaseSink + GstGnomeVFSSink + GstGioBaseSink + GstGioSink + GstGioStreamSink + GstBaseAudioSink + GstAudioSink + GstAlsaSink + GstVideoSink + GstXvImageSink + GstXImageSink + GstAppSink + GstTCPClientSink + GstMultiFdSink + GstTCPServerSink + GstTheoraDec + GstTheoraEnc + GstTheoraParse + GstBaseTextOverlay + GstTextOverlay + GstTimeOverlay + GstClockOverlay + GstTextRender + GstOggDemux + GstOggMux + GstOgmParse + GstOgmAudioParse + GstOgmVideoParse + GstOgmTextParse + GstOggParse + GstOggAviParse + GstVorbisEnc + GstVorbisDec + GstVorbisParse + GstVorbisTag + GstAlsaMixerElement + GstSubParse + GstSsaParse + GstBaseTransform + GstAudioFilter + GstVolume + GstVideoFilter + GstVideoScale + GstFFMpegCsp + GstAudioResample + GstAudioConvert + GstGDPDepay + GstGDPPay + GstAudioRate + GstAdder + GstVideoRate + GstStreamSelector + GstBus + GstTask + GstTaskPool + GstClock + GstSystemClock + GstAudioClock + GstPlugin + GstRegistry + GstRingBuffer + GstAudioSrcRingBuffer + GstAudioSinkRingBuffer GstMixerTrack - GstMixerOptions GstStreamInfo + GstEncodingProfile + GstTunerNorm + GstTunerChannel GstColorBalanceChannel PangoFontMap PangoFcFontMap @@ -120,14 +125,15 @@ GInterface GTypePlugin GstChildProxy GstURIHandler - GstTagSetter GstPreset + GstTagSetter GstImplementsInterface GstMixer GstPropertyProbe GstNavigation GstXOverlay GstColorBalance + GstTuner GstStreamVolume PangoCairoFontMap GFile diff --git a/docs/plugins/gst-plugins-base-plugins.interfaces b/docs/plugins/gst-plugins-base-plugins.interfaces index 772e582..4b602b1 100644 --- a/docs/plugins/gst-plugins-base-plugins.interfaces +++ b/docs/plugins/gst-plugins-base-plugins.interfaces @@ -3,28 +3,30 @@ GstPipeline GstChildProxy GstPlayBaseBin GstChildProxy GstPlayBin GstChildProxy GstPlayBin2 GstChildProxy GstStreamVolume -GstDecodeBin2 GstChildProxy -GstURIDecodeBin GstChildProxy +GstEncodeBin GstChildProxy GstDecodeBin GstChildProxy GstPlaySink GstChildProxy GstSubtitleOverlay GstChildProxy -GstEncodeBin GstChildProxy -GstVorbisEnc GstTagSetter GstPreset -GstVorbisTag GstTagSetter +GstDecodeBin2 GstChildProxy +GstURIDecodeBin GstChildProxy +GstGnomeVFSSrc GstURIHandler +GstGioSrc GstURIHandler GstCddaBaseSrc GstURIHandler GstCdParanoiaSrc GstURIHandler GstAlsaSrc GstImplementsInterface GstMixer GstPropertyProbe -GstGioSrc GstURIHandler -GstGnomeVFSSrc GstURIHandler +GstV4lElement GstImplementsInterface GstTuner GstXOverlay GstColorBalance GstPropertyProbe +GstV4lSrc GstImplementsInterface GstTuner GstXOverlay GstColorBalance GstPropertyProbe GstAppSrc GstURIHandler +GstGnomeVFSSink GstURIHandler GstGioSink GstURIHandler GstAlsaSink GstPropertyProbe -GstGnomeVFSSink GstURIHandler -GstXImageSink GstImplementsInterface GstNavigation GstXOverlay GstXvImageSink GstImplementsInterface GstNavigation GstXOverlay GstColorBalance GstPropertyProbe +GstXImageSink GstImplementsInterface GstNavigation GstXOverlay GstAppSink GstURIHandler -GstAlsaMixerElement GstImplementsInterface GstMixer GstPropertyProbe GstTheoraEnc GstPreset GstOggMux GstPreset +GstVorbisEnc GstTagSetter GstPreset +GstVorbisTag GstTagSetter +GstAlsaMixerElement GstImplementsInterface GstMixer GstPropertyProbe GstVolume GstImplementsInterface GstMixer GstStreamVolume PangoCairoFcFontMap PangoCairoFontMap diff --git a/docs/plugins/gst-plugins-base-plugins.prerequisites b/docs/plugins/gst-plugins-base-plugins.prerequisites index e81698c..176f319 100644 --- a/docs/plugins/gst-plugins-base-plugins.prerequisites +++ b/docs/plugins/gst-plugins-base-plugins.prerequisites @@ -4,6 +4,7 @@ GstImplementsInterface GstElement GstMixer GstImplementsInterface GstElement GstXOverlay GstImplementsInterface GstElement GstColorBalance GstImplementsInterface GstElement +GstTuner GstImplementsInterface GstElement GstStreamVolume GObject PangoCairoFontMap PangoFontMap GFile GObject diff --git a/ext/libvisual/visual.c b/ext/libvisual/visual.c index 45a09fb..8eb1115 100644 --- a/ext/libvisual/visual.c +++ b/ext/libvisual/visual.c @@ -215,7 +215,6 @@ gst_visual_init (GstVisual * visual) { /* create the sink and src pads */ visual->sinkpad = gst_pad_new_from_static_template (&sink_template, "sink"); - gst_pad_set_setcaps_function (visual->sinkpad, gst_visual_sink_setcaps); gst_pad_set_chain_function (visual->sinkpad, gst_visual_chain); gst_pad_set_event_function (visual->sinkpad, gst_visual_sink_event); gst_element_add_pad (GST_ELEMENT (visual), visual->sinkpad); @@ -395,7 +394,7 @@ gst_vis_src_negotiate (GstVisual * visual) GstStructure *structure; GstCaps *caps; GstQuery *query; - GstBufferPool *pool; + GstBufferPool *pool = NULL; guint size, min, max, prefix, alignment; caps = gst_pad_get_caps (visual->srcpad); @@ -492,6 +491,14 @@ gst_visual_sink_event (GstPad * pad, GstEvent * event) gst_visual_reset (visual); res = gst_pad_push_event (visual->srcpad, event); break; + case GST_EVENT_CAPS: + { + GstCaps *caps; + + gst_event_parse_caps (event, &caps); + res = gst_visual_sink_setcaps (pad, caps); + break; + } case GST_EVENT_NEWSEGMENT: { GstFormat format; @@ -514,7 +521,7 @@ gst_visual_sink_event (GstPad * pad, GstEvent * event) break; } default: - res = gst_pad_push_event (visual->srcpad, event); + res = gst_pad_event_default (visual->srcpad, event); break; }