Previous Book Contents Book Index Next

Inside Macintosh: Apple Game Sprockets Guide /
Chapter 1 - SoundSprocket / SoundSprocket Reference
SoundSprocket Functions / Creating and Managing Listeners


SSpListener_SetOrientation

You can use the SSpListener_SetOrientation function to set the orientation of a listener.

OSStatus SSpListener_SetOrientation (
SSpListenerReference inListenerReference,
const TQ3Vector3D *inOrientation);
inListenerReference
A listener reference.
inOrientation
The desired untransformed orientation of the listener. This orientation should be a unit vector.
function result
A result code.
DESCRIPTION
The SSpListener_SetOrientation function sets the orientation of the listener specified by the inListenerReference parameter to the orientation specified by the inOrientation parameter. The inOrientation parameter specifies the untransformed orientation of the listener (that is, the orientation of the listener before the listener's transform is applied). The actual orientation of the listener is calculated at the time you call the SSpSource_CalcLocalization function. The default orientation of a listener is the unit x vector (1, 0, 0).

SPECIAL CONSIDERATIONS
When you call SSpSource_CalcLocalization, the listener's orientation and up vectors should not be parallel.


Previous Book Contents Book Index Next

© Apple Computer, Inc.
2 JUL 1996