[pulseaudio-commits] [SCM] PulseAudio Sound Server branch, master, updated. v0.9.19-481-gb5e3076

Lennart Poettering gitmailer-noreply at 0pointer.de
Sun Feb 21 19:57:22 PST 2010


This is an automated email from the git hooks/post-receive script. It was
generated because of a push to the "PulseAudio Sound Server" repository.

The master branch has been updated
      from  250aeceb4d06ce326015d29b688d94e8f71a0cab (commit)

- Log -----------------------------------------------------------------
b5e3076 native: improve logging for buffer_attrs
0555c2e suspend-on-idle: resume audio device even for initially corked streams
-----------------------------------------------------------------------

Summary of changes:
 src/modules/module-suspend-on-idle.c |    8 +++-----
 src/pulsecore/protocol-native.c      |   18 ++++++++++++++++++
 2 files changed, 21 insertions(+), 5 deletions(-)

-----------------------------------------------------------------------

commit 0555c2ec7c33499f4d2816b181db8517cfd42e34
Author: Lennart Poettering <lennart at poettering.net>
Date:   Mon Feb 22 03:22:28 2010 +0100

    suspend-on-idle: resume audio device even for initially corked streams
    
    We need to resume audio devices even for streams that are created in
    corked stat, so that the latency ranges of the audio device are known
    during the initial latency negotiation. If we don't the latency
    negotiation will be based on placeholder data and changed later on which
    clients do not expect.
    
    This should fix issues with Skype.
    
    https://bugzilla.redhat.com/show_bug.cgi?id=554929

diff --git a/src/modules/module-suspend-on-idle.c b/src/modules/module-suspend-on-idle.c
index 7adaa0b..cfb7879 100644
--- a/src/modules/module-suspend-on-idle.c
+++ b/src/modules/module-suspend-on-idle.c
@@ -145,8 +145,9 @@ static pa_hook_result_t sink_input_fixate_hook_cb(pa_core *c, pa_sink_input_new_
     pa_assert(data);
     pa_assert(u);
 
-    if (data->flags & PA_SINK_INPUT_START_CORKED)
-        return PA_HOOK_OK;
+    /* We need to resume the audio device here even for
+     * PA_SINK_INPUT_START_CORKED, since we need the device parameters
+     * to be fully available while the stream is set up. */
 
     if ((d = pa_hashmap_get(u->device_infos, data->sink)))
         resume(d);
@@ -161,9 +162,6 @@ static pa_hook_result_t source_output_fixate_hook_cb(pa_core *c, pa_source_outpu
     pa_assert(data);
     pa_assert(u);
 
-    if (data->flags & PA_SOURCE_OUTPUT_START_CORKED)
-        return PA_HOOK_OK;
-
     if (data->source->monitor_of)
         d = pa_hashmap_get(u->device_infos, data->source->monitor_of);
     else

commit b5e30764c4dc7a764295adb9a75bdb2bba880c5e
Author: Lennart Poettering <lennart at poettering.net>
Date:   Mon Feb 22 03:40:29 2010 +0100

    native: improve logging for buffer_attrs

diff --git a/src/pulsecore/protocol-native.c b/src/pulsecore/protocol-native.c
index ff24612..2721dbe 100644
--- a/src/pulsecore/protocol-native.c
+++ b/src/pulsecore/protocol-native.c
@@ -858,6 +858,18 @@ static void fix_playback_buffer_attr(playback_stream *s) {
 
     pa_assert(s);
 
+    /* pa_log("Client requested: maxlength=%li bytes tlength=%li bytes minreq=%li bytes prebuf=%li bytes", */
+    /*        (long) s->buffer_attr.maxlength, */
+    /*        (long) s->buffer_attr.tlength, */
+    /*        (long) s->buffer_attr.minreq, */
+    /*        (long) s->buffer_attr.prebuf); */
+
+    /* pa_log("Client requested: maxlength=%lu ms tlength=%lu ms minreq=%lu ms prebuf=%lu ms", */
+    /*        (unsigned long) (pa_bytes_to_usec(s->buffer_attr.maxlength, &s->sink_input->sample_spec) / PA_USEC_PER_MSEC), */
+    /*        (unsigned long) (pa_bytes_to_usec(s->buffer_attr.tlength, &s->sink_input->sample_spec) / PA_USEC_PER_MSEC), */
+    /*        (unsigned long) (pa_bytes_to_usec(s->buffer_attr.minreq, &s->sink_input->sample_spec) / PA_USEC_PER_MSEC), */
+    /*        (unsigned long) (pa_bytes_to_usec(s->buffer_attr.prebuf, &s->sink_input->sample_spec) / PA_USEC_PER_MSEC)); */
+
     /* This function will be called from the main thread, before as
      * well as after the sink input has been activated using
      * pa_sink_input_put()! That means it may not touch any
@@ -984,6 +996,12 @@ static void fix_playback_buffer_attr(playback_stream *s) {
     if (s->buffer_attr.prebuf == (uint32_t) -1 ||
         s->buffer_attr.prebuf > max_prebuf)
         s->buffer_attr.prebuf = max_prebuf;
+
+    /* pa_log("Client accepted: maxlength=%lu ms tlength=%lu ms minreq=%lu ms prebuf=%lu ms", */
+    /*        (unsigned long) (pa_bytes_to_usec(s->buffer_attr.maxlength, &s->sink_input->sample_spec) / PA_USEC_PER_MSEC), */
+    /*        (unsigned long) (pa_bytes_to_usec(s->buffer_attr.tlength, &s->sink_input->sample_spec) / PA_USEC_PER_MSEC), */
+    /*        (unsigned long) (pa_bytes_to_usec(s->buffer_attr.minreq, &s->sink_input->sample_spec) / PA_USEC_PER_MSEC), */
+    /*        (unsigned long) (pa_bytes_to_usec(s->buffer_attr.prebuf, &s->sink_input->sample_spec) / PA_USEC_PER_MSEC)); */
 }
 
 /* Called from main context */

-- 
hooks/post-receive
PulseAudio Sound Server



More information about the pulseaudio-commits mailing list