diff options
author | Stefan Kost <ensonic@users.sourceforge.net> | 2006-09-11 18:23:59 +0000 |
---|---|---|
committer | Stefan Kost <ensonic@users.sourceforge.net> | 2006-09-11 18:23:59 +0000 |
commit | 22ebcc3091b84f0082581ee30a944da993fc5bc7 (patch) | |
tree | 1ecef1dc51f584259501d1f47eaef33a9643b2b5 | |
parent | ba185a300cbab71930ca38ad8877c91589f400e9 (diff) | |
download | gst-plugins-bad-22ebcc3091b84f0082581ee30a944da993fc5bc7.tar.gz gst-plugins-bad-22ebcc3091b84f0082581ee30a944da993fc5bc7.tar.bz2 gst-plugins-bad-22ebcc3091b84f0082581ee30a944da993fc5bc7.zip |
gst/spectrum/gstspectrum.*: Fix type mixup in spectrum->interval (gdouble<->guint64). Spotted by
Original commit message from CVS:
* gst/spectrum/gstspectrum.c: (gst_spectrum_init),
(gst_spectrum_set_property):
* gst/spectrum/gstspectrum.h:
Fix type mixup in spectrum->interval (gdouble<->guint64). Spotted by
René Stadler
-rw-r--r-- | ChangeLog | 8 | ||||
-rw-r--r-- | gst/spectrum/gstspectrum.c | 3 | ||||
-rw-r--r-- | gst/spectrum/gstspectrum.h | 2 |
3 files changed, 11 insertions, 2 deletions
@@ -1,5 +1,13 @@ 2006-09-11 Stefan Kost <ensonic@users.sf.net> + * gst/spectrum/gstspectrum.c: (gst_spectrum_init), + (gst_spectrum_set_property): + * gst/spectrum/gstspectrum.h: + Fix type mixup in spectrum->interval (gdouble<->guint64). Spotted by + René Stadler + +2006-09-11 Stefan Kost <ensonic@users.sf.net> + * gst/spectrum/demo-osssrc.c: (draw_spectrum), (main): Use more defines diff --git a/gst/spectrum/gstspectrum.c b/gst/spectrum/gstspectrum.c index d03024de..ae3645bb 100644 --- a/gst/spectrum/gstspectrum.c +++ b/gst/spectrum/gstspectrum.c @@ -208,6 +208,7 @@ gst_spectrum_init (GstSpectrum * spectrum, GstSpectrumClass * g_class) spectrum->adapter = gst_adapter_new (); + spectrum->interval = GST_SECOND / 10; spectrum->bands = 128; spectrum->base = 9; spectrum->len = 1024; /* 2 ^ (base+1) */ @@ -252,7 +253,7 @@ gst_spectrum_set_property (GObject * object, guint prop_id, filter->message = g_value_get_boolean (value); break; case PROP_SIGNAL_INTERVAL: - filter->interval = gst_guint64_to_gdouble (g_value_get_uint64 (value)); + filter->interval = g_value_get_uint64 (value); break; case PROP_BANDS: filter->bands = g_value_get_uint (value); diff --git a/gst/spectrum/gstspectrum.h b/gst/spectrum/gstspectrum.h index 0092f0ba..3bfdd489 100644 --- a/gst/spectrum/gstspectrum.h +++ b/gst/spectrum/gstspectrum.h @@ -48,7 +48,7 @@ struct _GstSpectrum { /* properties */ gboolean message; /* whether or not to post messages */ - gdouble interval; /* how many seconds between emits */ + guint64 interval; /* how many seconds between emits */ guint bands; /* number of spectrum bands */ gint threshold; /* energy level treshold */ |