[Webkit-unassigned] [Bug 44890] Add AudioContext files

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Sep 7 19:34:57 PDT 2010


https://bugs.webkit.org/show_bug.cgi?id=44890





--- Comment #5 from James Robinson <jamesr at chromium.org>  2010-09-07 19:34:57 PST ---
(From update of attachment 65948)
View in context: https://bugs.webkit.org/attachment.cgi?id=65948&action=prettypatch

> WebCore/webaudio/AudioContext.h:31
> +
I think you want #if ENABLE(WEB_AUDIO) here as well, no?

> WebCore/webaudio/AudioContext.h:62
> +    static PassRefPtr<AudioContext> create(Document* document);
nit: no need to name this parameter

> WebCore/webaudio/AudioContext.h:75
> +    float currentTime() { return (float)m_destinationNode->currentTime(); }
> +    float sampleRate() { return (float)m_destinationNode->sampleRate(); }
I'm not sure why these have to cast, but please use C++ style static_cast<float>() instead of C-style casts.

> WebCore/webaudio/AudioContext.h:101
> +    void notifyNodeFinishedProcessing(AudioNode* node);
nit: no need to name this parameter in the header

> WebCore/webaudio/AudioContext.h:105
> +    void markForDeletion(AudioNode* node);
nit: no need to name this parameter in the header

> WebCore/webaudio/AudioContext.h:109
> +    // Gets called everytime an AudioNode is connected.
> +    void nodeConnected(AudioNode* /*source*/, AudioNode* /*destination*/, unsigned /*outputIndex*/, unsigned /*inputIndex*/)
This is a little odd.  Does this function need a FIXME?  It doesn't really seem to do what the signature suggests it might.

> WebCore/webaudio/AudioContext.h:125
> +    AudioContext(Document* document);
> +    void lazyInitialize();
> +    void uninitialize();
> +
> +    // The context itself keeps a reference to all source nodes.  The source nodes, then reference all nodes they're connected to, and so on...
> +    void refNode(AudioNode* node);
> +    void derefNode(AudioNode* node);
> +    void derefUnfinishedSourceNodes();
nit: no need to name these parameters in the header

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list