0
0

The docs for this structure mention that it needs to have the same lifetime as the fmod system as references are kept and the struct accessed during operations. I wondered if this is still true and if so, if the lifetime is actually narrower than that. Say, only kept for the lifetime of the DSP object.

  • You must to post comments
0
0

I haven’t been able to find reference to that in the documentation, whereabouts did you see it?

Functions such as System::createDSP and System::registerDSP that take FMOD_DSP_DESCRIPTION pointers copy the values internally so you shouldn’t have to hold onto it.

  • You must to post comments
0
0

[quote="mathew":29rsrkrk]I haven’t been able to find reference to that in the documentation, whereabouts did you see it?
[/quote:29rsrkrk]

In the .chm docs in the FmodEx install under API reference > FMOD Ex API references > Structures > FMOD_DSP_DESCRIPTION:
[quote:29rsrkrk]Remarks

Some members of this structure are referenced directly inside FMOD so the structure should be allocated statically or at least remain in memory for the lifetime of the system.
[/quote:29rsrkrk]

  • You must to post comments
0
0

Thanks for pointing that out, the docs aren’t exactly correct here.
The FMOD_DSP_DESCRIPTION struct isn’t referenced, all the members are copied.

The only issue is the paramdesc member, that pointer is copied so the memory it points to must remain valid for the life of the DSP.

  • You must to post comments
Showing 3 results
Your Answer

Please first to submit.