N64® Functions Menu
|
al - Audio Library Functions
gDP - DP GBI Macros
gdSP - General GBI Macros
gSP - SP GBI Macros
gt - Turbo Microcode RDP
gu - Graphics Utilities
Math - Math Functions
nuSys - NuSystem
os - N64 Operating System
sp - Sprite Library Functions
uh - Host to Target IO
64DD - N64 Disk Drive
|
|
alSynStartVoiceParams
Syntax
#include <libaudio.h>
void alSynStartVoiceParams(ALSynth *drvr,
ALVoice *voice, ALWaveTable *tbl,
f32 pitch, s16 vol,
ALPan pan, u8 fxmix,
ALMicroTime time);
Arguments
- drvr is the pointer to the synthesizer driver
- voice is the pointer to a voice
- tbl is the pointer to a sound wavetable
- pitch is the float value describing the pitch ratio
- vol is the volume to use for playback
- pan is the stereo pan to use for playback
- fxmix is the relative mix of the effect's processed signal to unprocessed signal
- time is the time in Microseconds for the sound to reach the specified volume level
Explanation
It begins generating entries into the command lists created by alAudioFrame to synthesize audio samples for the given voice from sample data in the wavetable pointed to by the table.
Before calling this function, use the specified arguments to allocate the voice from the driver by calling alSynAllocVoice. The alSynAllocVoice function isn't always
successful, so be sure to check the result before you call alSynStartVoiceParams.
Valid values for pitch, pan, fxmix, and volume are
detailed in the following pages:
alSynSetPitch
alSynSetPan
alSynSetFXMix
alSynSetVol
When the voice has finished sounding, you can call alSynStopVoice, and then call alSynFreeVoice.
Warning
The synthesis driver expects that the loop data and adpcm book data (if
it is a compressed wavetable) are located in DRAM. The actual wavetable data can
be located in ROM and later moved (using DMA) into DRAM, but the loop and book data
are accessed before the DMA occurs. This is important when you are writing a
custom bank file.
When you are writing a custom player, this function (alSynStartVoiceParams) should be called only
from within an ALVoiceHandler. Also, do not set any of the voice's arguments (for example, don't call alSynSetVol) if the voice is in the stopped state unless
the voice is started in the same audio frame. If you call a function to set a stopped voice's arguments and the voice is not started until one or more frames later, you'll get unexpected results.
See Also
alSynAllocVoice
alSynStopVoice
alSynFreeVoice
alSynStartVoice
alAudioFrame
|
Nintendo® Confidential
Warning: all information in this document is confidential and covered by a non-disclosure agreement. You are responsible for keeping this information confidential and protected. Nintendo will vigorously enforce this responsibility.
Copyright © 1998
Nintendo of America Inc. All rights reserved Nintendo and N64 are registered trademarks of Nintendo
Last Updated April, 1999
|
|