FVolumeFader

Control-rate fader for managing volume fades of various standard shapes.

Windows
MacOS
Linux

References

Module

SignalProcessing

Header

/Engine/Source/Runtime/SignalProcessing/Public/DSP/VolumeFader.h

Include

#include "DSP/VolumeFader.h"

Syntax

class FVolumeFader

Remarks

Control-rate fader for managing volume fades of various standard shapes.

Constructors

Name Description

Public function

FVolumeFader()

Functions

Name Description

Public function

void

 

Activate()

Activates the fader if currently deactivated. Sets duration to indefinite (-1.0f)

Public function

void

 

Deactivate()

Deactivates the fader, causing it to remain at the current value and disregard update.

Public function Const

float

 

GetActiveDuration()

Gets time fader is to remain active (-1.0f if always active).

Public function Const

EFaderCurve

 

GetCurve()

Returns the curve type of the fader

Public function Const

float

 

GetFadeDuration()

Returns the duration of the fade.

Public function Const

float

 

GetTargetVolume()

Returns the target volume of the fader

Public function Const

float

 

GetVolume()

Returns current volume of fader

Public function Const

float

 

GetVolumeAfterTime

(
    float InDeltaTime
)

Returns the volume given the delta from the current time into the future (Effectively like running to retrieve volume but without actually updating internal state).

Public function Const

bool

 

IsActive()

Whether or not the fader is active.

Public function Const

bool

 

IsFading()

Returns whether or not the fader is currently fading over time.

Public function Const

bool

 

IsFadingIn()

Returns whether or not the fader is currently fading over time and value is increasing.

Public function Const

bool

 

IsFadingOut()

Returns whether or not the fader is currently fading over time and value is decreasing.

Public function

void

 

SetActiveDuration

(
    float InDuration
)

Sets the duration the fader is to be active in the future, after which point the fader is disabled.

Public function

void

 

SetVolume

(
    float InVolume
)

Sets the volume immediately, interrupting any currently active fade.

Public function

void

 

StartFade

(
    float InVolume,
    float InDuration,
    EFaderCurve InCurve
)

Applies a volume fade over time with the provided parameters.

Public function

void

 

StopFade()

Stops fade, maintaining the current value as the target.

Public function

void

 

Update

(
    float InDeltaTime
)

Updates the fader's state with the given delta in time since last update.

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss