Engine → Audio
mix_groups.h
Mix groups: a gain tree rooted at MASTER_GROUP. The main thread owns the tree and sends each group's effective gain (the product up the chain) and effective paused flag (its own flag or any ancestor's) to the mixer.
Structs
| File |
Description |
group_desc |
What create_group() needs. The parent is given by id, or by name through parentName when groups are declared in settings before any id exists (a null parentName means "use parent"). |
group_id |
Handle of a mix group: slot index plus the generation issued when the slot was last created. remove_group() retires the id at once and a reused slot gets a new generation, so stale ids are rejected. |
group_info |
Main-thread view of a group. paused is the group's own flag (what set_group_paused() last stored); effectivePaused says whether its voices are frozen, which is also the case while any ancestor is paused. |
Constants
| Name |
Type |
Value |
Description |
MASTER_GROUP |
inline constexpr group_id |
{0, 1} |
The root group, always present, never removable. |
Functions
Public
clamp_group_gain
[[nodiscard]] CONJURE_API f32 clamp_group_gain(
f32 gain) noexcept;
Clamp rule for group gains: [0, 2], NaN becomes 1.