mirror of https://code.videolan.org/videolan/vlc
aout: rename back drain_async to drain
Now that the legacy implementation is gone.
This commit is contained in:
parent
193ab0d027
commit
6c93cb0f04
|
@ -245,7 +245,7 @@ struct audio_output
|
|||
* \note This callback cannot be called in stopped state.
|
||||
*/
|
||||
|
||||
void (*drain_async)(audio_output_t *);
|
||||
void (*drain)(audio_output_t *);
|
||||
/**< Drain the playback buffers asynchronously (can be NULL).
|
||||
*
|
||||
* A drain operation can be cancelled by aout->flush() or aout->stop().
|
||||
|
|
|
@ -862,7 +862,7 @@ static int Open(vlc_object_t *obj)
|
|||
aout->time_get = TimeGet;
|
||||
aout->play = Play;
|
||||
aout->flush = Flush;
|
||||
aout->drain_async = Drain;
|
||||
aout->drain = Drain;
|
||||
|
||||
return VLC_SUCCESS;
|
||||
error:
|
||||
|
|
|
@ -376,7 +376,7 @@ static int Open (vlc_object_t *obj)
|
|||
aout->play = Play;
|
||||
aout->pause = Pause;
|
||||
aout->flush = Flush;
|
||||
aout->drain_async = sys->drain ? Drain : NULL;
|
||||
aout->drain = sys->drain ? Drain : NULL;
|
||||
if (sys->set_volume != NULL)
|
||||
{
|
||||
aout->volume_set = VolumeSet;
|
||||
|
|
|
@ -1076,7 +1076,7 @@ static int Open(vlc_object_t *obj)
|
|||
aout->play = Play;
|
||||
aout->pause = Pause;
|
||||
aout->flush = Flush;
|
||||
aout->drain_async = Drain;
|
||||
aout->drain = Drain;
|
||||
aout->volume_set = VolumeSet;
|
||||
aout->mute_set = MuteSet;
|
||||
aout->device_select = StreamMove;
|
||||
|
|
|
@ -178,7 +178,7 @@ static int Start( audio_output_t *p_aout, audio_sample_format_t *restrict fmt )
|
|||
p_aout->play = Play;
|
||||
p_aout->pause = WaveOutPause;
|
||||
p_aout->flush = WaveOutFlush;
|
||||
p_aout->drain_async = WaveOutDrainAsync;
|
||||
p_aout->drain = WaveOutDrainAsync;
|
||||
|
||||
aout_sys_t *sys = p_aout->sys;
|
||||
|
||||
|
|
|
@ -971,7 +971,7 @@ static int OpenAudio(vlc_object_t *p_this)
|
|||
aout->play = PlayAudio;
|
||||
aout->start = Start;
|
||||
aout->flush = Flush;
|
||||
aout->drain_async = Drain;
|
||||
aout->drain = Drain;
|
||||
aout->time_get = TimeGet;
|
||||
|
||||
aout->pause = aout_PauseDefault;
|
||||
|
|
|
@ -587,7 +587,7 @@ bool aout_DecIsDrained(audio_output_t *aout)
|
|||
{
|
||||
aout_owner_t *owner = aout_owner (aout);
|
||||
|
||||
if (aout->drain_async == NULL)
|
||||
if (aout->drain == NULL)
|
||||
{
|
||||
vlc_tick_t drain_deadline =
|
||||
atomic_load_explicit(&owner->drain_deadline, memory_order_relaxed);
|
||||
|
@ -612,11 +612,11 @@ void aout_DecDrain(audio_output_t *aout)
|
|||
aout->play(aout, block, vlc_tick_now());
|
||||
}
|
||||
|
||||
if (aout->drain_async)
|
||||
if (aout->drain)
|
||||
{
|
||||
assert(!atomic_load_explicit(&owner->drained, memory_order_relaxed));
|
||||
|
||||
aout->drain_async(aout);
|
||||
aout->drain(aout);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue