mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-18 07:47:17 +00:00
controllerized two audio plugins
Original commit message from CVS: reviewed by: <delete if not using a buddy> * docs/libs/tmpl/gstcolorbalance.sgml: * docs/libs/tmpl/gstgconf.sgml: * docs/libs/tmpl/gstmixer.sgml: * docs/libs/tmpl/gstringbuffer.sgml: * gst/sine/gstsinesrc.c: (gst_sinesrc_class_init), (gst_sinesrc_create): * gst/volume/gstvolume.c: (gst_volume_class_init), (volume_transform): controllerized two audio plugins
This commit is contained in:
parent
9fbb72f41d
commit
bef1be2e90
7 changed files with 37 additions and 23 deletions
14
ChangeLog
14
ChangeLog
|
@ -1,3 +1,17 @@
|
|||
2005-08-29 Stefan Kost <ensonic@users.sf.net>
|
||||
|
||||
reviewed by: <delete if not using a buddy>
|
||||
|
||||
* docs/libs/tmpl/gstcolorbalance.sgml:
|
||||
* docs/libs/tmpl/gstgconf.sgml:
|
||||
* docs/libs/tmpl/gstmixer.sgml:
|
||||
* docs/libs/tmpl/gstringbuffer.sgml:
|
||||
* gst/sine/gstsinesrc.c: (gst_sinesrc_class_init),
|
||||
(gst_sinesrc_create):
|
||||
* gst/volume/gstvolume.c: (gst_volume_class_init),
|
||||
(volume_transform):
|
||||
controllerized two audio plugins
|
||||
|
||||
2005-08-29 Andy Wingo <wingo@pobox.com>
|
||||
|
||||
* ext/vorbis/vorbisdec.c (vorbis_dec_convert, vorbis_dec_push)
|
||||
|
|
|
@ -23,15 +23,6 @@ interface for elements that provide color balance operations
|
|||
</para>
|
||||
|
||||
|
||||
<!-- ##### SIGNAL GstColorBalance::value-changed ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@gstcolorbalance: the object which received the signal.
|
||||
@arg1:
|
||||
@arg2:
|
||||
|
||||
<!-- ##### STRUCT GstColorBalanceClass ##### -->
|
||||
<para>
|
||||
|
||||
|
|
|
@ -17,12 +17,3 @@ gconf default elements support
|
|||
<!-- ##### SECTION Stability_Level ##### -->
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gst_gconf_get_string ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@key:
|
||||
@Returns:
|
||||
|
||||
|
||||
|
|
|
@ -41,19 +41,24 @@ gstmixer
|
|||
@set_option:
|
||||
@get_option:
|
||||
@option_changed:
|
||||
@_gst_reserved:
|
||||
|
||||
<!-- ##### STRUCT GstMixerOptions ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@parent:
|
||||
@values:
|
||||
@_gst_reserved:
|
||||
|
||||
<!-- ##### STRUCT GstMixerTrack ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@parent:
|
||||
@label:
|
||||
@flags:
|
||||
|
||||
<!-- ##### FUNCTION gst_mixer_list_tracks ##### -->
|
||||
<para>
|
||||
|
|
|
@ -23,6 +23,7 @@ an implementation of an audio ringbuffer
|
|||
</para>
|
||||
|
||||
@cond:
|
||||
@open:
|
||||
@acquired:
|
||||
@data:
|
||||
@spec:
|
||||
|
@ -40,8 +41,10 @@ an implementation of an audio ringbuffer
|
|||
</para>
|
||||
|
||||
@parent_class:
|
||||
@open_device:
|
||||
@acquire:
|
||||
@release:
|
||||
@close_device:
|
||||
@start:
|
||||
@pause:
|
||||
@resume:
|
||||
|
|
|
@ -24,9 +24,11 @@
|
|||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include <math.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <gst/controller/gst-controller.h>
|
||||
|
||||
#include "gstsinesrc.h"
|
||||
|
||||
|
@ -153,10 +155,10 @@ gst_sinesrc_class_init (GstSineSrcClass * klass)
|
|||
1, G_MAXINT, 1024, G_PARAM_READWRITE));
|
||||
g_object_class_install_property (gobject_class, ARG_FREQ,
|
||||
g_param_spec_double ("freq", "Frequency", "Frequency of sine source",
|
||||
0.0, 20000.0, 440.0, G_PARAM_READWRITE));
|
||||
0.0, 20000.0, 440.0, G_PARAM_READWRITE | GST_PARAM_CONTROLLABLE));
|
||||
g_object_class_install_property (gobject_class, ARG_VOLUME,
|
||||
g_param_spec_double ("volume", "Volume", "Volume",
|
||||
0.0, 1.0, 0.8, G_PARAM_READWRITE));
|
||||
0.0, 1.0, 0.8, G_PARAM_READWRITE | GST_PARAM_CONTROLLABLE));
|
||||
g_object_class_install_property (gobject_class, ARG_SYNC,
|
||||
g_param_spec_boolean ("sync", "Sync", "Synchronize to clock",
|
||||
FALSE, G_PARAM_READWRITE));
|
||||
|
@ -344,6 +346,8 @@ gst_sinesrc_create (GstBaseSrc * basesrc, guint64 offset,
|
|||
GST_BUFFER_OFFSET_END (buf) = src->offset + src->samples_per_buffer;
|
||||
GST_BUFFER_DURATION (buf) = tdiff;
|
||||
|
||||
gst_object_sink_values (G_OBJECT (src), src->timestamp);
|
||||
|
||||
samples = (gint16 *) GST_BUFFER_DATA (buf);
|
||||
|
||||
src->timestamp += tdiff;
|
||||
|
|
|
@ -30,6 +30,8 @@
|
|||
#include <gst/base/gstbasetransform.h>
|
||||
#include <gst/audio/audio.h>
|
||||
#include <gst/interfaces/mixer.h>
|
||||
#include <gst/controller/gst-controller.h>
|
||||
|
||||
#include "gstvolume.h"
|
||||
|
||||
/* some defines for audio processing */
|
||||
|
@ -266,11 +268,13 @@ gst_volume_class_init (GstVolumeClass * klass)
|
|||
gobject_class->dispose = gst_volume_dispose;
|
||||
|
||||
g_object_class_install_property (G_OBJECT_CLASS (klass), PROP_MUTE,
|
||||
g_param_spec_boolean ("mute", "mute", "mute", FALSE, G_PARAM_READWRITE));
|
||||
g_param_spec_boolean ("mute", "mute", "mute",
|
||||
FALSE, G_PARAM_READWRITE | GST_PARAM_CONTROLLABLE));
|
||||
|
||||
g_object_class_install_property (G_OBJECT_CLASS (klass), PROP_VOLUME,
|
||||
g_param_spec_double ("volume", "volume", "volume",
|
||||
0.0, VOLUME_MAX_DOUBLE, 1.0, G_PARAM_READWRITE));
|
||||
0.0, VOLUME_MAX_DOUBLE, 1.0,
|
||||
G_PARAM_READWRITE | GST_PARAM_CONTROLLABLE));
|
||||
|
||||
GST_BASE_TRANSFORM_CLASS (klass)->transform =
|
||||
GST_DEBUG_FUNCPTR (volume_transform);
|
||||
|
@ -391,6 +395,8 @@ volume_transform (GstBaseTransform * base, GstBuffer * inbuf,
|
|||
{
|
||||
GstVolume *this = GST_VOLUME (base);
|
||||
|
||||
gst_object_sink_values (G_OBJECT (this), GST_BUFFER_TIMESTAMP (outbuf));
|
||||
|
||||
this->process (this, GST_BUFFER_TIMESTAMP (outbuf),
|
||||
GST_BUFFER_DATA (outbuf), GST_BUFFER_SIZE (outbuf));
|
||||
|
||||
|
|
Loading…
Reference in a new issue