[vlc-commits] auhal: don't apply dev latency two times
Thomas Guillem
git at videolan.org
Tue Jul 16 12:09:27 CEST 2019
vlc/vlc-3.0 | branch: master | Thomas Guillem <thomas at gllm.fr> | Tue Jul 16 09:33:11 2019 +0200| [753fd23a64b36167dd1d7a672d9565000d9ad72b] | committer: Thomas Guillem
auhal: don't apply dev latency two times
It is already handled by the render callback on macOS.
(cherry picked from commit bd6e2265a551ec27632285a08efd70a3018b4bd7)
Signed-off-by: Thomas Guillem <thomas at gllm.fr>
> http://git.videolan.org/gitweb.cgi/vlc/vlc-3.0.git/?a=commit;h=753fd23a64b36167dd1d7a672d9565000d9ad72b
---
modules/audio_output/auhal.c | 14 ++++++--------
1 file changed, 6 insertions(+), 8 deletions(-)
diff --git a/modules/audio_output/auhal.c b/modules/audio_output/auhal.c
index d662fde326..4c8886a8c4 100644
--- a/modules/audio_output/auhal.c
+++ b/modules/audio_output/auhal.c
@@ -1064,8 +1064,7 @@ WarnConfiguration(audio_output_t *p_aout)
* StartAnalog: open and setup a HAL AudioUnit to do PCM audio output
*/
static int
-StartAnalog(audio_output_t *p_aout, audio_sample_format_t *fmt,
- mtime_t i_latency_us)
+StartAnalog(audio_output_t *p_aout, audio_sample_format_t *fmt)
{
struct aout_sys_t *p_sys = p_aout->sys;
OSStatus err = noErr;
@@ -1119,7 +1118,7 @@ StartAnalog(audio_output_t *p_aout, audio_sample_format_t *fmt,
/* Do the last VLC aout setups */
bool warn_configuration;
- int ret = au_Initialize(p_aout, p_sys->au_unit, fmt, layout, i_latency_us,
+ int ret = au_Initialize(p_aout, p_sys->au_unit, fmt, layout, 0,
&warn_configuration);
if (ret != VLC_SUCCESS)
goto error;
@@ -1152,8 +1151,7 @@ error:
* StartSPDIF: Setup an encoded digital stream (SPDIF) output
*/
static int
-StartSPDIF(audio_output_t * p_aout, audio_sample_format_t *fmt,
- mtime_t i_latency_us)
+StartSPDIF(audio_output_t * p_aout, audio_sample_format_t *fmt)
{
struct aout_sys_t *p_sys = p_aout->sys;
int ret;
@@ -1394,7 +1392,7 @@ StartSPDIF(audio_output_t * p_aout, audio_sample_format_t *fmt,
return VLC_EGENERIC;
}
- ret = ca_Initialize(p_aout, fmt, i_latency_us);
+ ret = ca_Initialize(p_aout, fmt, 0);
if (ret != VLC_SUCCESS)
{
AudioDeviceDestroyIOProcID(p_sys->i_selected_dev, p_sys->i_procID);
@@ -1620,7 +1618,7 @@ Start(audio_output_t *p_aout, audio_sample_format_t *restrict fmt)
/* Check for Digital mode or Analog output mode */
if (do_spdif)
{
- if (StartSPDIF (p_aout, fmt, i_latency_us) == VLC_SUCCESS)
+ if (StartSPDIF(p_aout, fmt) == VLC_SUCCESS)
{
msg_Dbg(p_aout, "digital output successfully opened");
return VLC_SUCCESS;
@@ -1628,7 +1626,7 @@ Start(audio_output_t *p_aout, audio_sample_format_t *restrict fmt)
}
else
{
- if (StartAnalog(p_aout, fmt, i_latency_us) == VLC_SUCCESS)
+ if (StartAnalog(p_aout, fmt) == VLC_SUCCESS)
{
msg_Dbg(p_aout, "analog output successfully opened");
fmt->channel_type = AUDIO_CHANNEL_TYPE_BITMAP;
More information about the vlc-commits
mailing list