OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2010, Google Inc. All rights reserved. | 2 * Copyright (C) 2010, Google Inc. All rights reserved. |
3 * Copyright (C) 2011 Apple Inc. All rights reserved. | 3 * Copyright (C) 2011 Apple Inc. All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
7 * are met: | 7 * are met: |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
50 // All panning is relative to this listener. | 50 // All panning is relative to this listener. |
51 readonly attribute AudioListener listener; | 51 readonly attribute AudioListener listener; |
52 | 52 |
53 // Current state of the AudioContext | 53 // Current state of the AudioContext |
54 readonly attribute AudioContextState state; | 54 readonly attribute AudioContextState state; |
55 | 55 |
56 [RaisesException] AudioBuffer createBuffer(unsigned long numberOfChannels, u
nsigned long numberOfFrames, float sampleRate); | 56 [RaisesException] AudioBuffer createBuffer(unsigned long numberOfChannels, u
nsigned long numberOfFrames, float sampleRate); |
57 | 57 |
58 // Asynchronous audio file data decoding. | 58 // Asynchronous audio file data decoding. |
59 [RaisesException, MeasureAs=AudioContextDecodeAudioData, CallWith=ScriptStat
e] Promise<AudioBuffer> decodeAudioData(ArrayBuffer audioData, optional AudioBuf
ferCallback successCallback, optional AudioBufferCallback errorCallback); | 59 [RaisesException, MeasureAs=AudioContextDecodeAudioData, CallWith=ScriptStat
e] Promise<AudioBuffer> decodeAudioData(ArrayBuffer audioData, optional AudioBuf
ferCallback successCallback, optional AudioBufferCallback errorCallback); |
60 | 60 [RaisesException, MeasureAs=AudioContextDecodeAudioData, CallWith=ScriptStat
e] Promise<AudioBuffer> decodeAudioData(ArrayBuffer audioData, DecodeAudioDataOp
tions options); |
61 // Sources | 61 // Sources |
62 [RaisesException, MeasureAs=AudioContextCreateBufferSource] AudioBufferSourc
eNode createBufferSource(); | 62 [RaisesException, MeasureAs=AudioContextCreateBufferSource] AudioBufferSourc
eNode createBufferSource(); |
63 | 63 |
64 [RaisesException, MeasureAs=AudioContextCreateMediaElementSource] MediaEleme
ntAudioSourceNode createMediaElementSource(HTMLMediaElement mediaElement); | 64 [RaisesException, MeasureAs=AudioContextCreateMediaElementSource] MediaEleme
ntAudioSourceNode createMediaElementSource(HTMLMediaElement mediaElement); |
65 | 65 |
66 [RaisesException, MeasureAs=AudioContextCreateMediaStreamSource] MediaStream
AudioSourceNode createMediaStreamSource(MediaStream mediaStream); | 66 [RaisesException, MeasureAs=AudioContextCreateMediaStreamSource] MediaStream
AudioSourceNode createMediaStreamSource(MediaStream mediaStream); |
67 [RaisesException, MeasureAs=AudioContextCreateMediaStreamDestination] MediaS
treamAudioDestinationNode createMediaStreamDestination(); | 67 [RaisesException, MeasureAs=AudioContextCreateMediaStreamDestination] MediaS
treamAudioDestinationNode createMediaStreamDestination(); |
68 | 68 |
69 // Processing nodes | 69 // Processing nodes |
70 [RaisesException, MeasureAs=AudioContextCreateGain] GainNode createGain(); | 70 [RaisesException, MeasureAs=AudioContextCreateGain] GainNode createGain(); |
(...skipping 16 matching lines...) Expand all Loading... |
87 | 87 |
88 // Close | 88 // Close |
89 [MeasureAs=AudioContextClose, CallWith=ScriptState, ImplementedAs=closeConte
xt] Promise<void> close(); | 89 [MeasureAs=AudioContextClose, CallWith=ScriptState, ImplementedAs=closeConte
xt] Promise<void> close(); |
90 | 90 |
91 // Pause/resume | 91 // Pause/resume |
92 [MeasureAs=AudioContextSuspend, CallWith=ScriptState, ImplementedAs=suspendC
ontext] Promise<void> suspend(); | 92 [MeasureAs=AudioContextSuspend, CallWith=ScriptState, ImplementedAs=suspendC
ontext] Promise<void> suspend(); |
93 [MeasureAs=AudioContextResume, CallWith=ScriptState, ImplementedAs=resumeCon
text] Promise<void> resume(); | 93 [MeasureAs=AudioContextResume, CallWith=ScriptState, ImplementedAs=resumeCon
text] Promise<void> resume(); |
94 | 94 |
95 attribute EventHandler onstatechange; | 95 attribute EventHandler onstatechange; |
96 }; | 96 }; |
OLD | NEW |