Index: third_party/WebKit/Source/modules/webaudio/AudioWorkletProcessor.h |
diff --git a/third_party/WebKit/Source/modules/webaudio/AudioWorkletProcessor.h b/third_party/WebKit/Source/modules/webaudio/AudioWorkletProcessor.h |
index df1a5b56be05c1db072e1c8157b0c86c112c9a22..222751ffdf53a936d8c850cf85e3fa5eed42c4d6 100644 |
--- a/third_party/WebKit/Source/modules/webaudio/AudioWorkletProcessor.h |
+++ b/third_party/WebKit/Source/modules/webaudio/AudioWorkletProcessor.h |
@@ -12,6 +12,9 @@ |
#include "platform/wtf/text/WTFString.h" |
#include "v8/include/v8.h" |
+#include "modules/webaudio/AudioParamDescriptor.h" |
+#include "platform/audio/AudioArray.h" |
+ |
namespace blink { |
class AudioBuffer; |
@@ -26,10 +29,12 @@ class AudioWorkletProcessorDefinition; |
// must be called on the worker thread. |
class MODULES_EXPORT AudioWorkletProcessor |
: public GarbageCollectedFinalized<AudioWorkletProcessor>, |
- public TraceWrapperBase { |
+ public ScriptWrappable { |
+DEFINE_WRAPPERTYPEINFO(); |
+ |
public: |
static AudioWorkletProcessor* Create(AudioWorkletGlobalScope*, |
- const String& name); |
+ AudioWorkletProcessorDefinition*); |
virtual ~AudioWorkletProcessor(); |
void SetInstance(v8::Isolate*, v8::Local<v8::Object> instance); |
@@ -37,19 +42,26 @@ class MODULES_EXPORT AudioWorkletProcessor |
v8::Local<v8::Object> InstanceLocal(v8::Isolate*); |
// |AudioWorkletHandler| invokes this method to process audio. |
- void Process(AudioBuffer* input_buffer, AudioBuffer* output_buffer); |
+ void Process(AudioBuffer* input_buffer, |
+ AudioBuffer* output_buffer, |
+ HashMap<String, AudioFloatArray*> audio_param_data_map); |
+ void Dispose(); |
- const String& GetName() const { return name_; } |
+ const String& GetName() const; |
+ const AudioWorkletProcessorDefinition* GetDefinition() const; |
DECLARE_TRACE(); |
DECLARE_TRACE_WRAPPERS(); |
private: |
- AudioWorkletProcessor(AudioWorkletGlobalScope*, const String& name); |
+ AudioWorkletProcessor(AudioWorkletGlobalScope*, |
+ AudioWorkletProcessorDefinition*); |
- Member<AudioWorkletGlobalScope> global_scope_; |
- const String name_; |
+ Member<AudioWorkletGlobalScope> global_scope_; |
+ Member<AudioWorkletProcessorDefinition> definition_; |
TraceWrapperV8Reference<v8::Object> instance_; |
+ |
+ bool is_disposed_ = false; |
}; |
} // namespace blink |