Mixerclass
Takes a bunch of sound, changes its volumes, mixes it together, outputs it
Methods20
Showing 20 methods
public void AddProcessor(Sandbox.Audio.AudioProcessor ap)
| Parameter | Type | Description |
|---|---|---|
| ap | AudioProcessor | — |
void—public void ClearProcessors()
void—public void Deserialize(System.Text.Json.Nodes.JsonObject js, Sandbox.Internal.TypeLibrary typeLibrary)
| Parameter | Type | Description |
|---|---|---|
| js | JsonObject | — |
| typeLibrary | TypeLibrary | — |
void—public void Destroy()
void—public static Sandbox.Audio.Mixer FindMixerByGuid(System.Guid guid)
| Parameter | Type | Description |
|---|---|---|
| guid | Guid | — |
public static Sandbox.Audio.Mixer FindMixerByName(string name)
| Parameter | Type | Description |
|---|---|---|
| name | string | — |
public Sandbox.TagSet GetBlockingTags()
Walks the parent chain. If either local tag set is non-empty, returns this mixer's `Sandbox.Audio.Mixer.BlockingTags`; otherwise inherits from parent. Resolved together with `Sandbox.Audio.Mixer.GetIgnoredTags` to avoid split-brain.
public Sandbox.TagSet GetIgnoredTags()
Walks the parent chain. See `Sandbox.Audio.Mixer.GetBlockingTags` for inheritance rules.
public System.Collections.Generic.IReadOnlySet`1<uint> GetOcclusionTags()
Get an array of occlusion tags our sounds want to hit. May return null if there are none defined!
Obsolete: Use GetBlockingTags() instead.
IReadOnlySet<uint>—public T GetProcessor()
T—public Sandbox.Audio.AudioProcessor[] GetProcessors()
public bool IsDescendantOf(Sandbox.Audio.Mixer mixer)
Returns true if this mixer is a descendant of the given mixer.
| Parameter | Type | Description |
|---|---|---|
| mixer | Mixer | — |
bool—public void RemoveProcessor(Sandbox.Audio.AudioProcessor ap)
| Parameter | Type | Description |
|---|---|---|
| ap | AudioProcessor | — |
void—public static void ResetToDefault()
void—public System.Text.Json.Nodes.JsonObject Serialize()
JsonObject—protected void SetMasterOcclusionDefaults()
void—protected void SetMasterSimulationTagDefaults()
void—public void StopAll(float fade)
Stop all sound handles using this mixer
| Parameter | Type | Description |
|---|---|---|
| fade | float | — |
void—No results match this filter.
Properties23
Showing 23 properties
public float Sandbox.Audio.Mixer.AirAbsorption { get; set; }
How much the air absorbs energy from the sound
float—public Sandbox.TagSet Sandbox.Audio.Mixer.BlockingTags { get; set; }
If non-empty, audio simulation traces (occlusion, transmission, reverb rays) only register hits on bodies with one of these tags. Empty = hit everything that isn't in `Sandbox.Audio.Mixer.IgnoredTags`.
public int Sandbox.Audio.Mixer.ChildCount { get; set; }
int—public float Sandbox.Audio.Mixer.DistanceAttenuation { get; set; }
Sounds get quieter as they go further away
float—public System.Guid Sandbox.Audio.Mixer.Id { get; set; }
Unique identifier for this object, for lookup, deserialization etc
Guid—public Sandbox.TagSet Sandbox.Audio.Mixer.IgnoredTags { get; set; }
Audio simulation traces always skip bodies with these tags (e.g. triggers, sky, passaudio). Applied on top of `Sandbox.Audio.Mixer.BlockingTags`.
public bool Sandbox.Audio.Mixer.IsMaster { get; set; }
The default mixer gets all sounds that don't have a mixer specifically assigned
bool—public int Sandbox.Audio.Mixer.MaxVoices { get; set; }
The maximum amount of voices to play at one time on this mixer
int—public Sandbox.Audio.AudioMeter Sandbox.Audio.Mixer.Meter { get; set; }
Allows monitoring of the output of the mixer
public bool Sandbox.Audio.Mixer.Mute { get; set; }
Is this mixer muted?
bool—public string Sandbox.Audio.Mixer.Name { get; set; }
The display name for this mixer
string—public float Sandbox.Audio.Mixer.Occlusion { get; set; }
How much these sounds can get occluded (0 = no occlusion simulation, 1 = full).
float—public Sandbox.TagSet Sandbox.Audio.Mixer.OcclusionTags { get; set; }
The tags which occlude our physics.
Obsolete: Use BlockingTags instead.
public bool Sandbox.Audio.Mixer.OverrideOcclusion { get; set; }
If true then this mixer will use custom occlusion tags. If false we'll use what our parent uses.
Obsolete: Use OverrideOcclusion + BlockingTags / IgnoredTags instead.
bool—public int Sandbox.Audio.Mixer.ProcessorCount { get; set; }
int—public float Sandbox.Audio.Mixer.Reverb { get; set; }
How much reverb is applied to sounds routed through this mixer (0 = dry / disabled, 1 = full).
float—public bool Sandbox.Audio.Mixer.Solo { get; set; }
Should this be the only mixer that is heard?
bool—public float Sandbox.Audio.Mixer.Spacializing { get; set; }
Legacy misspelled alias for `Sandbox.Audio.Mixer.Spatializing`.
Obsolete: Use Spatializing instead.
float—public float Sandbox.Audio.Mixer.Spatializing { get; set; }
When 0 the sound will come out of all speakers, when 1 it will be fully spatialized
float—public float Sandbox.Audio.Mixer.Volume { get; set; }
Scale the volume of our output by this amount
float—No results match this filter.