Installation Instructions
SimpleFMOD is a simple library to let you shoehorn music and sound effects into your games and applications quickly.
Why SimpleFMOD?
Initializing FMOD and performing the necessary memory management is complex for beginners. SimpleFMOD takes care of all the dirty work for you so you just have to concentrate on getting the sounds and music into your application. SimpleFMOD manages all the audio resources you use, handles initialization and teardown, allows simple loading of sounds or streams from both disk or embedded application resources (memory), handles game sound effects and music in separate channel groups so they can have their own master volumes, and provides numerous helper functions to make basic audio manipulation easy.
Full source code is included so that when you are ready to move onto more advanced techniques, you can see exactly how the basics work.
System Requirements
- Windows XP
- Windows Vista
- Windows 7
- Windows Server 2008
- Windows 8
Pre-requisites
SimpleFMOD has been tested with Visual Studio 2012 and Visual Studio 2010.
Download and install the FMOD Ex Programmers API from the FMOD web site to install the official FMOD libraries that SimpleFMOD depends on.
Download
Download link for SimpleFMOD (always use the latest version)
Compilation and linking
Referencing the FMOD Programmers API
Reference the FMOD Ex Programmers API header and library paths in each project as follows:
- Right-click your project -> Properties -> Configuration Properties -> VC++ Directories -> Include Directories -> add C:\Program Files\FMOD SoundSystem\FMOD Programmers API Windows\api\inc to the list of paths
- Right-click your project -> Properties -> Configuration Properties -> VC++ Directories -> Library Directories -> add C:\Program Files\FMOD SoundSystem\FMOD Programmers API Windows\api\lib to the list of paths
Each project must also include the FMOD Ex Programmers API library as a linker input.
- Right-click your project -> Properties -> Configuration Properties -> Linker -> Input -> Additional Dependencies -> add
fmodex_vc.lib
to the list of dependencies
Referencing SimpleFMOD
Each project must include the SimpleFMOD library as a linker input.
- Right-click your project -> Properties -> Configuration Properties -> Linker -> Input -> Additional Dependencies -> add
SimpleFMOD.lib
(for Release builds) orSimpleFMODd.lib
(for Debug builds) to the list of dependencies
Link profile
SimpleFMOD is statically linked with the Visual C++ run-time libraries. Projects based on it should statically link the runtime library as follows:
- Right-click your project -> Properties -> Configuration Properties -> C/C++ -> Code Generation ->Runtime Library -> Multi-threaded (/MT) or Multi-threaded Debug (/MTd) (depending on your build configuration)
Hi there!
I was attempting to use SimpleFMOD with my program and I get the following error:
” 1. IntelliSense: identifier “SimpleFMOD” is undefined”
I followed your instructions to the letter and I’m unsure why I’m getting this error. Could you please advise what could be the cause of this problem?
Thanks
Do the examples included with the library compile correctly or do they give the same error?
Follow-up: try adding “using namespace SFMOD;” after you include SimpleFMOD.h. Everything in the library is defined in a namespace called SFMOD. I will add this to the instructions on page 2 🙂
There we go, that did the trick 🙂
Thank you!
Good stuff. I’m not perfect at writing instructions hehe, thanks for pointing that out 🙂 If you have any more problems just have a look through the examples folder, they should all work nicely 🙂
No issues 🙂
After wrangling with the original FMOD for a couple of hours, SFMOD really puts it in terms of plain english!
How do you go about releasing sounds once you are finished? I see the struct ReleaseFMODResource with
void operator()(FMOD::Sound *r) const
{
r->release();
}
but how do you use it / call it?
I tried to include this in my VS2010 project but I get a linking error:
SimpleFMODd.lib(SimpleFMOD.obj) : error LNK2038: mismatch detected for ‘_MSC_VER’: value ‘1700’ doesn’t match value ‘1600’
Maybe the libraries aren’t good for VS2010 anymore?
Argh, yes, the latest versions I uploaded are compiled against VS2012. It’s easy to fix though, the source code is included, just re-compile it with VS2010 🙂
First of all thank you for the effort to write this great library and tutorials.
I’ve tried to get this to work for days now, without any luck. 😦
At first I was trying to make it compile with GCC, but after hours and hours of headaches I surrendered. So I’m now trying to compile the Frequency Analyzer, but there are just soo many issues.. After adding some includes ( and “tchar.h”) which apparently are necessary I finally got through the compiling process for the first time, but now there are linking issues: [text]The object or library file ‘Release\BeatDetecter.obj’ was created with an older compiler than other objects; rebuild old objects and libraries[/text]. After a while I found your comment about it actually not being compiled to work in VS2010… So now I’m at the point where I have to compile the lib… But neither have I ever compiled a static lib, nor have I seriously used Visual Studio. So I just created a new project, selected “static library” and then tried to build it with SimpleFMOD.h as the header file and SimpleFMOD.cpp as the source file, which gave me the following error messages:
[text]1>..\..\..\..\..\..\..\Program Files (x86)\DJKaty.com\SimpleFMOD\src\SimpleFMOD.cpp(102): error C2143: syntax error : missing ‘,’ before ‘:’
1>..\..\..\..\..\..\..\Program Files (x86)\DJKaty.com\SimpleFMOD\src\SimpleFMOD.cpp(102): error C2530: ‘r’ : references must be initialized
1>..\..\..\..\..\..\..\Program Files (x86)\DJKaty.com\SimpleFMOD\src\SimpleFMOD.cpp(102): error C3531: ‘r’: a symbol whose type contains ‘auto’ must have an initializer[/text]
I added the fmod include and lib dirs and even tried to add the fmod lib as a dependency, but it keeps giving me the same errors.
Any help would be highly appreciated.
Okay, after spending a couple more hours on this I figured out that instead of
we can use
and then the library finally compiles.
Then I replaced the resulting .lib with the original one of the installation. Then in the Frequency Analyzer project I set the Runtime Library to “Multi-threaded DLL (/MD)” and put the fmodex.dll in the Release directory and it finally worked. BUT I should mention I have removed all the Simple2D stuff in advance and created a console application.