Wwise SDK 2025.1.1
|
#include <AkCommandTypes.h>
公開変数類 | |
AkUInt64 | nodeID |
ID of the bus, Container node, or output device. When nodeType is set to AkNodeType_AudioDevice , a value of 0 designates the main (default) output. [詳解] | |
AkUInt8 | nodeType |
Type of node that nodeID refers to. Must be a valid value from the AkNodeType enumeration. [詳解] | |
AkUInt8 | fxIndex |
Effect slot index (0-254) [詳解] | |
AkUniqueID | fxSharesetID |
ShareSet ID of the effect; pass AK_INVALID_UNIQUE_ID to clear the Effect slot [詳解] | |
Sets an Effect ShareSet at the specified slot of a container, bus, or output device.
![]() | 注釈: Replacing effects is preferably done through a Set Effect Event Action. |
This operation adds a reference on the audio node to an existing ShareSet.
To specify a bus, set nodeType
to AkNodeType_Bus
. The bus can be an Audio Bus or an Auxiliary Bus.
To specify an output device, set nodeType
to AkNodeType_AudioDevice
. The ID can refer to a specific ID returned by AK::SoundEngine::GetOutputID
or 0 to designate the main (default) output device. In this case, only audio device effect sharesets are accepted.
When specifying any other container (e.g. Switch, Blend, Sound SFX, etc.) set nodeType
to AkNodeType_Default
.
![]() | 注釈: This function has unspecified behavior when adding an Effect to a currently playing Bus which does not have any Effects, or removing the last Effect on a currently playing bus. |
![]() | 注釈: This function will replace existing Effects on the node. If the target node is not at the top of the hierarchy and is in the Containers hierarchy, the option "Override Parent" in the Effect section in Wwise must be enabled for this node, otherwise the parent's Effect will still be the one in use and SetEffect will have no impact. |
This command can fail for the following reasons:
AK_InvalidParameter
when nodeID
is an invalid ID, or when fxIndex
or nodeType
is out of range.AK_IDNotFound
when either the Node ID or the Shareset ID are not present in the Init bank.AK_RenderedFX
when the current effect in the slot is rendered at bank-generation time (rendered effects cannot be replaced).AK_NotCompatible
when nodeType
is AkNodeType_AudioDevice
and the effect shareset is not an output device effect.AK_InsufficientMemory
when there is not enough memory to complete the operation.AkCommandTypes.h の 1003 行目に定義があります。