Revert "Remove deprecated use of static mutex in moodbar."
Fixes #4394
This reverts commit 7652e2f780
.
This commit is contained in:
parent
615e8e7614
commit
36f0cde07d
|
@ -221,8 +221,6 @@ gst_fftwspectrum_init (GstFFTWSpectrum * conv,
|
||||||
conv->def_size = DEF_SIZE_DEFAULT;
|
conv->def_size = DEF_SIZE_DEFAULT;
|
||||||
conv->def_step = DEF_STEP_DEFAULT;
|
conv->def_step = DEF_STEP_DEFAULT;
|
||||||
conv->hi_q = HIQUALITY_DEFAULT;
|
conv->hi_q = HIQUALITY_DEFAULT;
|
||||||
|
|
||||||
g_mutex_init(&conv->mutex);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
@ -305,12 +303,13 @@ alloc_fftw_data (GstFFTWSpectrum *conv)
|
||||||
* implementing filters.
|
* implementing filters.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
g_mutex_lock(&conv->mutex);
|
static GStaticMutex mutex = G_STATIC_MUTEX_INIT;
|
||||||
|
g_static_mutex_lock(&mutex);
|
||||||
conv->fftw_plan
|
conv->fftw_plan
|
||||||
= fftw_plan_dft_r2c_1d(conv->size, conv->fftw_in,
|
= fftw_plan_dft_r2c_1d(conv->size, conv->fftw_in,
|
||||||
(fftw_complex *) conv->fftw_out,
|
(fftw_complex *) conv->fftw_out,
|
||||||
conv->hi_q ? FFTW_MEASURE : FFTW_ESTIMATE);
|
conv->hi_q ? FFTW_MEASURE : FFTW_ESTIMATE);
|
||||||
g_mutex_unlock(&conv->mutex);
|
g_static_mutex_unlock(&mutex);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -54,8 +54,6 @@ struct _GstFFTWSpectrum
|
||||||
/* Properties */
|
/* Properties */
|
||||||
gint32 def_size, def_step;
|
gint32 def_size, def_step;
|
||||||
gboolean hi_q;
|
gboolean hi_q;
|
||||||
|
|
||||||
GMutex mutex;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
struct _GstFFTWSpectrumClass
|
struct _GstFFTWSpectrumClass
|
||||||
|
|
Loading…
Reference in New Issue