Skip to content

Feat/miniaudio music system#42

Open
gimploo wants to merge 11 commits into
devfrom
feat/miniaudio-music-system
Open

Feat/miniaudio music system#42
gimploo wants to merge 11 commits into
devfrom
feat/miniaudio-music-system

Conversation

@gimploo

@gimploo gimploo commented Jul 19, 2026

Copy link
Copy Markdown
Owner

No description provided.

gimploo added 11 commits July 18, 2026 08:29
Add PLANNED comments and stub headers for audio_device, audio_music,
and audio_sfx. No runtime behavior yet — waiting for approval before
vendoring miniaudio and implementing the hybrid Wwise-export path.
Implements layered interactive music + one-shot SFX for Vedanta's
Wwise-authored theme (Music_Khushi).

poglib changes:
- audio_device.h: miniaudio engine lifecycle (init/shutdown/engine)
- audio_music.h: 4-layer streaming with intensity-driven volume curves
- audio_sfx.h: one-shot impact stinger pool with round-robin sets
- music_config.h: Wwise-project-derived layer/curve/sfx definitions
- application.h: wire device init/shutdown into app lifecycle
- external/miniaudio.h: vendored single-header audio library
- Replace char[]/char* with str_t in audio_music.h, audio_sfx.h, music_config.h
- Rename static helpers to INTERNAL + __internal__ naming pattern
- Add math.h include for powf/fabsf
MA_NO_DSOUND prevents miniaudio's DirectSound wrapper types from
conflicting with windows.h (pulled in by SDL2 before miniaudio).
WASAPI remains enabled as the primary Windows audio backend.
Also updated miniaudio.h to latest release (v0.11.25).
MSVC build needs Windows SDK types (WORD, DWORD, etc.) defined before
miniaudio's WASAPI backend code. Add explicit windows.h include with
WIN32_LEAN_AND_MEAN for miniaudio on Windows.
- Remove #define WORD 512 from common.h and dbg.h (collided with Windows SDK WORD type used by miniaudio.h)
- Replace all WORD buffer-size usages with literal 512
- Fix ma_sound_set_fade_in_milliseconds signature (4 args in miniaudio v0.11.25)
- Fix str() compound literal in music_config.h (not constant expression for file-scope statics)
Covers: hybrid Wwise/miniaudio approach, layer system, RTPC curves,
impact stingers, game integration, runtime data flow, tradeoffs,
limitations, troubleshooting. Intended for contributors unfamiliar
with the audio subsystem.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant