0
0

Hello,

I am new to fmod. I am working on a Virtual reality CAVE project was dedcided to use fmod for my sound server due to its 3d capabilities. I am currently playing with the code in MS Visual C++. Can anyone tell me why I am recieving this error when i try to build my edited example files?

Main.obj : error LNK2001: unresolved external symbol _FSOUND_Close@0
Main.obj : error LNK2001: unresolved external symbol _FMUSIC_FreeSong@4
Main.obj : error LNK2001: unresolved external symbol _FMUSIC_GetNumOrders@4
Main.obj : error LNK2001: unresolved external symbol _FMUSIC_GetRow@4
Main.obj : error LNK2001: unresolved external symbol _FMUSIC_GetPatternLength@8
Main.obj : error LNK2001: unresolved external symbol _FMUSIC_GetOrder@4
Main.obj : error LNK2001: unresolved external symbol _FSOUND_GetChannelsPlaying@0
Main.obj : error LNK2001: unresolved external symbol _FSOUND_GetCPUUsage@0
Main.obj : error LNK2001: unresolved external symbol _FMUSIC_GetName@4
Main.obj : error LNK2001: unresolved external symbol _FMUSIC_PlaySong@4
Main.obj : error LNK2001: unresolved external symbol _FMUSIC_LoadSong@4
Main.obj : error LNK2001: unresolved external symbol _FSOUND_GetError@0
Main.obj : error LNK2001: unresolved external symbol _FSOUND_Init@12
Main.obj : error LNK2001: unresolved external symbol _FSOUND_GetVersion@0
Debug/Main.exe : fatal error LNK1120: 14 unresolved externals
Error executing link.exe.

There is a lib file in the documentation i have to include somewhere? It is not clear to me from the documentation where i must insert this file. Any help would be greatly appreciated. Thank you.

  • You must to post comments
0
0

add the .lib file to your project in vc++ :) as you would add any other file e.g: .cpp

  • You must to post comments
0
0

Yeah… you can either add the .lib file to your VC project tree, or (this is the way I do it), specify fmodvc.lib in the Linker options under Project Settings (in this case, the folder containing fmodvc.lib would have to be in the VC library search path)

  • You must to post comments
0
0

I’ve having that exact problem (except I’m using C++ with the “Digital Mars” compiler as opposed to Visual C++)

I have made all 4.h files, all 4 .lib files, and libfmod.a avalable to my compiler buy copying them into the appropriate directories (although I probably only need one, I’m not sure which one my compiler would need.)

Here is the relevant code..

[code:qg1hxu5t]#include <iostream.h>

include <fmod.h>

include <stdio.h>

include <stdlib.h>

include <fmod_errors.h>

include <windows.h>

(...)

int main()
{

if (!FSOUND_Init(44100, 32, FSOUND_INIT_USEDEFAULTMIDISYNTH))
{
printf("Error!\n");
printf("%s\n", FMOD_ErrorString(FSOUND_GetError()));
return 1;
}

FMUSIC_MODULE* TitleTheme = FMUSIC_LoadSong("../../MyDocu~1/Dan/ANGELG~1.mid");
FMUSIC_PlaySong(TitleTheme);

(...)

FMUSIC_StopSong(TitleTheme);
FMUSIC_FreeSong(TitleTheme);
FSOUND_Close();
return 0;
}[/code:qg1hxu5t]

What am I doing wrong?

  • You must to post comments
Showing 3 results
Your Answer

Please first to submit.