package audio

import (
	rl "github.com/gen2brain/raylib-go/raylib"
)

func LoadFromMemory(typ string, data []byte) rl.Sound {
	wave := rl.LoadWaveFromMemory(typ, data, int32(len(data)))
	defer rl.UnloadWave(wave)
	return rl.LoadSoundFromWave(wave)
}
