本文整理汇总了C++中soundLib::init_audio_system方法的典型用法代码示例。如果您正苦于以下问题:C++ soundLib::init_audio_system方法的具体用法?C++ soundLib::init_audio_system怎么用?C++ soundLib::init_audio_system使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类soundLib
的用法示例。
在下文中一共展示了soundLib::init_audio_system方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: main
int main(int argc, char *argv[])
{
get_filepath();
fio.read_game(game_data);
soundManager.init_audio_system();
if (graphLib.initGraphics() != true) {
printf("ERROR intializing graphic\n");
return -1;
}
sceneShow show;
show.show_scene(0);
input.wait_keypress();
return 1;
}
示例2: main
//.........这里部分代码省略.........
#endif
// check command-line paramethers
if (argc > 1) {
for (int i=1; i<argc; i++) {
std::string temp_argv(argv[i]);
if (temp_argv == "--fullscreen") {
} else if (temp_argv == "--quickload") {
GAME_FLAGS[FLAG_QUICKLOAD] = true;
} else if (temp_argv == "--invencible") { // player have infinite HP
GAME_FLAGS[FLAG_INVENCIBLE] = true;
} else if (temp_argv == "--allweapons") { // player have all weapons available even if
GAME_FLAGS[FLAG_ALLWEAPONS] = true;
} else if (temp_argv == "--infinitejump") { // player can jump again and again
GAME_FLAGS[FLAG_INFINITE_JUMP] = true;
}
}
}
std::cout << "PS2.DEBUG #7" << std::endl; std::fflush(stdout);
//fio.check_conversion();
fio.read_game(game_data);
//GAME_FLAGS[FLAG_INFINITE_HP] = true; // DEBUG
gameControl.get_drop_item_ids();
soundManager.init_audio_system();
// PS2 version have to load config AFTER SDL_Init due to SDK issues
#ifdef LINUX
SAVEPATH = std::string(getenv("HOME")) + "/.rockbot/";
mkdir(SAVEPATH.c_str(), 0777);
//std::cout << "SAVEPATH: " << SAVEPATH << ", mkdir-res: " << res << ", errno: " << errno << std::endl;
#elif WIN32
SAVEPATH = std::string(getenv("APPDATA")) + "/rockbot";
std::cout << "SAVEPATH: " << SAVEPATH << std::endl;
_mkdir(SAVEPATH.c_str());
#else
SAVEPATH = FILEPATH;
#endif
#ifndef PLAYSTATION2
fio.load_config(game_config);
#endif
// INIT GRAPHICS
if (graphLib.initGraphics() != true) {
printf("ERROR intializing graphic\n");
return -1;
}
// define SAVEPATH
#ifdef PLAYSTATION2
PS2_load_MC();
SAVEPATH = "mc0:Rockbot/";
if (fioMkdir(SAVEPATH.c_str()) < 0) {
std::cout << "main - warning: could not create '" << SAVEPATH << "' folder" << std::endl; std::fflush(stdout);
/// @TODO - check if directory exists