Changes

Jump to: navigation, search

Audio Data API

5 bytes added, 14:11, 2 June 2010
nsIDOMNotifyAudioMetadataEvent
</pre>
The '''mozChannels''' attribute contains a the number of channels in this the audio resource (e.g., 2). The '''mozSampleRate''' attribute contains the number of samples per second that will be played, for example 44100. The '''mozFrameBufferLength''' attribute contains the default number of samples that will be returned in each '''AudioWritten''' event. This number is a total for all channels, and by default is set to be the number of channels * 1024 (e.g., 2 channels * 1024 samples = 2048 total). You can change this size using the '''mozSetFrameBufferSize()''' method to be another power of 2 between 512 and 32768 (see details below).
===== nsIDOMNotifyAudioWrittenEvent =====
Confirm
656
edits

Navigation menu