--- linuxsampler/trunk/src/network/lscp.y 2004/06/20 16:01:50 135 +++ linuxsampler/trunk/src/network/lscp.y 2004/06/20 23:18:24 138 @@ -44,6 +44,7 @@ // we provide our own version of yyerror() so we don't have to link against the yacc library void yyerror(const char* s); +bool background; %} // reentrant parser @@ -97,8 +98,8 @@ | CREATE SP create_instruction { $$ = $3; } | DESTROY SP destroy_instruction { $$ = $3; } | LIST SP list_instruction { $$ = $3; } - | LOAD SP load_instruction { $$ = $3; } - | LOAD_BACKGROUND SP load_instruction { $$ = $3; } + | LOAD SP load_instruction { $$ = $3; background = false; } + | LOAD_BACKGROUND SP load_instruction { $$ = $3; background = true; } | REMOVE SP CHANNEL SP sampler_channel { $$ = LSCPSERVER->RemoveChannel($5); } | SET SP set_instruction { $$ = $3; } | SUBSCRIBE SP subscribe_event { $$ = $3; } @@ -146,6 +147,7 @@ ; create_instruction : AUDIO_OUTPUT_DEVICE SP string SP key_val_list { $$ = LSCPSERVER->CreateAudioOutputDevice($3,$5); } + | AUDIO_OUTPUT_DEVICE SP string { $$ = LSCPSERVER->CreateAudioOutputDevice($3); } ; destroy_instruction : AUDIO_OUTPUT_DEVICE SP NUMBER { $$ = LSCPSERVER->DestroyAudioOutputDevice($3); } @@ -174,7 +176,7 @@ list_instruction : AUDIO_OUTPUT_DEVICES { $$ = LSCPSERVER->GetAudioOutputDevices(); } ; -load_instr_args : filename SP instrument_index SP sampler_channel { $$ = LSCPSERVER->LoadInstrument($1, $3, $5); } +load_instr_args : filename SP instrument_index SP sampler_channel { $$ = LSCPSERVER->LoadInstrument($1, $3, $5, background); } ; load_engine_args : engine_name SP sampler_channel { $$ = LSCPSERVER->LoadEngine($1, $3); }