Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(886)

Unified Diff: media/audio/audio_util.h

Issue 13726011: Add vector_math::FMUL. Replace audio_util::AdjustVolume. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix NaCl. Add unittests. Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: media/audio/audio_util.h
diff --git a/media/audio/audio_util.h b/media/audio/audio_util.h
index 9fdbde81422ef2a70423bec563d3ec4e3f5bb417..38591f73ad5ec140f94efbd9f5250b8acc83c608 100644
--- a/media/audio/audio_util.h
+++ b/media/audio/audio_util.h
@@ -5,39 +5,12 @@
#ifndef MEDIA_AUDIO_AUDIO_UTIL_H_
#define MEDIA_AUDIO_AUDIO_UTIL_H_
-#include <string>
-
#include "base/basictypes.h"
-#include "media/base/channel_layout.h"
+#include "base/time.h"
+#include "build/build_config.h"
Chris Rogers 2013/04/05 21:31:35 just curious why these new header files?
DaleCurtis 2013/04/05 23:52:30 The defined(OS_WIN) should have build_config.h ava
#include "media/base/media_export.h"
-namespace base {
-class SharedMemory;
-}
-
namespace media {
-class AudioBus;
-
-// For all audio functions 3 audio formats are supported:
-// 8 bits unsigned 0 to 255.
-// 16 bit signed (little endian).
-// 32 bit signed (little endian)
-
-// AdjustVolume() does a software volume adjustment of a sample buffer.
-// The samples are multiplied by the volume, which should range from
-// 0.0 (mute) to 1.0 (full volume).
-// Using software allows each audio and video to have its own volume without
-// affecting the master volume.
-// In the future the function may be used to adjust the sample format to
-// simplify hardware requirements and to support a wider variety of input
-// formats.
-// The buffer is modified in-place to avoid memory management, as this
-// function may be called in performance critical code.
-MEDIA_EXPORT bool AdjustVolume(void* buf,
- size_t buflen,
- int channels,
- int bytes_per_sample,
- float volume);
// Returns user buffer size as specified on the command line or 0 if no buffer
// size has been specified.

Powered by Google App Engine
This is Rietveld 408576698