Miles Sound System SDK 7.2a

AIL_sample_output_levels

The function AIL_sample_output_levels returns the final mixer level-scaling factors for one or more combinations of source channels and destination speakers.

void AIL_sample_output_levels(
  HSAMPLE S,
  MSS_SPEAKER const * source_speaker_indexes,
  MSS_SPEAKER const * dest_speaker_indexes,
  F32 *level_array,
  S32 n_levels
);

In Parameters

S
indicates the HSAMPLE for which the mixer output levels are to be retrieved.
source_speaker_indexes
specifies an array of one or more channels in the source data.
dest_speaker_indexes
specifies an array of one or more speakers.
n_levels
specifies the number of entries in level_array, source_speaker_indexes, and dest_speaker_indexes.

Out Parameters

level_array
an array of coefficients from 0.0 to 1.0 which represent the amplitude levels of the given sample channels at the given speakers.

Discussion

This function lets you retrieve the per-channel volume scale factors that result from all dry-path attenuation processes inside MSS. These factors are derived from the products of 3D distance and cone attenuation (if any), obstruction, per-sample and per-speaker reverb dry levels, volume/pan control, the DIG_LEVEL_RAMP_SAMPLES process, and per-sample channel levels associated with the AIL_set_sample_channel_levels function. (They do not include any modifications to the actual sample values performed by DSP pipeline filters.)

This function will have no effect with per-voice hardware drivers that don't use the Miles software mixer. Currently, this applies only to the Xbox 1 and MSS_MC_DIRECTSOUND3D and MSS_MC_EAX? values from the MSS_MC_SPEC list.

Uses for this function include dynamic prioritization of samples and audio pipeline debugging.

For a detailed understanding of per-channel level control, you should carefully review the How do I use multi-channel sound output in Miles? FAQ before attempting to use this function. You may also wish to examine the Digital Audio Pipeline section.


Group: Digital Audio Services, The Digital Audio Pipeline
Related Functions: AIL_set_sample_channel_levels
Related Basic Types: F32, HSAMPLE, MILES_PREFERENCES, MSS_MC_SPEC, MSS_SPEAKER, S32, void
Related FAQs: How do I use multi-channel sound output in Miles?

For technical support, e-mail Miles3@radgametools.com
© Copyright 1991-2007 RAD Game Tools, Inc. All Rights Reserved.