Previous Book Contents Book Index Next

Inside Macintosh: Apple Game Sprockets Guide /
Chapter 1 - SoundSprocket / SoundSprocket Reference
SoundSprocket Functions / Creating and Managing 3D Sound Sources


SSpSource_SetOrientation

You can use the SSpSource_SetOrientation function to set the orientation of a sound source.

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

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


Previous Book Contents Book Index Next

© Apple Computer, Inc.
2 JUL 1996