Version

menu_open
Attention : vous avez été redirigé vers la plus récente documentation correspondant à votre version générale ( 2023.1.3.8471 ). Si vous souhaitez accéder à la documentation de votre version précise, veuillez télécharger la documentation hors ligne depuis l'Audiokinetic Launcher et sélectionner l'option de documentation Offline dans l'application de création Wwise.
Wwise SDK 2023.1.3

◆ SetRTPCValue() [1/2]

AKSOUNDENGINE_API AKRESULT AK::SoundEngine::SetRTPCValue ( AkRtpcID  in_rtpcID,
AkRtpcValue  in_value,
AkGameObjectID  in_gameObjectID = AK_INVALID_GAME_OBJECT,
AkTimeMs  in_uValueChangeDuration = 0,
AkCurveInterpolation  in_eFadeCurve = AkCurveInterpolation_Linear,
bool  in_bBypassInternalValueInterpolation = false 
)

Sets the value of a real-time parameter control (by ID). With this function, you may set a game parameter value with global scope or with game object scope. Game object scope supersedes global scope. (Once a value is set for the game object scope, it will not be affected by changes to the global scope value.) Game parameter values set with a global scope are applied to all game objects that not yet registered, or already registered but not overridden with a value with game object scope. To set a game parameter value with global scope, pass AK_INVALID_GAME_OBJECT as the game object. With this function, you may also change the value of a game parameter over time. To do so, specify a non-zero value for in_uValueChangeDuration. At each audio frame, the game parameter value will be updated internally according to the interpolation curve. If you call SetRTPCValue() with in_uValueChangeDuration = 0 in the middle of an interpolation, the interpolation stops and the new value is set directly. Thus, if you call this function at every game frame, you should not use in_uValueChangeDuration, as it would have no effect and it is less efficient. Refer to RTPCs and Game Objects, RTPCs and Busses and RTPCs and Plug-Ins for more details on RTPC scope.

Returns
  • AK_Success if the value was successfully set
  • AK_InvalidFloatValue if the value specified was NaN, Inf or FLT_MAX (3.402823e+38)
  • AK_InvalidID if in_rtpcID is AK_INVALID_UNIQUE_ID (0)
See also
Parameters
in_rtpcIDID of the game parameter
in_valueValue to set
in_gameObjectIDAssociated game object ID
in_uValueChangeDurationDuration during which the game parameter is interpolated towards in_value
in_eFadeCurveCurve type to be used for the game parameter interpolation
in_bBypassInternalValueInterpolationTrue if you want to bypass the internal "slew rate" or "over time filtering" specified by the sound designer. This is meant to be used when for example loading a level and you dont want the values to interpolate.

Cette page a-t-elle été utile ?

Besoin d'aide ?

Des questions ? Des problèmes ? Besoin de plus d'informations ? Contactez-nous, nous pouvons vous aider !

Visitez notre page d'Aide

Décrivez-nous de votre projet. Nous sommes là pour vous aider.

Enregistrez votre projet et nous vous aiderons à démarrer sans aucune obligation !

Partir du bon pied avec Wwise