2 ms·
> The neat thing about audio is that you can stream it in You can stream music. You cannot stream effects; the timing of effects is such that you can't afford
by eropple 10y ago
> The neat thing about audio is that you can stream it in
You can stream music. You cannot stream effects; the timing of effects is such that you can't afford a frame's delay or people will notice it's off-kilter. And, as it happens, effects are precisely what are loaded uncompressed; almost every game engine's streaming-music feature uses MP3, OGG, or whatever.
- izacus 10y agoSound effects are almost always streamed in - remember, most of modern games are built for consoles as well, which have significantly less memory storage. Hence lack of compression - it lets you stream in audio from a spinning BR directly without spending more CPU power.
- eropple 10y agoThat could be the case on consoles, but I've never seen an engine that didn't strongly recommend preloading triggered effects on platforms with a RAM budget.
- striking 10y agoOften you can predict what effects your scene will need. Sometimes you can't, and in that case you can't compress. But it's entirely possible that you could decompress some of that audio into RAM beforehand if you're not confident every device can play that audio compressed immediately. Or store back a cache file temporarily. Or just not even worry about the CPU because the vast majority of users are GPU-limited rather than CPU-limited.