mirror of
https://github.com/tildearrow/furnace.git
synced 2024-11-27 06:53:01 +00:00
add safe mode with audio
This commit is contained in:
parent
a06c38d8b1
commit
1cf519ce17
1 changed files with 9 additions and 1 deletions
10
src/main.cpp
10
src/main.cpp
|
@ -76,6 +76,7 @@ bool cmdOutBinary=false;
|
|||
bool vgmOutDirect=false;
|
||||
|
||||
bool safeMode=false;
|
||||
bool safeModeWithAudio=false;
|
||||
|
||||
std::vector<TAParam> params;
|
||||
|
||||
|
@ -134,6 +135,12 @@ TAParamResult pSafeMode(String val) {
|
|||
return TA_PARAM_SUCCESS;
|
||||
}
|
||||
|
||||
TAParamResult pSafeModeAudio(String val) {
|
||||
safeMode=true;
|
||||
safeModeWithAudio=true;
|
||||
return TA_PARAM_SUCCESS;
|
||||
}
|
||||
|
||||
TAParamResult pBinary(String val) {
|
||||
cmdOutBinary=true;
|
||||
return TA_PARAM_SUCCESS;
|
||||
|
@ -353,6 +360,7 @@ void initParams() {
|
|||
params.push_back(TAParam("s","subsong",true,pSubSong,"<number>","set sub-song"));
|
||||
params.push_back(TAParam("o","outmode",true,pOutMode,"one|persys|perchan","set file output mode"));
|
||||
params.push_back(TAParam("S","safemode",false,pSafeMode,"","enable safe mode (software rendering and no audio)"));
|
||||
params.push_back(TAParam("A","safeaudio",false,pSafeModeAudio,"","enable safe mode (with audio"));
|
||||
|
||||
params.push_back(TAParam("B","benchmark",true,pBenchmark,"render|seek","run performance test"));
|
||||
|
||||
|
@ -509,7 +517,7 @@ int main(int argc, char** argv) {
|
|||
|
||||
e.preInit();
|
||||
|
||||
if (safeMode) {
|
||||
if (safeMode && !safeModeWithAudio) {
|
||||
e.setAudio(DIV_AUDIO_DUMMY);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue