diff options
author | xians@chromium.org <xians@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-10-04 22:38:30 +0000 |
---|---|---|
committer | xians@chromium.org <xians@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-10-04 22:38:30 +0000 |
commit | 980a50c7853059caf68b475ae8637dc35f199f82 (patch) | |
tree | 426f5fe68780a407d247a2cd4fb22ae737f38c14 /media/audio/audio_io.h | |
parent | 19005b7e8f675a339af6327563fd72775ae592f7 (diff) | |
download | chromium_src-980a50c7853059caf68b475ae8637dc35f199f82.zip chromium_src-980a50c7853059caf68b475ae8637dc35f199f82.tar.gz chromium_src-980a50c7853059caf68b475ae8637dc35f199f82.tar.bz2 |
Adding delay estimation to input audio.
On linux, snd_pcm_delay API will be used to get the delay value from ALSA;
On mac, the AudioQueue implementation will just use the buffer size as delay value since we may not use this impl for recording;
the low-latency AudioUnits implementation will use some AudioUnitGetProperty() API to get the accurate delay value from the driver;
On windows, for the Wave implementation, based on the tests we do, it should be OK to use the buffer size as the delay value;
for the to-be-implemented core audio implementation, we will see what is the appropriate way to get the delay there.
Review URL: http://codereview.chromium.org/8068005
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@104002 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'media/audio/audio_io.h')
-rw-r--r-- | media/audio/audio_io.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/media/audio/audio_io.h b/media/audio/audio_io.h index 74b5c47..2550873 100644 --- a/media/audio/audio_io.h +++ b/media/audio/audio_io.h @@ -112,7 +112,7 @@ class AudioInputStream { // available. This is called from a special audio thread and the // implementation should return as soon as possible. virtual void OnData(AudioInputStream* stream, const uint8* src, - uint32 size) = 0; + uint32 size, uint32 hardware_delay_bytes) = 0; // The stream is done with this callback, the last call received by this // audio sink. |