2011-04-05 Chris Rogers <crogers@google.com>
authorcrogers@google.com <crogers@google.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 5 Apr 2011 18:59:53 +0000 (18:59 +0000)
committercrogers@google.com <crogers@google.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 5 Apr 2011 18:59:53 +0000 (18:59 +0000)
commit1a9c4c47deb693f35f55f0961d09172c1762d427
tree74a267b4649f0ae714b72b0d4def5bf953be8192
parente01a47309d8993f812fa5ccc04c31f883979bbc5
2011-04-05  Chris Rogers  <crogers@google.com>

        Reviewed by Kenneth Russell.

        Add support for offline audio rendering to AudioContext API
        https://bugs.webkit.org/show_bug.cgi?id=57676

        No new tests since audio API is not yet implemented.

        * DerivedSources.make:
        * WebCore.gypi:
        * WebCore.xcodeproj/project.pbxproj:
        * bindings/js/JSAudioContextCustom.cpp:
        (WebCore::JSAudioContextConstructor::constructJSAudioContext):
        * bindings/js/JSEventCustom.cpp:
        (WebCore::toJS):
        * bindings/js/JSEventTarget.cpp:
        (WebCore::toJS):
        * bindings/v8/V8DOMWrapper.cpp:
        (WebCore::V8DOMWrapper::convertEventTargetToV8Object):
        * bindings/v8/custom/V8AudioContextCustom.cpp:
        (WebCore::V8AudioContext::constructorCallback):
        * bindings/v8/custom/V8EventCustom.cpp:
        (WebCore::toV8):
        * dom/Event.cpp:
        (WebCore::Event::isOfflineAudioCompletionEvent):
        * dom/Event.h:
        * dom/EventTarget.cpp:
        (WebCore::EventTarget::toAudioContext):
        * dom/EventTarget.h:
        * platform/audio/HRTFDatabaseLoader.cpp:
        (WebCore::HRTFDatabaseLoader::waitForLoaderThreadCompletion):
        * platform/audio/HRTFDatabaseLoader.h:
        (WebCore::HRTFDatabaseLoader::loader):
        * webaudio/AudioContext.cpp:
        (WebCore::AudioContext::createOfflineContext):
        (WebCore::AudioContext::AudioContext):
        (WebCore::AudioContext::constructCommon):
        (WebCore::AudioContext::document):
        (WebCore::AudioContext::scriptExecutionContext):
        (WebCore::AudioContext::toAudioContext):
        (WebCore::AudioContext::startRendering):
        (WebCore::AudioContext::fireCompletionEvent):
        * webaudio/AudioContext.h:
        (WebCore::AudioContext::isOfflineContext):
        (WebCore::AudioContext::eventTargetData):
        (WebCore::AudioContext::ensureEventTargetData):
        (WebCore::AudioContext::refEventTarget):
        (WebCore::AudioContext::derefEventTarget):
        * webaudio/AudioContext.idl:
        * webaudio/AudioDestinationNode.cpp:
        (WebCore::AudioDestinationNode::AudioDestinationNode):
        * webaudio/AudioDestinationNode.h:
        (WebCore::AudioDestinationNode::reset):
        (WebCore::AudioDestinationNode::numberOfChannels):
        * webaudio/ConvolverNode.cpp:
        (WebCore::ConvolverNode::setBuffer):
        * webaudio/DefaultAudioDestinationNode.cpp: Added.
        (WebCore::DefaultAudioDestinationNode::DefaultAudioDestinationNode):
        (WebCore::DefaultAudioDestinationNode::~DefaultAudioDestinationNode):
        (WebCore::DefaultAudioDestinationNode::initialize):
        (WebCore::DefaultAudioDestinationNode::uninitialize):
        (WebCore::DefaultAudioDestinationNode::startRendering):
        * webaudio/DefaultAudioDestinationNode.h: Added.
        (WebCore::DefaultAudioDestinationNode::create):
        (WebCore::DefaultAudioDestinationNode::sampleRate):
        * webaudio/OfflineAudioCompletionEvent.cpp: Added.
        (WebCore::OfflineAudioCompletionEvent::create):
        (WebCore::OfflineAudioCompletionEvent::OfflineAudioCompletionEvent):
        (WebCore::OfflineAudioCompletionEvent::~OfflineAudioCompletionEvent):
        (WebCore::OfflineAudioCompletionEvent::isOfflineAudioCompletionEvent):
        * webaudio/OfflineAudioCompletionEvent.h: Added.
        (WebCore::OfflineAudioCompletionEvent::renderedBuffer):
        * webaudio/OfflineAudioCompletionEvent.idl: Added.
        * webaudio/OfflineAudioDestinationNode.cpp: Added.
        (WebCore::OfflineAudioDestinationNode::OfflineAudioDestinationNode):
        (WebCore::OfflineAudioDestinationNode::~OfflineAudioDestinationNode):
        (WebCore::OfflineAudioDestinationNode::initialize):
        (WebCore::OfflineAudioDestinationNode::uninitialize):
        (WebCore::OfflineAudioDestinationNode::startRendering):
        (WebCore::OfflineAudioDestinationNode::renderEntry):
        (WebCore::OfflineAudioDestinationNode::render):
        (WebCore::OfflineAudioDestinationNode::notifyCompleteDispatch):
        (WebCore::OfflineAudioDestinationNode::notifyComplete):
        * webaudio/OfflineAudioDestinationNode.h: Added.
        (WebCore::OfflineAudioDestinationNode::create):
        (WebCore::OfflineAudioDestinationNode::sampleRate):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@82963 268f45cc-cd09-0410-ab3c-d52691b4dbfc
29 files changed:
Source/WebCore/ChangeLog
Source/WebCore/DerivedSources.make
Source/WebCore/WebCore.gypi
Source/WebCore/WebCore.xcodeproj/project.pbxproj
Source/WebCore/bindings/js/JSAudioContextCustom.cpp
Source/WebCore/bindings/js/JSEventCustom.cpp
Source/WebCore/bindings/js/JSEventTarget.cpp
Source/WebCore/bindings/v8/V8DOMWrapper.cpp
Source/WebCore/bindings/v8/custom/V8AudioContextCustom.cpp
Source/WebCore/bindings/v8/custom/V8EventCustom.cpp
Source/WebCore/dom/Event.cpp
Source/WebCore/dom/Event.h
Source/WebCore/dom/EventTarget.cpp
Source/WebCore/dom/EventTarget.h
Source/WebCore/platform/audio/HRTFDatabaseLoader.cpp
Source/WebCore/platform/audio/HRTFDatabaseLoader.h
Source/WebCore/webaudio/AudioContext.cpp
Source/WebCore/webaudio/AudioContext.h
Source/WebCore/webaudio/AudioContext.idl
Source/WebCore/webaudio/AudioDestinationNode.cpp
Source/WebCore/webaudio/AudioDestinationNode.h
Source/WebCore/webaudio/ConvolverNode.cpp
Source/WebCore/webaudio/DefaultAudioDestinationNode.cpp [new file with mode: 0644]
Source/WebCore/webaudio/DefaultAudioDestinationNode.h [new file with mode: 0644]
Source/WebCore/webaudio/OfflineAudioCompletionEvent.cpp [new file with mode: 0644]
Source/WebCore/webaudio/OfflineAudioCompletionEvent.h [new file with mode: 0644]
Source/WebCore/webaudio/OfflineAudioCompletionEvent.idl [new file with mode: 0644]
Source/WebCore/webaudio/OfflineAudioDestinationNode.cpp [new file with mode: 0644]
Source/WebCore/webaudio/OfflineAudioDestinationNode.h [new file with mode: 0644]