Firelight Technologies FMOD Ex


For any sound that has subsounds, this function will determine the order of playback of these subsounds, and it will play / stitch together the subsounds without gaps.
  This is a very useful feature for those users wanting to do seamless / gapless stream playback. (ie sports commentary, gapless playback media players etc). 

C++ Syntax

FMOD_RESULT Sound::setSubSoundSentence(
  int *  subsoundlist, 
  int  numsubsounds

C Syntax

FMOD_RESULT FMOD_Sound_SetSubSoundSentence(
  FMOD_SOUND *  sound,
  int *  subsoundlist, 
  int  numsubsounds



Pointer to an array of indicies which are the subsounds to play. One subsound can be included in this list multiple times if required.


Number of indicies inside the subsoundlist array.


Return Values

If the function succeeds then the return value is FMOD_OK.
If the function fails then the return value will be one of the values defined in the FMOD_RESULT enumeration.



The currently playing subsound in a sentence can be found with Channel::getPosition and the timeunit FMOD_TIMEUNIT_SENTENCE_SUBSOUND. This is useful for displaying the currently playing track of a cd in a whole CD sentence for example.
For realtime stitching purposes, it is better to know the buffered ahead of time subsound index. This can be done by adding the flag (using bitwise OR) FMOD_TIMEUNIT_BUFFERED.
If FMOD_ERR_SUBSOUND_MODE is returned, then FMOD_CREATECOMPRESSEDSAMPLE has been used on a child sound, but not on the parent sound, or vice versa. Another cause of this is trying to mix a static sample with a streaming sound. Mode bits to do with this must match.
A user can change subsounds that are not playing at the time, to do dynamic stitching/sentencing of sounds.


See Also



Version 4.44.07 Built on Feb 11, 2013