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

Side by Side Diff: third_party/WebKit/Source/modules/webaudio/BaseAudioContext.h

Issue 2134813002: Implement ConstantSourceNode (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 years, 2 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010, Google Inc. All rights reserved. 2 * Copyright (C) 2010, Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
49 49
50 class AnalyserNode; 50 class AnalyserNode;
51 class AudioBuffer; 51 class AudioBuffer;
52 class AudioBufferCallback; 52 class AudioBufferCallback;
53 class AudioBufferSourceNode; 53 class AudioBufferSourceNode;
54 class AudioListener; 54 class AudioListener;
55 class AudioSummingJunction; 55 class AudioSummingJunction;
56 class BiquadFilterNode; 56 class BiquadFilterNode;
57 class ChannelMergerNode; 57 class ChannelMergerNode;
58 class ChannelSplitterNode; 58 class ChannelSplitterNode;
59 class ConstantSourceNode;
59 class ConvolverNode; 60 class ConvolverNode;
60 class DelayNode; 61 class DelayNode;
61 class Dictionary; 62 class Dictionary;
62 class Document; 63 class Document;
63 class DynamicsCompressorNode; 64 class DynamicsCompressorNode;
64 class ExceptionState; 65 class ExceptionState;
65 class GainNode; 66 class GainNode;
66 class HTMLMediaElement; 67 class HTMLMediaElement;
67 class IIRFilterNode; 68 class IIRFilterNode;
68 class MediaElementAudioSourceNode; 69 class MediaElementAudioSourceNode;
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
144 145
145 // Handles the promise and callbacks when |decodeAudioData| is finished deco ding. 146 // Handles the promise and callbacks when |decodeAudioData| is finished deco ding.
146 void handleDecodeAudioData(AudioBuffer*, ScriptPromiseResolver*, AudioBuffer Callback* successCallback, AudioBufferCallback* errorCallback); 147 void handleDecodeAudioData(AudioBuffer*, ScriptPromiseResolver*, AudioBuffer Callback* successCallback, AudioBufferCallback* errorCallback);
147 148
148 AudioListener* listener() { return m_listener; } 149 AudioListener* listener() { return m_listener; }
149 150
150 virtual bool hasRealtimeConstraint() = 0; 151 virtual bool hasRealtimeConstraint() = 0;
151 152
152 // The AudioNode create methods are called on the main thread (from JavaScri pt). 153 // The AudioNode create methods are called on the main thread (from JavaScri pt).
153 AudioBufferSourceNode* createBufferSource(ExceptionState&); 154 AudioBufferSourceNode* createBufferSource(ExceptionState&);
155 ConstantSourceNode* createConstantSource(ExceptionState&);
154 MediaElementAudioSourceNode* createMediaElementSource(HTMLMediaElement*, Exc eptionState&); 156 MediaElementAudioSourceNode* createMediaElementSource(HTMLMediaElement*, Exc eptionState&);
155 MediaStreamAudioSourceNode* createMediaStreamSource(MediaStream*, ExceptionS tate&); 157 MediaStreamAudioSourceNode* createMediaStreamSource(MediaStream*, ExceptionS tate&);
156 MediaStreamAudioDestinationNode* createMediaStreamDestination(ExceptionState &); 158 MediaStreamAudioDestinationNode* createMediaStreamDestination(ExceptionState &);
157 GainNode* createGain(ExceptionState&); 159 GainNode* createGain(ExceptionState&);
158 BiquadFilterNode* createBiquadFilter(ExceptionState&); 160 BiquadFilterNode* createBiquadFilter(ExceptionState&);
159 WaveShaperNode* createWaveShaper(ExceptionState&); 161 WaveShaperNode* createWaveShaper(ExceptionState&);
160 DelayNode* createDelay(ExceptionState&); 162 DelayNode* createDelay(ExceptionState&);
161 DelayNode* createDelay(double maxDelayTime, ExceptionState&); 163 DelayNode* createDelay(double maxDelayTime, ExceptionState&);
162 PannerNode* createPanner(ExceptionState&); 164 PannerNode* createPanner(ExceptionState&);
163 ConvolverNode* createConvolver(ExceptionState&); 165 ConvolverNode* createConvolver(ExceptionState&);
(...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after
370 Member<PeriodicWave> m_periodicWaveTriangle; 372 Member<PeriodicWave> m_periodicWaveTriangle;
371 373
372 // This is considering 32 is large enough for multiple channels audio. 374 // This is considering 32 is large enough for multiple channels audio.
373 // It is somewhat arbitrary and could be increased if necessary. 375 // It is somewhat arbitrary and could be increased if necessary.
374 enum { MaxNumberOfChannels = 32 }; 376 enum { MaxNumberOfChannels = 32 };
375 }; 377 };
376 378
377 } // namespace blink 379 } // namespace blink
378 380
379 #endif // BaseAudioContext_h 381 #endif // BaseAudioContext_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698