/[svn]/linuxsampler/trunk/src/engines/gig/EngineChannel.cpp
ViewVC logotype

Diff of /linuxsampler/trunk/src/engines/gig/EngineChannel.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1040 by schoenebeck, Wed Feb 7 15:41:31 2007 UTC revision 1309 by iliev, Wed Aug 29 10:36:32 2007 UTC
# Line 159  namespace LinuxSampler { namespace gig { Line 159  namespace LinuxSampler { namespace gig {
159       * This method will then actually start to load the instrument and block       * This method will then actually start to load the instrument and block
160       * the calling thread until loading was completed.       * the calling thread until loading was completed.
161       *       *
      * @returns detailed description of the method call result  
162       * @see PrepareLoadInstrument()       * @see PrepareLoadInstrument()
163       */       */
164      void EngineChannel::LoadInstrument() {      void EngineChannel::LoadInstrument() {
# Line 192  namespace LinuxSampler { namespace gig { Line 191  namespace LinuxSampler { namespace gig {
191              instrid.Index     = InstrumentIdx;              instrid.Index     = InstrumentIdx;
192              newInstrument = Engine::instruments.Borrow(instrid, this);              newInstrument = Engine::instruments.Borrow(instrid, this);
193              if (!newInstrument) {              if (!newInstrument) {
194                  throw InstrumentResourceManagerException("resource was not created");                  throw InstrumentManagerException("resource was not created");
195              }              }
196          }          }
197          catch (RIFF::Exception e) {          catch (RIFF::Exception e) {
198              InstrumentStat = -2;              InstrumentStat = -2;
199                StatusChanged(true);
200              String msg = "gig::Engine error: Failed to load instrument, cause: " + e.Message;              String msg = "gig::Engine error: Failed to load instrument, cause: " + e.Message;
201              throw Exception(msg);              throw Exception(msg);
202          }          }
203          catch (InstrumentResourceManagerException e) {          catch (InstrumentManagerException e) {
204              InstrumentStat = -3;              InstrumentStat = -3;
205                StatusChanged(true);
206              String msg = "gig::Engine error: Failed to load instrument, cause: " + e.Message();              String msg = "gig::Engine error: Failed to load instrument, cause: " + e.Message();
207              throw Exception(msg);              throw Exception(msg);
208          }          }
209          catch (...) {          catch (...) {
210              InstrumentStat = -4;              InstrumentStat = -4;
211                StatusChanged(true);
212              throw Exception("gig::Engine error: Failed to load instrument, cause: Unknown exception while trying to parse gig file.");              throw Exception("gig::Engine error: Failed to load instrument, cause: Unknown exception while trying to parse gig file.");
213          }          }
214    
# Line 219  namespace LinuxSampler { namespace gig { Line 221  namespace LinuxSampler { namespace gig {
221    
222          if (pEngine) pEngine->ChangeInstrument(this, newInstrument);          if (pEngine) pEngine->ChangeInstrument(this, newInstrument);
223          else pInstrument = newInstrument;          else pInstrument = newInstrument;
224            
225            StatusChanged(true);
226      }      }
227    
228      /**      /**
# Line 336  namespace LinuxSampler { namespace gig { Line 340  namespace LinuxSampler { namespace gig {
340              default:              default:
341                  throw AudioOutputException("Invalid engine audio channel " + ToString(EngineAudioChannel));                  throw AudioOutputException("Invalid engine audio channel " + ToString(EngineAudioChannel));
342          }          }
343    
344            bStatusChanged = true;
345      }      }
346    
347      int EngineChannel::OutputChannel(uint EngineAudioChannel) {      int EngineChannel::OutputChannel(uint EngineAudioChannel) {
# Line 388  namespace LinuxSampler { namespace gig { Line 394  namespace LinuxSampler { namespace gig {
394          }          }
395          fxSends.push_back(pFxSend);          fxSends.push_back(pFxSend);
396          if (pEngine) pEngine->Enable();          if (pEngine) pEngine->Enable();
397            fireFxSendCountChanged(iSamplerChannelIndex, GetFxSendCount());
398            
399          return pFxSend;          return pFxSend;
400      }      }
401    
# Line 425  namespace LinuxSampler { namespace gig { Line 433  namespace LinuxSampler { namespace gig {
433              }              }
434          }          }
435          if (pEngine) pEngine->Enable();          if (pEngine) pEngine->Enable();
436            fireFxSendCountChanged(iSamplerChannelIndex, GetFxSendCount());
437      }      }
438    
439      /**      /**
# Line 631  namespace LinuxSampler { namespace gig { Line 640  namespace LinuxSampler { namespace gig {
640          MidiVolume     = 1.0;          MidiVolume     = 1.0;
641          GlobalPanLeft  = 1.0f;          GlobalPanLeft  = 1.0f;
642          GlobalPanRight = 1.0f;          GlobalPanRight = 1.0f;
643            GlobalTranspose = 0;
644          // set all MIDI controller values to zero          // set all MIDI controller values to zero
645          memset(ControllerTable, 0x00, 129);          memset(ControllerTable, 0x00, 129);
646          // reset all FX Send levels          // reset all FX Send levels

Legend:
Removed from v.1040  
changed lines
  Added in v.1309

  ViewVC Help
Powered by ViewVC