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

Side by Side Diff: content/renderer/audio_device.h

Issue 6703003: Move a bunch of html5 renderer code to content. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 9 years, 9 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 | « content/content_renderer.gypi ('k') | content/renderer/audio_device.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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 CHROME_RENDERER_AUDIO_DEVICE_H_ 5 #ifndef CONTENT_RENDERER_AUDIO_DEVICE_H_
6 #define CHROME_RENDERER_AUDIO_DEVICE_H_ 6 #define CONTENT_RENDERER_AUDIO_DEVICE_H_
7 #pragma once 7 #pragma once
8 8
9 #include <vector> 9 #include <vector>
10 10
11 #include "base/basictypes.h" 11 #include "base/basictypes.h"
12 #include "base/scoped_ptr.h" 12 #include "base/scoped_ptr.h"
13 #include "base/shared_memory.h" 13 #include "base/shared_memory.h"
14 #include "base/threading/simple_thread.h" 14 #include "base/threading/simple_thread.h"
15 #include "chrome/renderer/audio_message_filter.h" 15 #include "content/renderer/audio_message_filter.h"
16 16
17 // Each instance of AudioDevice corresponds to one host stream. 17 // Each instance of AudioDevice corresponds to one host stream.
18 // This class is not thread-safe, so its methods must be called from 18 // This class is not thread-safe, so its methods must be called from
19 // the same thread. 19 // the same thread.
20 class AudioDevice : public AudioMessageFilter::Delegate, 20 class AudioDevice : public AudioMessageFilter::Delegate,
21 public base::DelegateSimpleThread::Delegate { 21 public base::DelegateSimpleThread::Delegate {
22 public: 22 public:
23 class RenderCallback { 23 class RenderCallback {
24 public: 24 public:
25 virtual void Render(const std::vector<float*>& audio_data, 25 virtual void Render(const std::vector<float*>& audio_data,
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 void* shared_memory_data() { return shared_memory()->memory(); } 74 void* shared_memory_data() { return shared_memory()->memory(); }
75 75
76 static scoped_refptr<AudioMessageFilter> filter_; 76 static scoped_refptr<AudioMessageFilter> filter_;
77 int32 stream_id_; 77 int32 stream_id_;
78 scoped_ptr<base::SharedMemory> shared_memory_; 78 scoped_ptr<base::SharedMemory> shared_memory_;
79 scoped_ptr<base::SyncSocket> socket_; 79 scoped_ptr<base::SyncSocket> socket_;
80 80
81 DISALLOW_COPY_AND_ASSIGN(AudioDevice); 81 DISALLOW_COPY_AND_ASSIGN(AudioDevice);
82 }; 82 };
83 83
84 #endif // CHROME_RENDERER_AUDIO_DEVICE_H_ 84 #endif // CONTENT_RENDERER_AUDIO_DEVICE_H_
OLDNEW
« no previous file with comments | « content/content_renderer.gypi ('k') | content/renderer/audio_device.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698