Some questions about using EVENT_INFOONLY events in combination with Just Fail If Quietest.
The docs say that using the EVENT_INFOONLY mode will not allocate instances. However, to use it with Just Fail If Quietest we must set member data on the event, so it can’t just use some static shared instance – or can it?
If it actually is instanced, how many unique INFOONLY events can I get, where does the memory come from, and what happens when it runs out of memory/instances?
Will FMOD_EVENT_CALLBACKTYPE_STOLEN ever be fired for INFOONLY events? The docs suggest this callback only applies to playing sounds, but I’m wondering what happens if it’s possible to run out of INFOONLY instances.
set3DAttributes says that the getEvent methods will use an INFOONLY event for the purposes of Just Fail If Quietest. I assume these methods use the Event** parameter as both input and output then? What happens to the INFOONLY event that I pass in – is it still valid afterwards?
Will play around to try to figure this out, just wanted to get a definitive answer if possible.
Thanks for any advice!
- nyoung asked 9 years ago
So, it seems that each time I call getEvent with INFOONLY mode, I get the same pointer back… does that mean that there is just one shared INFOONLY mode event for each event?
And so, for the purposes of Just Fail If Quietest, one should get the INFOONLY event and then immediately attempt to get the real event, making sure that no other code has a chance to touch the INFOONLY event in the interim?
There is no such thing as an ‘info only instance’.
Info only is referring to the template that instances are created from.
If you set an attribute on this it will be carried into the event when getEvent is used with a proper instanced version of the event. It doesnt change all instances when you set it again, it is just copied across when you call getEvent to get a proper instance.
Please login first to submit.