| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "modules/webaudio/AudioContext.h" | 5 #include "modules/webaudio/AudioContext.h" |
| 6 | 6 |
| 7 #include "bindings/core/v8/ExceptionMessages.h" | 7 #include "bindings/core/v8/ExceptionMessages.h" |
| 8 #include "bindings/core/v8/ExceptionState.h" | 8 #include "bindings/core/v8/ExceptionState.h" |
| 9 #include "bindings/core/v8/ScriptPromiseResolver.h" | 9 #include "bindings/core/v8/ScriptPromiseResolver.h" |
| 10 #include "core/dom/DOMException.h" | 10 #include "core/dom/DOMException.h" |
| 11 #include "core/dom/ExceptionCode.h" | 11 #include "core/dom/ExceptionCode.h" |
| 12 #include "core/frame/LocalDOMWindow.h" | 12 #include "core/frame/LocalDOMWindow.h" |
| 13 #include "core/frame/UseCounter.h" | 13 #include "core/frame/UseCounter.h" |
| 14 #include "core/timing/DOMWindowPerformance.h" | 14 #include "core/timing/DOMWindowPerformance.h" |
| 15 #include "core/timing/Performance.h" | 15 #include "core/timing/Performance.h" |
| 16 #include "modules/webaudio/AudioBufferCallback.h" | |
| 17 #include "modules/webaudio/AudioContextOptions.h" | 16 #include "modules/webaudio/AudioContextOptions.h" |
| 18 #include "modules/webaudio/AudioTimestamp.h" | 17 #include "modules/webaudio/AudioTimestamp.h" |
| 19 #include "modules/webaudio/DefaultAudioDestinationNode.h" | 18 #include "modules/webaudio/DefaultAudioDestinationNode.h" |
| 20 #include "platform/Histogram.h" | 19 #include "platform/Histogram.h" |
| 21 #include "platform/audio/AudioUtilities.h" | 20 #include "platform/audio/AudioUtilities.h" |
| 22 #include "public/platform/WebAudioLatencyHint.h" | 21 #include "public/platform/WebAudioLatencyHint.h" |
| 23 | 22 |
| 24 #if DEBUG_AUDIONODE_REFERENCES | 23 #if DEBUG_AUDIONODE_REFERENCES |
| 25 #include <stdio.h> | 24 #include <stdio.h> |
| 26 #endif | 25 #endif |
| (...skipping 238 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 265 SetContextState(kSuspended); | 264 SetContextState(kSuspended); |
| 266 GetDeferredTaskHandler().ClearHandlersToBeDeleted(); | 265 GetDeferredTaskHandler().ClearHandlersToBeDeleted(); |
| 267 } | 266 } |
| 268 } | 267 } |
| 269 | 268 |
| 270 double AudioContext::baseLatency() const { | 269 double AudioContext::baseLatency() const { |
| 271 return FramesPerBuffer() / static_cast<double>(sampleRate()); | 270 return FramesPerBuffer() / static_cast<double>(sampleRate()); |
| 272 } | 271 } |
| 273 | 272 |
| 274 } // namespace blink | 273 } // namespace blink |
| OLD | NEW |