W3C home > Mailing lists > Public > public-audio@w3.org > July to September 2013

[web-audio-api] (AudioBufferSimpl): AudioBuffer simplification (#80)

From: Olivier Thereaux <notifications@github.com>
Date: Wed, 11 Sep 2013 07:28:11 -0700
To: WebAudio/web-audio-api <web-audio-api@noreply.github.com>
Message-ID: <WebAudio/web-audio-api/issues/80@github.com>
> Originally reported on W3C Bugzilla [ISSUE-17341](https://www.w3.org/Bugs/Public/show_bug.cgi?id=17341) Tue, 05 Jun 2012 11:34:05 GMT
> Reported by Philip J├Ągenstedt
> Assigned to 

Audio-ISSUE-48 (AudioBufferSimpl): AudioBuffer simplification [Web Audio API]

http://www.w3.org/2011/audio/track/issues/48

Raised by: Philip J├Ągenstedt
On product: Web Audio API

The duration attribute fills no purpose, as it can be calculated trivially from sampleRate and length.

In fact, the interface can be reduced to:

    interface AudioBuffer {
        readonly attribute float sampleRate;
        Float32Array[] data;
    }

The number of channels is data.length and the number of samples is data[0].length.

The name data was picked for consistency with the ImageData interface from the 2D canvas context.

---
Reply to this email directly or view it on GitHub:
https://github.com/WebAudio/web-audio-api/issues/80
Received on Wednesday, 11 September 2013 14:28:39 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:50:11 UTC