here`s the code can anyone see what im doing wrong i can get it to work with out the map like the code in my first post
#include "wmp3.h"
#include <map>
using std::map;
//WMp3* myMp3 = new WMp3();
map<int,WMp3()> soundmap;//probably this thats wrong
BOOL APIENTRY DllMain( HANDLE hModule,
DWORD ul_reason_for_call,
LPVOID lpReserved
)
{
return TRUE;
}
#define MYCOMMAND __declspec ( dllexport )
MYCOMMAND void loadmp3file(const char* file,int id,int buff)
{
soundmap[id]->OpenMp3File(file,buff);
}
MYCOMMAND void playmp3(int id)
{
soundmap[id]->Play();
}
here is the errors
1>main.cpp
1>.\main.cpp(24) : error C2227: left of '->OpenMp3File' must point to class/struct/union/generic type
1> type is 'WMp3 (__cdecl &)(void)'
1>.\main.cpp(29) : error C2227: left of '->Play' must point to class/struct/union/generic type
1> type is 'WMp3 (__cdecl &)(void)'