Open lebedec opened 4 months ago
There are 3 plugin types:
In application runtime they can be provided all the ways
In SDK each plugin has separate header with its own version FMOD_xxx_PLUGIN_VERSION
:
All these definitions must be provided in common FMOD library (included in fmod_common.h
which included in fmod.h
)
Also, I think there is no much sense to provide Rust safe wrappers for plugin definitions because. Almost all definitions of plugin is callbacks with C FFI interfaces. Maybe we need separate libfmod-sys
crate (this is also recommended by the Rust FFI guidelines).
Draft, new libfmod
crates hierarchy:
Feel free to use fmod-audio-sys
!
About wrappers for plugin API.
There are issues for short period of time. All occured becuase of "safe" conversion:
Also, working with plugin API in any case leads to raw FFI: specific pointers defintion, byte buffers, C unions, C callbacks, etc
I am becoming more and more confident that FMOD plugins API structures like FMOD_DSP_DESCRIPTION
must be raw FFI without wrappers.
based on #14
We probably need a separate crate without linking that will contain everything we need for FMOD DSP plugins development.
fmod_dsp.h
which noted as header for DSP plugins developmentProbable solution:
A new crate
libfmod-dsp-plugin
based onfmod_dsp.h
header which contains only definitions for DSP plugins development. Version and backward compatibility based onFMOD_PLUGIN_SDK_VERSION
(provided by FMOD team). No linking. No FMOD context bindings.Blocker:
Need more docs except white papers or any FMOD developer expertise to be sure that this solution correct