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

Side by Side Diff: media/audio/win/waveout_output_win.h

Issue 9805001: Move media/audio files into media namespace (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « media/audio/win/wavein_input_win.cc ('k') | media/audio/win/waveout_output_win.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef MEDIA_AUDIO_WIN_WAVEOUT_OUTPUT_WIN_H_ 5 #ifndef MEDIA_AUDIO_WIN_WAVEOUT_OUTPUT_WIN_H_
6 #define MEDIA_AUDIO_WIN_WAVEOUT_OUTPUT_WIN_H_ 6 #define MEDIA_AUDIO_WIN_WAVEOUT_OUTPUT_WIN_H_
7 #pragma once 7 #pragma once
8 8
9 #include <windows.h> 9 #include <windows.h>
10 #include <mmsystem.h> 10 #include <mmsystem.h>
11 #include <mmreg.h> 11 #include <mmreg.h>
12 12
13 #include "base/basictypes.h" 13 #include "base/basictypes.h"
14 #include "base/memory/scoped_ptr.h" 14 #include "base/memory/scoped_ptr.h"
15 #include "base/synchronization/lock.h" 15 #include "base/synchronization/lock.h"
16 #include "base/win/scoped_handle.h" 16 #include "base/win/scoped_handle.h"
17 #include "media/audio/audio_io.h" 17 #include "media/audio/audio_io.h"
18 #include "media/audio/audio_parameters.h" 18 #include "media/audio/audio_parameters.h"
19 19
20 namespace media {
21
20 class AudioManagerWin; 22 class AudioManagerWin;
21 23
22 // Implements PCM audio output support for Windows using the WaveXXX API. 24 // Implements PCM audio output support for Windows using the WaveXXX API.
23 // While not as nice as the DirectSound-based API, it should work in all target 25 // While not as nice as the DirectSound-based API, it should work in all target
24 // operating systems regardless or DirectX version installed. It is known that 26 // operating systems regardless or DirectX version installed. It is known that
25 // in some machines WaveXXX based audio is better while in others DirectSound 27 // in some machines WaveXXX based audio is better while in others DirectSound
26 // is better. 28 // is better.
27 // 29 //
28 // Important: the OnXXXX functions in AudioSourceCallback are called by more 30 // Important: the OnXXXX functions in AudioSourceCallback are called by more
29 // than one thread so it is important to have some form of synchronization if 31 // than one thread so it is important to have some form of synchronization if
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 // Pointer to the allocated audio buffers, we allocate all buffers in one big 127 // Pointer to the allocated audio buffers, we allocate all buffers in one big
126 // chunk. This object owns them. 128 // chunk. This object owns them.
127 scoped_array<char> buffers_; 129 scoped_array<char> buffers_;
128 130
129 // Lock used to avoid the conflict when callbacks are called simultaneously. 131 // Lock used to avoid the conflict when callbacks are called simultaneously.
130 base::Lock lock_; 132 base::Lock lock_;
131 133
132 DISALLOW_COPY_AND_ASSIGN(PCMWaveOutAudioOutputStream); 134 DISALLOW_COPY_AND_ASSIGN(PCMWaveOutAudioOutputStream);
133 }; 135 };
134 136
137 } // namespace media
138
135 #endif // MEDIA_AUDIO_WIN_WAVEOUT_OUTPUT_WIN_H_ 139 #endif // MEDIA_AUDIO_WIN_WAVEOUT_OUTPUT_WIN_H_
OLDNEW
« no previous file with comments | « media/audio/win/wavein_input_win.cc ('k') | media/audio/win/waveout_output_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698