Hey,
I’m still fairly new to using FMOD and I"m having a problem with the sound of a project I"m working on. I’m trying to figure out how to load a sound once into FMOD but have it play on different channels when necessary. Mainly, I"m trying to do this so I can implement 3D sounds where different agents can play the same sound at different positions.
Any and all help is appreciated.
- Darkdan1138 asked 9 years ago
- You must login to post comments
The audio data for a sound is stored with the FMOD::Sound object. The instance data for a sound is stored with the FMOD::Channel object.
Every time you call System::playSound(), your sound will get put onto a new channel, so you can call System::playSound as many times as you want on a single FMOD::Sound and every time you call it, it’ll play another instance of that sound.
Be aware, though, that if you call System::createStream() (or pass in FMOD_CREATESTREAM to System::createSound()), then you must have one Sound object for each instance (this is due to the way it’s implemented, where the Sound object stores the file pointer).
- Adiss answered 9 years ago
- You must login to post comments
Please login first to submit.