[vlc-devel] [PATCH 1/2] aout: send the preferred period delay to modules
Steve Lhomme
robux4 at ycbcr.xyz
Mon Feb 11 08:00:42 CET 2019
On 08/02/2019 08:09, Thomas Guillem wrote:
> ---
> include/vlc_aout.h | 10 +++++++++-
> modules/audio_output/adummy.c | 5 +++--
> modules/audio_output/alsa.c | 4 +++-
> modules/audio_output/amem.c | 4 +++-
> modules/audio_output/audiotrack.c | 6 ++++--
> modules/audio_output/audiounit_ios.m | 4 +++-
> modules/audio_output/auhal.c | 4 +++-
> modules/audio_output/directsound.c | 3 ++-
> modules/audio_output/file.c | 4 +++-
> modules/audio_output/jack.c | 4 +++-
> modules/audio_output/kai.c | 3 ++-
> modules/audio_output/mmdevice.c | 4 +++-
> modules/audio_output/opensles_android.c | 4 +++-
> modules/audio_output/oss.c | 4 +++-
> modules/audio_output/pulse.c | 4 +++-
> modules/audio_output/sndio.c | 3 ++-
> modules/audio_output/tizen_audio.c | 4 +++-
> modules/audio_output/waveout.c | 4 +++-
> modules/audio_output/winstore.c | 4 +++-
> modules/video_output/decklink.cpp | 4 +++-
> src/audio_output/output.c | 3 ++-
> 21 files changed, 66 insertions(+), 23 deletions(-)
>
> diff --git a/include/vlc_aout.h b/include/vlc_aout.h
> index 11209ee0ce..59f930221f 100644
> --- a/include/vlc_aout.h
> +++ b/include/vlc_aout.h
> @@ -140,7 +140,8 @@ struct audio_output
>
> void *sys; /**< Private data for callbacks */
>
> - int (*start)(audio_output_t *, audio_sample_format_t *fmt);
> + int (*start)(audio_output_t *, audio_sample_format_t *fmt,
> + vlc_tick_t *period_hint);
> /**< Starts a new stream (mandatory, cannot be NULL).
> *
> * This callback changes the audio output from stopped to playing state
> @@ -149,6 +150,13 @@ struct audio_output
> *
> * \param fmt input stream sample format upon entry,
> * output stream sample format upon return [IN/OUT]
> + *
> + * \param period_hint wanted period by the core. This value can be
> + * overwritten by the implementation if it's not possible to configure
> + * such period. A period corresponds to the amount of time the audio
> + * server will wait until the buffer is free enough to request more data
> + * [IN/OUT]
>
So far you don't handle the OUT case in pulse audio. Will there be cases
where it is used ? And if so the issue should probably be checked on the
aout->start() call.
More information about the vlc-devel
mailing list