MIX_GetTrackGain(3)

πŸ“¦
version 3.2.4 Β· 2 versions
, in fedora 44

✨ MIX_GetTrackGain(3) ✨

okay bestie, welcome to the SDL_mixer3 corner of the manual, where we're gonna talk about MIX_GetTrackGain(3) and why it's lowkey the glow-up check for your track's volume πŸ’…


🌸 NAME 🌸

MIX_GetTrackGain β€” get a track's gain control 🎚️✨


πŸŽ€ SYNOPSIS πŸŽ€

#include <SDL3_mixer/SDL_mixer.h>

float MIX_GetTrackGain(MIX_Track *track);

πŸ¦‹ DESCRIPTION πŸ¦‹

so this one is literally just a lil peek at the gain value πŸ’– it hands you back the last value that got set through MIX_SetTrackGain() β€” that's it, that's the whole vibe.

and if nobody has ever explicitly set a gain on that track? no problem, you get 1.0f back. default queen behavior πŸ‘‘ (which, yes, means "no change to the volume," iykyk).


🌈 FUNCTION PARAMETERS 🌈

  • track β€” the track you're asking about, bestie. the one you wanna query. 🫢

⭐ RETURN VALUE ⭐

it returns the track's current gain. that's the whole thing. slay. ✨


πŸ’œ THREAD SAFETY πŸ’œ

fr fr, you can call this from any thread. no cap. all threads are welcome at this party πŸŽ‰ no locks, no drama, no gatekeeping.


πŸ‘‘ AVAILABILITY πŸ‘‘

this iconic lil function has been around since SDL_mixer 3.0.0. so if you're on anything older… sorry bestie, it's giving upgrade era πŸ’€


πŸ”₯ SEE ALSO πŸ”₯


and that's the tea πŸ“ this page came from the SDL_mixer manual, sitting pretty at version SDL_mixer 3.2.4, filed under the SDL_mixer3 functions section (and yeah, the original footer said MIX_GetTrackGain(3) right back at us, so consider this your cute lil sign-off πŸ’–). go forth and read your gains, queen 🧚✨

πŸ“¦ where this page comes from