INNER CODE UNIT · TypeScript

setMasterVolume

Bloom-Engine/engine · src/audio/index.ts:50

export function setMasterVolume(volume: number): void {
  bloom_set_master_volume(volume);
}

// Music functions

export function loadMusic(path: string): Music {
  const handle = bloom_load_music(path as any);
  return { handle };
}

/// Returns the raw numeric handle. Prefer this on Android (aarch64): Perry 0.5.x
/// miscompiles `music.handle` field reads that feed straight into an f64 FFI slot,
/// producing NaN and dropping the music.
export function loadMusicRaw(path: string): number {
  return bloom_load_music(path as any);
}

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…