Version

menu_open
Wwise SDK 2023.1.8
Quick Start Sample Integration - RTPCs

RTPC Example

RTPCs let the sound engine compute a property's value by evaluating a curve, defined by the Wwise user, for the X value that corresponds to a parameter within the game. For example, the following code sets the value of the "RPM" game parameter:

In the sample program you can experiment with RTPCs in two ways:

  • In the Car section, select the Play_Engine event, click Post, then move the RPM slider. This changes the value of the RPM game parameter which the engine sound uses to alter its volume and pitch properties
  • In the Human section, check/uncheck the "Enable Effect" checkbox, then click on Talk. When the checkbox is checked, the "Enable_Effect" game parameter is set to 100. When its unchecked the game parameter is set to 0. The Voices control bus uses this game parameter to set/clear its "Bypass Effect" property.

Refer to Integration Details - RTPCs for more details.

Note: This sample code comes from the Sound Engine Integration Sample Project available in the Samples section. Refer to Integration Demo Sample for more information.
AKSOUNDENGINE_API AKRESULT 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)
AkReal32 AkRtpcValue
Real time parameter control value.
Definition: AkTypes.h:74

Was this page helpful?

Need Support?

Questions? Problems? Need more info? Contact us, and we can help!

Visit our Support page

Tell us about your project. We're here to help.

Register your project and we'll help you get started with no strings attached!

Get started with Wwise