[pulseaudio-commits] r1488 - /branches/lennart/src/modules/module-null-sink.c

svnmailer-noreply at 0pointer.de svnmailer-noreply at 0pointer.de
Sat Jun 23 13:03:01 PDT 2007


Author: lennart
Date: Sat Jun 23 22:03:00 2007
New Revision: 1488

URL: http://0pointer.de/cgi-bin/viewcvs.cgi?rev=3D1488&root=3Dpulseaudio&vi=
ew=3Drev
Log:
drop silence generation from sink drivers

Modified:
    branches/lennart/src/modules/module-null-sink.c

Modified: branches/lennart/src/modules/module-null-sink.c
URL: http://0pointer.de/cgi-bin/viewcvs.cgi/branches/lennart/src/modules/mo=
dule-null-sink.c?rev=3D1488&root=3Dpulseaudio&r1=3D1487&r2=3D1488&view=3Ddi=
ff
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D
--- branches/lennart/src/modules/module-null-sink.c (original)
+++ branches/lennart/src/modules/module-null-sink.c Sat Jun 23 22:03:00 2007
@@ -140,7 +140,7 @@
                 pa_asyncmsgq_done(u->asyncmsgq, 0);
                 goto finish;
             }
-                    =

+
             ret =3D pa_asyncmsgq_dispatch(object, code, data, &chunk);
             pa_asyncmsgq_done(u->asyncmsgq, ret);
             continue;
@@ -151,15 +151,11 @@
             pa_gettimeofday(&now);
 =

             if (pa_timeval_cmp(&u->timestamp, &now) <=3D 0) {
-                size_t l;
-
-                if (pa_sink_render(u->sink, u->block_size, &chunk) >=3D 0)=
 {
-                    l =3D chunk.length;
-                    pa_memblock_unref(chunk.memblock);
-                } else
-                    l =3D u->block_size;
-
-                pa_timeval_add(&u->timestamp, pa_bytes_to_usec(l, &u->sink=
->sample_spec));
+
+                pa_sink_render(u->sink, u->block_size, &chunk);
+                pa_memblock_unref(chunk.memblock);
+
+                pa_timeval_add(&u->timestamp, pa_bytes_to_usec(chunk.lengt=
h, &u->sink->sample_spec));
                 continue;
             }
 =





More information about the pulseaudio-commits mailing list