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

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

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

revision 1773 by iliev, Wed Sep 10 15:02:24 2008 UTC revision 1774 by iliev, Thu Sep 11 18:11:06 2008 UTC
# Line 188  namespace LinuxSampler { namespace gig { Line 188  namespace LinuxSampler { namespace gig {
188                  pRegion = pInstrument->GetNextRegion();                  pRegion = pInstrument->GetNextRegion();
189              }              }
190                            
191              int low = pInstrument->DimensionKeyRange.low;              if (loaded) { // retrieve keyswitching only if the instrument is fully loaded.
192              int high = pInstrument->DimensionKeyRange.high;                  int low = pInstrument->DimensionKeyRange.low;
193              if (low < 0 || low > 127 || high < 0 || high > 127 || low > high) {                  int high = pInstrument->DimensionKeyRange.high;
194                  std::cerr << "Invalid keyswitch range: " << low << " - " << high << std::endl;                  if (low < 0 || low > 127 || high < 0 || high > 127 || low > high) {
195              } else {                      std::cerr << "Invalid keyswitch range: " << low << " - " << high << std::endl;
196                  for (int i = low; i <= high; i++) info.KeySwitchBindings[i] = 1;                  } else {
197                        for (int i = low; i <= high; i++) info.KeySwitchBindings[i] = 1;
198                    }
199              }              }
200    
201              if (loaded) Unlock();              if (loaded) Unlock();

Legend:
Removed from v.1773  
changed lines
  Added in v.1774

  ViewVC Help
Powered by ViewVC