Changeset 106580 in webkit


Ignore:
Timestamp:
Feb 2, 2012 12:46:43 PM (12 years ago)
Author:
commit-queue@webkit.org
Message:

Constant values to set "distanceModel" are undefined
https://bugs.webkit.org/show_bug.cgi?id=74273

Patch by Raymond Toy <Raymond Toy> on 2012-02-02
Reviewed by Kenneth Russell.

Source/WebCore:

Tests: webaudio/distance-exponential.html

webaudio/distance-inverse.html
webaudio/distance-linear.html

  • webaudio/AudioPannerNode.h: Define enum for the new constants

for the distance models.

  • webaudio/AudioPannerNode.idl: Define matching constants for the

distance models.

LayoutTests:

  • webaudio/distance-exponential-expected.txt: Added.
  • webaudio/distance-exponential.html: Added.
  • webaudio/distance-inverse-expected.txt: Added.
  • webaudio/distance-inverse.html: Added.
  • webaudio/distance-linear-expected.txt: Added.
  • webaudio/distance-linear.html: Added.
  • webaudio/resources/distance-model-testing.js: Added.

(createImpulseBuffer):
(linearDistance):
(exponentialDistance):
(inverseDistance):
(createGraph):
(startSources):
(equalPowerGain):
(checkDistanceResult.return.renderedBuffer):
(checkDistanceResult):

Location:
trunk
Files:
7 added
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r106579 r106580  
     12012-02-02  Raymond Toy  <rtoy@google.com>
     2
     3        Constant values to set "distanceModel" are undefined
     4        https://bugs.webkit.org/show_bug.cgi?id=74273
     5
     6        Reviewed by Kenneth Russell.
     7
     8        * webaudio/distance-exponential-expected.txt: Added.
     9        * webaudio/distance-exponential.html: Added.
     10        * webaudio/distance-inverse-expected.txt: Added.
     11        * webaudio/distance-inverse.html: Added.
     12        * webaudio/distance-linear-expected.txt: Added.
     13        * webaudio/distance-linear.html: Added.
     14        * webaudio/resources/distance-model-testing.js: Added.
     15        (createImpulseBuffer):
     16        (linearDistance):
     17        (exponentialDistance):
     18        (inverseDistance):
     19        (createGraph):
     20        (startSources):
     21        (equalPowerGain):
     22        (checkDistanceResult.return.renderedBuffer):
     23        (checkDistanceResult):
     24
    1252012-02-02  Raymond Toy  <rtoy@google.com>
    226
  • trunk/Source/WebCore/ChangeLog

    r106579 r106580  
     12012-02-02  Raymond Toy  <rtoy@google.com>
     2
     3        Constant values to set "distanceModel" are undefined
     4        https://bugs.webkit.org/show_bug.cgi?id=74273
     5
     6        Reviewed by Kenneth Russell.
     7
     8        Tests: webaudio/distance-exponential.html
     9               webaudio/distance-inverse.html
     10               webaudio/distance-linear.html
     11
     12        * webaudio/AudioPannerNode.h: Define enum for the new constants
     13        for the distance models.
     14        * webaudio/AudioPannerNode.idl: Define matching constants for the
     15        distance models.
     16
    1172012-02-02  Raymond Toy  <rtoy@google.com>
    218
  • trunk/Source/WebCore/webaudio/AudioPannerNode.h

    r106579 r106580  
    5454    };
    5555
     56    // These must be defined as in the .idl file and must match those
     57    // in the DistanceEffect class.
     58    enum {
     59        LINEAR_DISTANCE = 0,
     60        INVERSE_DISTANCE = 1,
     61        EXPONENTIAL_DISTANCE = 2,
     62    };
     63   
    5664    static PassRefPtr<AudioPannerNode> create(AudioContext* context, float sampleRate)
    5765    {
  • trunk/Source/WebCore/webaudio/AudioPannerNode.idl

    r106579 r106580  
    3333        const unsigned short SOUNDFIELD = 2;
    3434
     35        // Distance model
     36        const unsigned short LINEAR_DISTANCE = 0;
     37        const unsigned short INVERSE_DISTANCE = 1;
     38        const unsigned short EXPONENTIAL_DISTANCE = 2;
     39
    3540        // Default model for stereo is HRTF
    3641        // FIXME: use unsigned short when glue generation supports it
Note: See TracChangeset for help on using the changeset viewer.