[vlc-commits] audiounit_ios: remove ca_Flush hack

Thomas Guillem git at videolan.org
Tue Dec 12 15:17:13 CET 2017


vlc/vlc-3.0 | branch: master | Thomas Guillem <thomas at gllm.fr> | Tue Dec 12 13:01:35 2017 +0100| [c814ad098eae8afb68eedb93c10f99c6c6f270f9] | committer: Thomas Guillem

audiounit_ios: remove ca_Flush hack

Since ca_Flush() can now works when paused.

NB: Normally, ca_Flush() can't be called when paused by VLC but this module do
a pause in order to mute, and the paused state can now be set from the
interrupt notification.

(cherry picked from commit c7e8e84b6475081aa07a79ae5bcaa0806a3f7031)
Signed-off-by: Thomas Guillem <thomas at gllm.fr>

> http://git.videolan.org/gitweb.cgi/vlc/vlc-3.0.git/?a=commit;h=c814ad098eae8afb68eedb93c10f99c6c6f270f9
---

 modules/audio_output/audiounit_ios.m | 10 +---------
 1 file changed, 1 insertion(+), 9 deletions(-)

diff --git a/modules/audio_output/audiounit_ios.m b/modules/audio_output/audiounit_ios.m
index c87f3572b9..7421ecf6c6 100644
--- a/modules/audio_output/audiounit_ios.m
+++ b/modules/audio_output/audiounit_ios.m
@@ -350,15 +350,7 @@ Flush(audio_output_t *p_aout, bool wait)
 {
     struct aout_sys_t * p_sys = p_aout->sys;
 
-    if (!p_sys->b_paused)
-        ca_Flush(p_aout, wait);
-    else
-    {
-        /* ca_Flush() can't work while paused since the AudioUnit is Stopped
-         * and the render callback won't be called. But it's safe to clear the
-         * circular buffer from this thread since AU is stopped. */
-        TPCircularBufferClear(&p_sys->c.circular_buffer);
-    }
+    ca_Flush(p_aout, wait);
 }
 
 static int



More information about the vlc-commits mailing list