AXSetMultiVoiceDeviceMix

Syntax

#include <cafe/ax.h>

AXPB_ERROR_CODE AXSetMultiVoiceDeviceMix (AXMVPB *mv, AXPBDeviceType device,
                                          u32 Id, AXPBBusType bus, u16 vol, s16 volDelta);

Parameters

mv Pointer to the multi-voice.
device Output device.
Id Device ID.
bus Bus type.
vol Volume applied to each voice in the multi-voice (Unity = 0x8000).
volDelta Value added to the currentVolume for each audio sample that the voices play in the next audio frame.

Return Values

Zero if successful, an error of type AXPB_ERROR_CODE otherwise.

Description

Applies the volume and volume-delta values to each of the voice's output device (specified by device, Id, and bus) of multi-voice mv.

The values vol and volDelta define what volume a voice will be played at on the specified device and bus. If a voice has a nonzero volume on a given bus, it will have its audio data played on that bus, increasing the computational load of playing the multi-voice.

The multi-voice channel count should not exceed max number of channels for the device. For TV, the mv should be have no more than AX_MAX_NUM_TV_CHS (6 for Wii U); for DRC, it should contain AX_MAX_NUM_DRC_CHS channels and for remotes AX_MAX_NUM_RMT_CHS.

This function is not to be confused with functions in the MIX library. The MIX library is essentially built upon this function and provides high-level control over AXPBCHMIX structures for each voice.

Compatibility

Library Version Compatibility
Sound 2.0 Yes
Sound 1.0 No

Do Not Call From

None.

See Also

AXPBCHMIX
AXSetMultiVoiceVe

Revision History

2013/10/20 Initial Version


CONFIDENTIAL