diff options
author | Sebastian Dröge <slomo@circular-chaos.org> | 2008-08-18 15:05:32 +0000 |
---|---|---|
committer | Sebastian Dröge <slomo@circular-chaos.org> | 2008-08-18 15:05:32 +0000 |
commit | cfc5ea685a0b487fab4cea62eeea90aa9e58e0e0 (patch) | |
tree | c8d2bef9faa31bdd267386a8fc04b6c699e40e3e /ext/pulse/pulsesrc.c | |
parent | 25665a0df3ccad07a6867eb3d231d6e580393b99 (diff) |
ext/pulse/: The bytes_per_sample and silence_sample fields of the GstRingBufferSpec are already filled with the corre...
Original commit message from CVS:
* ext/pulse/pulsesink.c: (gst_pulsesink_prepare):
* ext/pulse/pulsesrc.c: (gst_pulsesrc_prepare):
The bytes_per_sample and silence_sample fields of the GstRingBufferSpec
are already filled with the correct values by
gst_ring_buffer_parse_caps() so there's no need to set them again
with wrong values.
Diffstat (limited to 'ext/pulse/pulsesrc.c')
-rw-r--r-- | ext/pulse/pulsesrc.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/ext/pulse/pulsesrc.c b/ext/pulse/pulsesrc.c index 59d2c24d..9302ca3a 100644 --- a/ext/pulse/pulsesrc.c +++ b/ext/pulse/pulsesrc.c @@ -509,8 +509,9 @@ gst_pulsesrc_prepare (GstAudioSrc * asrc, GstRingBufferSpec * spec) if (!pulsesrc->context || pa_context_get_state (pulsesrc->context) != PA_CONTEXT_READY) { GST_ELEMENT_ERROR (pulsesrc, RESOURCE, FAILED, ("Bad context state: %s", - pulsesrc->context ? pa_strerror (pa_context_errno (pulsesrc-> - context)) : NULL), (NULL)); + pulsesrc-> + context ? pa_strerror (pa_context_errno (pulsesrc->context)) : + NULL), (NULL)); goto unlock_and_fail; } @@ -554,9 +555,6 @@ gst_pulsesrc_prepare (GstAudioSrc * asrc, GstRingBufferSpec * spec) pa_threaded_mainloop_unlock (pulsesrc->mainloop); - spec->bytes_per_sample = pa_frame_size (&pulsesrc->sample_spec); - memset (spec->silence_sample, 0, spec->bytes_per_sample); - return TRUE; unlock_and_fail: |