Hi, I’m am using the newly released Unity FMOD integration (1.08.00), and I am trying to replicate the callback for getting Markers and beats from an event instance, as shown in the documentation below.
This works fine in the editor and on android, however on iOS, I am getting Just In Time errors when I try to set the callback. Unfortunately the problem seems to be in your dll. Do you know of any work around?
ExecutionEngineException: Attempting to JIT compile method ‘(wrapper
(FMOD.Studio.EVENT_CALLBACK_TYPE,intptr,intptr)’ while running with
at (wrapper managed-to-native)
at FMOD.Studio.EventInstance.setCallback (FMOD.Studio.EVENT_CALLBACK
callback, EVENT_CALLBACK_TYPE callbackmask) [0x00000] in :0 at MainTrackController.Play () [0x00000] in :0 at GarageGameController.Begin () [0x00000] in :0
- You must login to post comments
Use IL2CPP for your iOS builds instead of Mono (done on the the Unity Player Settings).
You can’t submit Mono builds to the store anyway because it doesn’t support 64bit apps.
You need to add [MonoPInvokeCallback] above your method. It shouldn’t require any changes to our plugin.
MonoPInvokeCallback needs a type specified, at least it does for me.. using AOT; What should be used?
I have the same issue still. A type needs to be specified.
Could you provide an example piece of code?
[MonoPInvokeCallback (typeof (FMOD.Studio.EVENT_CALLBACK))]
Side note: this solution also works for getting the FMOD callbacks working on PS4.
Please login first to submit.