diff options
author | Chris Robinson <[email protected]> | 2010-11-21 06:32:59 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2010-11-21 06:32:59 -0800 |
commit | a7b4e0b5c5eefb8476836aad094035bd0a5cbcd5 (patch) | |
tree | 3a1d54115f2557e5540297625f20961b8b148e62 /Alc/pulseaudio.c | |
parent | bbb45e326c049aef5b4d7e86021f365d206d8bb3 (diff) |
Get rid of the device timer stuff
Diffstat (limited to 'Alc/pulseaudio.c')
-rw-r--r-- | Alc/pulseaudio.c | 29 |
1 files changed, 1 insertions, 28 deletions
diff --git a/Alc/pulseaudio.c b/Alc/pulseaudio.c index 81e56cf8..46ac446a 100644 --- a/Alc/pulseaudio.c +++ b/Alc/pulseaudio.c @@ -137,9 +137,6 @@ typedef struct { pa_threaded_mainloop *loop; - ALuint64 baseTime; - pa_usec_t lastTime; - ALvoid *thread; volatile ALboolean killNow; @@ -965,8 +962,6 @@ static ALCboolean pulse_reset_playback(ALCdevice *device) //{{{ ppa_stream_set_write_callback(data->stream, stream_write_callback, device); ppa_stream_set_underflow_callback(data->stream, stream_signal_callback, device); - device->TimeRes = 1000; - data->thread = StartThread(PulseProc, device); if(!data->thread) { @@ -992,7 +987,6 @@ static ALCboolean pulse_reset_playback(ALCdevice *device) //{{{ static void pulse_stop_playback(ALCdevice *device) //{{{ { pulse_data *data = device->ExtraData; - pa_usec_t usec = 0; if(!data->stream) return; @@ -1008,11 +1002,6 @@ static void pulse_stop_playback(ALCdevice *device) //{{{ ppa_threaded_mainloop_lock(data->loop); - if(ppa_stream_get_time(data->stream, &usec) != PA_OK) - usec = data->lastTime; - data->baseTime += usec*1000; - data->lastTime = 0; - #if PA_CHECK_VERSION(0,9,15) if(ppa_stream_set_buffer_attr_callback) ppa_stream_set_buffer_attr_callback(data->stream, NULL, NULL); @@ -1241,21 +1230,6 @@ static void pulse_capture_samples(ALCdevice *device, ALCvoid *buffer, ALCuint sa alcSetError(device, ALC_INVALID_VALUE); } //}}} -static ALuint64 pulse_get_time(ALCdevice *Device) //{{{ -{ - pulse_data *data = Device->ExtraData; - pa_usec_t usec; - - ppa_threaded_mainloop_lock(data->loop); - if(!data->stream || ppa_stream_get_time(data->stream, &usec) != PA_OK) - usec = data->lastTime; - else - data->lastTime = usec; - ppa_threaded_mainloop_unlock(data->loop); - - return data->baseTime + usec*1000; -} //}}} - BackendFuncs pulse_funcs = { //{{{ pulse_open_playback, @@ -1267,8 +1241,7 @@ BackendFuncs pulse_funcs = { //{{{ pulse_start_capture, pulse_stop_capture, pulse_capture_samples, - pulse_available_samples, - pulse_get_time + pulse_available_samples }; //}}} void alc_pulse_init(BackendFuncs *func_list) //{{{ |