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

Side by Side Diff: content/renderer/media/audio_renderer_impl.cc

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/renderer/media/audio_renderer_impl.h ('k') | content/renderer/notification_provider.h » ('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 #include "content/renderer/media/audio_renderer_impl.h" 5 #include "content/renderer/media/audio_renderer_impl.h"
6 6
7 #include <math.h> 7 #include <math.h>
8 8
9 #include "chrome/common/render_messages.h" 9 #include "chrome/common/render_messages.h"
10 #include "chrome/common/render_messages_params.h" 10 #include "chrome/common/render_messages_params.h"
11 #include "chrome/renderer/audio_message_filter.h"
12 #include "chrome/renderer/render_view.h" 11 #include "chrome/renderer/render_view.h"
13 #include "chrome/renderer/render_thread.h" 12 #include "chrome/renderer/render_thread.h"
14 #include "media/base/filter_host.h" 13 #include "media/base/filter_host.h"
15 14
16 namespace { 15 namespace {
17 16
18 // We will try to fill 200 ms worth of audio samples in each packet. A round 17 // We will try to fill 200 ms worth of audio samples in each packet. A round
19 // trip latency for IPC messages are typically 10 ms, this should give us 18 // trip latency for IPC messages are typically 10 ms, this should give us
20 // plenty of time to avoid clicks. 19 // plenty of time to avoid clicks.
21 const int kMillisecondsPerPacket = 200; 20 const int kMillisecondsPerPacket = 200;
(...skipping 331 matching lines...) Expand 10 before | Expand all | Expand 10 after
353 DCHECK(MessageLoop::current() == io_loop_); 352 DCHECK(MessageLoop::current() == io_loop_);
354 353
355 // We treat the IO loop going away the same as stopping. 354 // We treat the IO loop going away the same as stopping.
356 base::AutoLock auto_lock(lock_); 355 base::AutoLock auto_lock(lock_);
357 if (stopped_) 356 if (stopped_)
358 return; 357 return;
359 358
360 stopped_ = true; 359 stopped_ = true;
361 DestroyTask(); 360 DestroyTask();
362 } 361 }
OLDNEW
« no previous file with comments | « content/renderer/media/audio_renderer_impl.h ('k') | content/renderer/notification_provider.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698