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

Side by Side Diff: content/renderer/media/renderer_webaudiodevice_impl.h

Issue 1687213002: Express audio delay more precisely in frames rather than milliseconds. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 years, 10 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
« no previous file with comments | « no previous file | content/renderer/media/renderer_webaudiodevice_impl.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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 CONTENT_RENDERER_MEDIA_RENDERER_WEBAUDIODEVICE_IMPL_H_ 5 #ifndef CONTENT_RENDERER_MEDIA_RENDERER_WEBAUDIODEVICE_IMPL_H_
6 #define CONTENT_RENDERER_MEDIA_RENDERER_WEBAUDIODEVICE_IMPL_H_ 6 #define CONTENT_RENDERER_MEDIA_RENDERER_WEBAUDIODEVICE_IMPL_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include "base/cancelable_callback.h" 10 #include "base/cancelable_callback.h"
(...skipping 27 matching lines...) Expand all
38 const url::Origin& security_origin); 38 const url::Origin& security_origin);
39 ~RendererWebAudioDeviceImpl() override; 39 ~RendererWebAudioDeviceImpl() override;
40 40
41 // blink::WebAudioDevice implementation. 41 // blink::WebAudioDevice implementation.
42 void start() override; 42 void start() override;
43 void stop() override; 43 void stop() override;
44 double sampleRate() override; 44 double sampleRate() override;
45 45
46 // AudioRendererSink::RenderCallback implementation. 46 // AudioRendererSink::RenderCallback implementation.
47 int Render(media::AudioBus* dest, 47 int Render(media::AudioBus* dest,
48 uint32_t audio_delay_milliseconds, 48 uint32_t frames_delayed,
49 uint32_t frames_skipped) override; 49 uint32_t frames_skipped) override;
50 50
51 void OnRenderError() override; 51 void OnRenderError() override;
52 52
53 private: 53 private:
54 const media::AudioParameters params_; 54 const media::AudioParameters params_;
55 55
56 // Weak reference to the callback into WebKit code. 56 // Weak reference to the callback into WebKit code.
57 blink::WebAudioDevice::RenderCallback* const client_callback_; 57 blink::WebAudioDevice::RenderCallback* const client_callback_;
58 58
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 92
93 // Security origin, used to check permissions for |output_device_|. 93 // Security origin, used to check permissions for |output_device_|.
94 url::Origin security_origin_; 94 url::Origin security_origin_;
95 95
96 DISALLOW_COPY_AND_ASSIGN(RendererWebAudioDeviceImpl); 96 DISALLOW_COPY_AND_ASSIGN(RendererWebAudioDeviceImpl);
97 }; 97 };
98 98
99 } // namespace content 99 } // namespace content
100 100
101 #endif // CONTENT_RENDERER_MEDIA_RENDERER_WEBAUDIODEVICE_IMPL_H_ 101 #endif // CONTENT_RENDERER_MEDIA_RENDERER_WEBAUDIODEVICE_IMPL_H_
OLDNEW
« no previous file with comments | « no previous file | content/renderer/media/renderer_webaudiodevice_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698