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

Unified Diff: media/base/audio_bus.h

Issue 10909185: Add Mac OS X synchronized audio I/O back-end (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 3 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/base/audio_bus.h
===================================================================
--- media/base/audio_bus.h (revision 156450)
+++ media/base/audio_bus.h (working copy)
@@ -11,6 +11,10 @@
#include "base/memory/scoped_ptr.h"
#include "media/base/media_export.h"
+#if defined(OS_MACOSX)
+struct AudioBufferList;
+#endif
+
namespace media {
class AudioParameters;
@@ -25,6 +29,16 @@
// SSE optimizations.
enum { kChannelAlignment = 16 };
+ AudioBus(int channels, int frames);
+ AudioBus(int channels, int frames, float* data);
+ AudioBus(int frames, const std::vector<float*>& channel_data);
+
+#if defined(OS_MACOSX)
+ AudioBus(int channels, int frames, AudioBufferList* buffer_list);
+#endif
+
+ ~AudioBus();
scherkus (not reviewing) 2012/09/13 13:06:03 we'll likely have to chat about this change a bit
DaleCurtis 2012/09/14 09:14:00 +1, I don't see why you made this change. You shou
Chris Rogers 2012/09/15 00:06:08 Ok, I can change this part if necessary - not that
DaleCurtis 2012/09/15 07:44:42 This is going to result in real time allocation ei
+
// Creates a new AudioBus and allocates |channels| of length |frames|. Uses
// channels() and frames_per_buffer() from AudioParameters if given.
static scoped_ptr<AudioBus> Create(int channels, int frames);
@@ -85,12 +99,7 @@
private:
friend class scoped_ptr<AudioBus>;
- ~AudioBus();
- AudioBus(int channels, int frames);
- AudioBus(int channels, int frames, float* data);
- AudioBus(int frames, const std::vector<float*>& channel_data);
-
// Helper method for building |channel_data_| from a block of memory. |data|
// must be at least BlockSize() bytes in size.
void BuildChannelData(int channels, int aligned_frame, float* data);

Powered by Google App Engine
This is Rietveld 408576698