summaryrefslogtreecommitdiffstats
path: root/media/audio/audio_util.h
diff options
context:
space:
mode:
authorenal@chromium.org <enal@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-09-15 02:35:48 +0000
committerenal@chromium.org <enal@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-09-15 02:35:48 +0000
commitcc2e7541eff6b7155d444bdec2d0f0aae6eadedd (patch)
treedbc97db24bd1f3124903cd292c794013c8257984 /media/audio/audio_util.h
parentd6eaa3fb36a5940e0f196e024cacb42f278c6b5c (diff)
downloadchromium_src-cc2e7541eff6b7155d444bdec2d0f0aae6eadedd.zip
chromium_src-cc2e7541eff6b7155d444bdec2d0f0aae6eadedd.tar.gz
chromium_src-cc2e7541eff6b7155d444bdec2d0f0aae6eadedd.tar.bz2
Windows-only change -- issue is worst on Windows because of pre-buffering. On Linux problem is much milder, and on Mac we cannot yield high-priority audio thread...
Very short-term change: while working on proper long-term solution, workaround for race condition that causes clicks and bad audio stream. Yield if reader was called too quickly after previous call, as there are good chances renderer thread did not fill the buffer yet. BUG=http://code.google.com/p/chromium/issues/detail?id=61022 Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=99236 Review URL: http://codereview.chromium.org/7755001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@101231 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'media/audio/audio_util.h')
-rw-r--r--media/audio/audio_util.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/media/audio/audio_util.h b/media/audio/audio_util.h
index ff8f2f0..e9452b2 100644
--- a/media/audio/audio_util.h
+++ b/media/audio/audio_util.h
@@ -92,6 +92,10 @@ MEDIA_EXPORT uint32 GetActualDataSizeInBytes(base::SharedMemory* shared_memory,
MEDIA_EXPORT void SetActualDataSizeInBytes(base::SharedMemory* shared_memory,
uint32 shared_memory_size,
uint32 actual_data_size);
+MEDIA_EXPORT void SetUnknownDataSize(base::SharedMemory* shared_memory,
+ uint32 shared_memory_size);
+MEDIA_EXPORT bool IsUnknownDataSize(base::SharedMemory* shared_memory,
+ uint32 shared_memory_size);
} // namespace media