0
0
mirror of https://github.com/mpv-player/mpv.git synced 2024-09-20 12:02:23 +02:00
mpv/audio/out
wm4 e56d8a200d Replace all calls to GetTimer()/GetTimerMS()
GetTimer() is generally replaced with mp_time_us(). Both calls return
microseconds, but the latter uses int64_t, us defined to never wrap,
and never returns 0 or negative values.

GetTimerMS() has no direct replacement. Instead the other functions are
used.

For some code, switch to mp_time_sec(), which returns the time as double
float value in seconds. The returned time is offset to program start
time, so there is enough precision left to deliver microsecond
resolution for at least 100 years. Unless it's casted to a float
(or the CPU reduces precision), which is why we still use mp_time_us()
out of paranoia in places where precision is clearly needed.

Always switch to the correct time. The whole point of the new timer
calls is that they don't wrap, and storing microseconds in unsigned int
variables would negate this.

In some cases, remove wrap-around handling for time values.
2013-05-26 16:44:20 +02:00
..
ao_alsa.c ao_alsa: always unset ALSA error handler, cleanup on init error 2013-05-26 16:44:18 +02:00
ao_coreaudio.c ao_coreaudio: fix switched parameters 2013-05-12 22:00:32 +02:00
ao_dsound.c audio/out: channel map selection 2013-05-12 21:24:57 +02:00
ao_jack.c Replace all calls to GetTimer()/GetTimerMS() 2013-05-26 16:44:20 +02:00
ao_lavc.c Merge branch 'audio_changes' 2013-05-12 21:47:55 +02:00
ao_null.c Replace all calls to GetTimer()/GetTimerMS() 2013-05-26 16:44:20 +02:00
ao_openal.c audio/out: channel map selection 2013-05-12 21:24:57 +02:00
ao_oss.c audio/out: channel map selection 2013-05-12 21:24:57 +02:00
ao_pcm.c audio/out: channel map selection 2013-05-12 21:24:57 +02:00
ao_portaudio.c audio/out: channel map selection 2013-05-12 21:24:57 +02:00
ao_pulse.c audio/out: channel map selection 2013-05-12 21:24:57 +02:00
ao_rsound.c audio/out: channel map selection 2013-05-12 21:24:57 +02:00
ao_sdl.c Replace all calls to GetTimer()/GetTimerMS() 2013-05-26 16:44:20 +02:00
ao.c audio: add channel map selection function 2013-05-12 21:24:57 +02:00
ao.h audio: add channel map selection function 2013-05-12 21:24:57 +02:00
audio_out_internal.h audio/out: switch to channel map 2013-05-12 21:24:54 +02:00