blob: 40c1cd27bb078dde236e66eff9c075ac42a52b96 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
|
#include <string>
#include <cstdio>
#include <unistd.h>
#include <common/logger.h>
#include <common/iman.h>
#include <sound/sound.h>
#include <plugins/pluginloader.h>
int main() {
new CLogger();
new CInstanceManager();
lt_dlinit();
CPluginLoader *plugin = new CPluginLoader("libopenalsound");
if (plugin->LoadPlugin()) {
CSoundInterface *sound = static_cast<CSoundInterface*>(CInstanceManager::GetInstancePointer()->SearchInstance(CLASS_SOUND));
sound->Create(true);
sound->CacheAll();
sound->Play((Sound)8);
sound->Play((Sound)18);
sleep(10);
/*
while (1)
{
// just a test, very slow
plugin->FrameMove(0);
//if ('n' == getchar())
// break;
}*/
plugin->UnloadPlugin();
}
lt_dlexit();
return 0;
}
|