From: Sebastian Dröge Date: Thu, 10 Sep 2009 14:55:31 +0000 (+0200) Subject: playbin(2): Document that the volume property uses a linear scale X-Git-Tag: 1.19.3~511^2~9202 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=662a31983f21a8c52f4dce8f817c06349b2ba1cc;p=platform%2Fupstream%2Fgstreamer.git playbin(2): Document that the volume property uses a linear scale Fixes bug #571610. --- diff --git a/gst/playback/gstplaybin.c b/gst/playback/gstplaybin.c index 7d25392..298f9e5 100644 --- a/gst/playback/gstplaybin.c +++ b/gst/playback/gstplaybin.c @@ -394,6 +394,13 @@ gst_play_bin_class_init (GstPlayBinClass * klass) g_param_spec_object ("vis-plugin", "Vis plugin", "the visualization element to use (NULL = none)", GST_TYPE_ELEMENT, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS)); + /** + * GstPlayBin:volume: + * + * Get or set the current audio stream volume. 1.0 means 100%, + * 0.0 means mute. This uses a linear volume scale. + * + */ g_object_class_install_property (gobject_klass, ARG_VOLUME, g_param_spec_double ("volume", "volume", "volume", 0.0, VOLUME_MAX_DOUBLE, 1.0, @@ -522,8 +529,8 @@ gst_play_bin_vis_blocked (GstPad * tee_pad, gboolean blocked, } vis_bin = - GST_BIN_CAST (gst_object_get_parent (GST_OBJECT_CAST (play_bin-> - visualisation))); + GST_BIN_CAST (gst_object_get_parent (GST_OBJECT_CAST + (play_bin->visualisation))); if (!GST_IS_BIN (vis_bin) || !GST_IS_PAD (tee_pad)) { goto beach; @@ -665,8 +672,8 @@ gst_play_bin_set_property (GObject * object, guint prop_id, GstBin *vis_bin = NULL; vis_bin = - GST_BIN_CAST (gst_object_get_parent (GST_OBJECT_CAST (play_bin-> - visualisation))); + GST_BIN_CAST (gst_object_get_parent (GST_OBJECT_CAST + (play_bin->visualisation))); /* Check if the visualisation is already in a bin */ if (GST_IS_BIN (vis_bin)) { diff --git a/gst/playback/gstplaybin2.c b/gst/playback/gstplaybin2.c index 02619ad..e6843bd 100644 --- a/gst/playback/gstplaybin2.c +++ b/gst/playback/gstplaybin2.c @@ -728,6 +728,13 @@ gst_play_bin_class_init (GstPlayBinClass * klass) "the subpicture output element to use (NULL = default dvdspu)", GST_TYPE_ELEMENT, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS)); + /** + * GstPlayBin2:volume: + * + * Get or set the current audio stream volume. 1.0 means 100%, + * 0.0 means mute. This uses a linear volume scale. + * + */ g_object_class_install_property (gobject_klass, PROP_VOLUME, g_param_spec_double ("volume", "Volume", "The audio volume, 1.0=100%", 0.0, VOLUME_MAX_DOUBLE, 1.0,