unreal.AudioModulationStatics
¶
- class unreal.AudioModulationStatics(outer: Object | None = None, name: Name | str = 'None')¶
Bases:
BlueprintFunctionLibrary
namespace AudioModulation
C++ Source:
Plugin: AudioModulation
Module: AudioModulation
File: AudioModulationStatics.h
- classmethod activate_bus(world_context_object, bus) None ¶
Manually activates a modulation bus. If called, deactivation will only occur if bus is manually deactivated or destroyed (i.e. will not deactivate when all references become inactive).
- Parameters:
world_context_object (Object) –
bus (SoundControlBus) –
- classmethod activate_bus_mix(world_context_object, mix) None ¶
Manually activates a bus modulator mix. If called, deactivation will only occur if mix is manually deactivated and not referenced or destroyed (i.e. will not deactivate when all references become inactive).
- Parameters:
world_context_object (Object) –
mix (SoundControlBusMix) –
- classmethod activate_generator(world_context_object, generator) None ¶
Manually activates a modulation generator. If called, deactivation will only occur if generator is manually deactivated and not referenced or destroyed (i.e. will not deactivate when all references become inactive).
- Parameters:
world_context_object (Object) –
generator (SoundModulationGenerator) –
- classmethod clear_all_global_bus_mix_values(world_context_object, fade_time=-1.000000) None ¶
Clears all global control bus mix values if set, using the applied fade time to return all to their respective bus’s parameter default value.
- classmethod clear_global_bus_mix_value(world_context_object, bus, fade_time=-1.000000) None ¶
Clears global control bus mix if set, using the applied fade time to return to the provided bus’s parameter default value.
- Parameters:
world_context_object (Object) –
bus (SoundControlBus) – Bus associated with mix to update
fade_time (float) – Fade time to user when interpolating between current value and new values. If non-positive, change is immediate.
- classmethod create_bus(world_context_object, name, parameter, activate=True) SoundControlBus ¶
Creates a modulation bus with the provided default value.
- Parameters:
world_context_object (Object) –
name (Name) – Name of bus
parameter (SoundModulationParameter) – Default value for created bus
activate (bool) – Whether or not to activate bus on creation. If true, deactivation will only occur if returned bus is manually deactivated and not referenced or destroyed (i.e. will not deactivate when all references become inactive).
- Returns:
Capture this in a Blueprint variable to prevent it from being automatically garbage collected.
- Return type:
- classmethod create_bus_mix(world_context_object, name, stages, activate) SoundControlBusMix ¶
Creates a modulation bus mix, with a bus stage set to the provided target value.
- Parameters:
world_context_object (Object) –
name (Name) – Name of mix.
stages (Array[SoundControlBusMixStage]) – Stages mix is responsible for.
activate (bool) – Whether or not to activate mix on creation. If true, deactivation will only occur if returned mix is manually deactivated and not referenced or destroyed (i.e. will not deactivate when all references become inactive).
- Returns:
Capture this in a Blueprint variable to prevent it from being garbage collected.
- Return type:
- classmethod create_bus_mix_stage(world_context_object, bus, value, attack_time=0.100000, release_time=0.100000) SoundControlBusMixStage ¶
Creates a stage used to mix a control bus.
- Parameters:
world_context_object (Object) –
bus (SoundControlBus) – Bus stage is in charge of applying mix value to.
value (float) – Value for added bus stage to target when mix is active.
attack_time (float) – Time in seconds for stage to mix in.
release_time (float) – Time in seconds for stage to mix out.
- Return type:
- classmethod create_envelope_follower_generator(world_context_object, name, params) SoundModulationGeneratorEnvelopeFollower ¶
Creates a modulation generator based on an Envelope Follower with the given parameters.
- Parameters:
world_context_object (Object) –
name (Name) – Name of generator.
params (EnvelopeFollowerGeneratorParams) –
- Returns:
Capture this in a Blueprint variable to prevent it from being garbage collected.
- Return type:
- classmethod create_lfo_generator(world_context_object, name, params) SoundModulationGeneratorLFO ¶
Creates a modulation generator based on an LFO with the given parameters.
- Parameters:
world_context_object (Object) –
name (Name) – Name of generator.
params (SoundModulationLFOParams) –
- Returns:
Capture this in a Blueprint variable to prevent it from being garbage collected.
- Return type:
- classmethod deactivate_bus(world_context_object, bus) None ¶
Deactivates a bus. Does nothing if the provided bus is already inactive.
- Parameters:
world_context_object (Object) –
bus (SoundControlBus) – Scope of modulator
- classmethod deactivate_bus_mix(world_context_object, mix) None ¶
Deactivates a modulation bus mix. Does nothing if an instance of the provided bus mix is already inactive.
- Parameters:
world_context_object (Object) –
mix (SoundControlBusMix) –
- classmethod deactivate_generator(world_context_object, generator) None ¶
Deactivates a modulation generator. Does nothing if an instance of the provided generator is already inactive.
- Parameters:
world_context_object (Object) –
generator (SoundModulationGenerator) – Generator to activate
- classmethod get_modulator_value(world_context_object, modulator) float ¶
Gets the (normalized) value of the given modulator.
- Parameters:
world_context_object (Object) –
modulator (SoundModulatorBase) –
- Returns:
Value - The current value of the modulator. If the modulator is not active, returns 1.0.
- Return type:
- classmethod get_modulators_from_destination(destination) Set[SoundModulatorBase] ¶
Gets the list of modulators currently applied to a Modulation Destination.
- Parameters:
destination (SoundModulationDestinationSettings) – The Modulation Destination.
- Returns:
Modulators - The set of Modulators.
- Return type:
- classmethod load_mix_from_profile(world_context_object, mix, activate=True, profile_index=0) Array[SoundControlBusMixStage] ¶
Loads control bus mix from a profile into UObject mix definition, deserialized from an ini file.
- Parameters:
world_context_object (Object) –
mix (SoundControlBusMix) –
activate (bool) – If true, activate mix upon loading from profile.
profile_index (int32) – Index of profile, allowing multiple profiles to be loaded to single mix object. If <= 0, loads from default profile (no suffix).
- Returns:
Stages - Stage values loaded from profile (empty if profile did not exist or had no values serialized).
- Return type:
- classmethod save_mix_to_profile(world_context_object, mix, profile_index=0) None ¶
Saves control bus mix to a profile, serialized to an ini file. If mix is loaded, uses current proxy’s state. If not, uses default UObject representation.
- Parameters:
world_context_object (Object) –
mix (SoundControlBusMix) –
profile_index (int32) – Index of profile, allowing multiple profiles can be saved for single mix object. If 0, saves to default ini profile (no suffix).
- classmethod set_global_bus_mix_value(world_context_object, bus, value, fade_time=-1.000000) None ¶
Sets a Global Control Bus Mix with a single stage associated with the provided Bus to the given float value. This call should be reserved for buses that are to be always active. It is NOT recommended for transient buses, as not calling clear can keep buses active indefinitely.
- Parameters:
world_context_object (Object) –
bus (SoundControlBus) – Bus associated with mix to update
value (float) – Value to set global stage to.
fade_time (float) – Fade time to user when interpolating between current value and new value. If negative, falls back to last fade time set on stage. If fade time never set on stage, defaults to 100ms.
- classmethod update_mix(world_context_object, mix, stages, fade_time=-1.000000) None ¶
Sets a Control Bus Mix with the provided stage data, if the stages are provided in an active instance proxy of the mix. Does not update UObject definition of the mix.
- Parameters:
world_context_object (Object) –
mix (SoundControlBusMix) – Mix to update
stages (Array[SoundControlBusMixStage]) – Stages to set. If stage’s bus is not referenced by mix, stage’s update request is ignored.
fade_time (float) – Fade time to user when interpolating between current value and new values. If negative, falls back to last fade time set on stage. If fade time never set on stage, uses attack time set on stage in mix asset.
- classmethod update_mix_by_filter(world_context_object, mix, address_filter, param_class_filter, param_filter, value=1.000000, fade_time=-1.000000) None ¶
Sets filtered stages of a given class to a provided target value for active instance of mix. Does not update UObject definition of mix.
- Parameters:
world_context_object (Object) –
mix (SoundControlBusMix) – Mix to modify
address_filter (str) – (Optional) Address filter to apply to provided mix’s stages.
param_class_filter (type(Class)) – (Optional) Filters buses by parameter class.
param_filter (SoundModulationParameter) – (Optional) Filters buses by parameter.
value (float) – Target value to mix filtered stages to.
fade_time (float) – If non-negative, updates the fade time for the resulting bus stages found matching the provided filter.
- classmethod update_mix_from_object(world_context_object, mix, fade_time=-1.000000) None ¶
Commits updates from a UObject definition of a bus mix to active instance in audio thread (ignored if mix has not been activated).
- Parameters:
world_context_object (Object) –
mix (SoundControlBusMix) – Mix to update
fade_time (float) – Fade time to user when interpolating between current value and new values. If negative, falls back to last fade time set on stage. If fade time never set on stage, uses attack time set on stage in mix asset.
- classmethod update_modulator(world_context_object, modulator) None ¶
Commits updates from a UObject definition of a modulator (e.g. Bus, Bus Mix, Generator) to active instance in audio thread (ignored if modulator type has not been activated).
- Parameters:
world_context_object (Object) –
modulator (SoundModulatorBase) – Modulator to update