diff --git a/files/en-us/web/api/audionode/channelinterpretation/index.html b/files/en-us/web/api/audionode/channelinterpretation/index.html index 199cd3a42fb4295..bb31bcde5e921f6 100644 --- a/files/en-us/web/api/audionode/channelinterpretation/index.html +++ b/files/en-us/web/api/audionode/channelinterpretation/index.html @@ -8,25 +8,36 @@ - Reference - Web Audio API - channelInterpretation +browser-compat: api.AudioNode.channelInterpretation ---

{{ APIRef("Web Audio API") }}

-

The channelInterpretation property of the {{ domxref("AudioNode") }} interface represents an enumerated value describing the meaning of the channels. This interpretation will define how audio up-mixing and down-mixing will happen.

+

The channelInterpretation property of the {{domxref("AudioNode")}} interface represents an enumerated value describing how input channels are mapped to output channels when the number of inputs/outputs is different. For example, this setting defines how a mono input will be up-mixed to a stereo or 5.1 channel output, or how a quad channel input will be down-mixed to a stereo or mono output.

+ +

The property has two options: speakers and discrete. These are documented in Basic concepts behind Web Audio API > up-mixing and down-mixing.

-

{{page("/en-US/docs/Web/API/Web_Audio_API/Basic_concepts_behind_Web_Audio_API","Up-mixing and down-mixing")}}

Syntax

-
var oscillator = audioCtx.createOscillator();
+
var oscillator = audioCtx.createOscillator();
 oscillator.channelInterpretation = 'discrete';

Value

-

An enumerated value representing a channelInterpretation.

+

The values are documented in Basic concepts behind Web Audio API > up-mixing and down-mixing.

+ +

In summary:

+
+
speakers
+
Use set of "standard" mappings for combinations of common speaker input and outputs setups (mono, stereo, quad, 5.1). For example, with this setting a mono channel input will output to both channels of a stereo output.
+
discrete
+
Input channels are mapped to output channels in order. If there are more inputs that outputs the additional inputs are dropped; if there are fewer then the unused outputs are silent.
+
+

Example

-
var AudioContext = window.AudioContext || window.webkitAudioContext;
+
var AudioContext = window.AudioContext || window.webkitAudioContext;
 
 var audioCtx = new AudioContext();
 
@@ -41,24 +52,11 @@ 

Example

Specifications

- - - - - - - - - - - - - -
SpecificationStatusComment
{{SpecName('Web Audio API', '#dom-audionode-channelinterpretation', 'channelInterpretation')}}{{Spec2('Web Audio API')}}
+{{Specifications}}

Browser compatibility

-

{{Compat("api.AudioNode.channelInterpretation")}}

+

{{Compat}}

See also

diff --git a/files/en-us/web/api/web_audio_api/basic_concepts_behind_web_audio_api/index.html b/files/en-us/web/api/web_audio_api/basic_concepts_behind_web_audio_api/index.html index ed98e83301cf4c4..bd6100c4dca50ca 100644 --- a/files/en-us/web/api/web_audio_api/basic_concepts_behind_web_audio_api/index.html +++ b/files/en-us/web/api/web_audio_api/basic_concepts_behind_web_audio_api/index.html @@ -311,13 +311,13 @@

Visualizations

{{domxref("AnalyserNode.getFloatFrequencyData()")}}
-
Copies the current frequency data into a {{domxref("Float32Array")}} array passed into it.
+
Copies the current frequency data into a {{jsxref("Float32Array")}} array passed into it.
{{domxref("AnalyserNode.getByteFrequencyData()")}}
-
Copies the current frequency data into a {{domxref("Uint8Array")}} (unsigned byte array) passed into it.
+
Copies the current frequency data into a {{jsxref("Uint8Array")}} (unsigned byte array) passed into it.
{{domxref("AnalyserNode.getFloatTimeDomainData()")}}
-
Copies the current waveform, or time-domain, data into a {{domxref("Float32Array")}} array passed into it.
+
Copies the current waveform, or time-domain, data into a {{jsxref("Float32Array")}} array passed into it.
{{domxref("AnalyserNode.getByteTimeDomainData()")}}
-
Copies the current waveform, or time-domain, data into a {{domxref("Uint8Array")}} (unsigned byte array) passed into it.
+
Copies the current waveform, or time-domain, data into a {{jsxref("Uint8Array")}} (unsigned byte array) passed into it.