I’m using the C# API from fmodstudioapi20314win-installer.exe
The application is 64-bit / Windows.
Debug version works fine loading fmodstudioL.dll and fmodL.dll
Release version fails to load fmodstudio.dll with:
System.BadImageFormatException: An attempt was made to load a program with an incorrect format. (0x8007000B) at FMOD.Studio.System.FMOD_Studio_System_Create(IntPtr& system, UInt32 headerversion) at FMOD.Studio.System.create(System& system)
I double checked that I copied the right files: "c:\Program Files (x86)\FMOD SoundSystem\FMOD Studio API Windows\api\studio\lib\x64\fmodstudio.dll" "c:\Program Files (x86)\FMOD SoundSystem\FMOD Studio API Windows\api\core\lib\x64\fmod.dll"
.\dumpbin.exe /headers "C:\Program Files (x86)\FMOD SoundSystem\FMOD Studio API Windows\api\studio\lib\x64\fmodstudio.dll" | findstr machine
And share the output which should look like 8664 machine (x64). If not, please remove the | findstr machine and share share the full output of the logs. If it is outputting the correct version, would it be possible to reinstall the engine can check if it is working as expected?
The C# wrapper assembly I put together was called FMOD.csproj
When loading the (correct) fmodstudio.dll it tried to load the managed FMOD.dll instead of the correct fmod.dll…
In the Debug version I used fmodL.dll and fmodstudioL.dll so there was no name collision there.