summaryrefslogtreecommitdiff
path: root/Source/WebCore/Modules/webaudio/PannerNode.idl
diff options
context:
space:
mode:
Diffstat (limited to 'Source/WebCore/Modules/webaudio/PannerNode.idl')
-rw-r--r--Source/WebCore/Modules/webaudio/PannerNode.idl49
1 files changed, 28 insertions, 21 deletions
diff --git a/Source/WebCore/Modules/webaudio/PannerNode.idl b/Source/WebCore/Modules/webaudio/PannerNode.idl
index ee0bb287f..fc991bf94 100644
--- a/Source/WebCore/Modules/webaudio/PannerNode.idl
+++ b/Source/WebCore/Modules/webaudio/PannerNode.idl
@@ -24,36 +24,43 @@
[
Conditional=WEB_AUDIO,
+ ImplementedAs=PanningModelType
+] enum PanningModelType {
+ "equalpower",
+ "HRTF"
+};
+
+[
+ Conditional=WEB_AUDIO,
+ ImplementedAs=DistanceModelType
+] enum DistanceModelType {
+ "linear",
+ "inverse",
+ "exponential"
+};
+
+[
+ Conditional=WEB_AUDIO,
JSGenerateToJSObject,
InterfaceName=webkitAudioPannerNode,
] interface PannerNode : AudioNode {
- // Panning model
- const unsigned short EQUALPOWER = 0;
- const unsigned short HRTF = 1;
- const unsigned short SOUNDFIELD = 2;
-
- // Distance model
- const unsigned short LINEAR_DISTANCE = 0;
- const unsigned short INVERSE_DISTANCE = 1;
- const unsigned short EXPONENTIAL_DISTANCE = 2;
-
// Default model for stereo is HRTF
- [CustomSetter] attribute DOMString panningModel;
+ attribute PanningModelType panningModel;
// Uses a 3D cartesian coordinate system
- void setPosition(float x, float y, float z);
- void setOrientation(float x, float y, float z);
- void setVelocity(float x, float y, float z);
+ void setPosition(unrestricted float x, unrestricted float y, unrestricted float z);
+ void setOrientation(unrestricted float x, unrestricted float y, unrestricted float z);
+ void setVelocity(unrestricted float x, unrestricted float y, unrestricted float z);
// Distance model
- [CustomSetter] attribute DOMString distanceModel;
+ attribute DistanceModelType distanceModel;
- attribute double refDistance;
- attribute double maxDistance;
- attribute double rolloffFactor;
+ attribute unrestricted double refDistance;
+ attribute unrestricted double maxDistance;
+ attribute unrestricted double rolloffFactor;
// Directional sound cone
- attribute double coneInnerAngle;
- attribute double coneOuterAngle;
- attribute double coneOuterGain;
+ attribute unrestricted double coneInnerAngle;
+ attribute unrestricted double coneOuterAngle;
+ attribute unrestricted double coneOuterGain;
};