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

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

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

revision 1297 by iliev, Thu Aug 16 15:55:21 2007 UTC revision 1305 by iliev, Mon Aug 27 07:51:28 2007 UTC
# Line 526  namespace LinuxSampler { namespace gig { Line 526  namespace LinuxSampler { namespace gig {
526          if (pEngineChannel->GetMute()) return; // skip if sampler channel is muted          if (pEngineChannel->GetMute()) return; // skip if sampler channel is muted
527          #endif          #endif
528    
529          uint vc = 0;          uint voiceCount = 0;
530          uint sc = 0;          uint streamCount = 0;
531          RTList<uint>::Iterator iuiKey = pEngineChannel->pActiveKeys->first();          RTList<uint>::Iterator iuiKey = pEngineChannel->pActiveKeys->first();
532          RTList<uint>::Iterator end    = pEngineChannel->pActiveKeys->end();          RTList<uint>::Iterator end    = pEngineChannel->pActiveKeys->end();
533          while (iuiKey != end) { // iterate through all active keys          while (iuiKey != end) { // iterate through all active keys
# Line 541  namespace LinuxSampler { namespace gig { Line 541  namespace LinuxSampler { namespace gig {
541                  itVoice->Render(Samples);                  itVoice->Render(Samples);
542                  if (itVoice->IsActive()) { // still active                  if (itVoice->IsActive()) { // still active
543                      ActiveVoiceCountTemp++;                      ActiveVoiceCountTemp++;
544                      vc++;                      voiceCount++;
545    
546                      if (itVoice->PlaybackState == Voice::playback_state_disk) {                      if (itVoice->PlaybackState == Voice::playback_state_disk) {
547                          if ((itVoice->DiskStreamRef).State == Stream::state_active) sc++;                          if ((itVoice->DiskStreamRef).State == Stream::state_active) streamCount++;
548                      }                      }
549                  }  else { // voice reached end, is now inactive                  }  else { // voice reached end, is now inactive
550                      FreeVoice(pEngineChannel, itVoice); // remove voice from the list of active voices                      FreeVoice(pEngineChannel, itVoice); // remove voice from the list of active voices
# Line 552  namespace LinuxSampler { namespace gig { Line 552  namespace LinuxSampler { namespace gig {
552              }              }
553          }          }
554                    
555          pEngineChannel->SetVoiceCount(vc);          pEngineChannel->SetVoiceCount(voiceCount);
556          pEngineChannel->SetDiskStreamCount(sc);          pEngineChannel->SetDiskStreamCount(streamCount);
557      }      }
558    
559      /**      /**
# Line 1744  namespace LinuxSampler { namespace gig { Line 1744  namespace LinuxSampler { namespace gig {
1744      }      }
1745    
1746      String Engine::Version() {      String Engine::Version() {
1747          String s = "$Revision: 1.78 $";          String s = "$Revision: 1.79 $";
1748          return s.substr(11, s.size() - 13); // cut dollar signs, spaces and CVS macro keyword          return s.substr(11, s.size() - 13); // cut dollar signs, spaces and CVS macro keyword
1749      }      }
1750    

Legend:
Removed from v.1297  
changed lines
  Added in v.1305

  ViewVC Help
Powered by ViewVC