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

Diff of /linuxsampler/trunk/src/engines/AbstractEngineChannel.cpp

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

revision 2596 by schoenebeck, Thu Jun 5 19:39:12 2014 UTC revision 2598 by schoenebeck, Fri Jun 6 12:38:54 2014 UTC
# Line 887  namespace LinuxSampler { Line 887  namespace LinuxSampler {
887          }          }
888          eventQueueReader.free(); // free all copied events from input queue          eventQueueReader.free(); // free all copied events from input queue
889      }      }
890        
891      /**      /**
892       * Called by real-time instrument script functions to schedule a new event       * Called by real-time instrument script functions to schedule a new event
893       * somewhere in future.       * somewhere in future.
894         *
895         * @returns unique event ID of scheduled new event
896       */       */
897      void AbstractEngineChannel::ScheduleEvent(const Event* pEvent, int delay) { //TODO: delay not implemented yet      int AbstractEngineChannel::ScheduleEvent(const Event* pEvent, int delay) { //TODO: delay not implemented yet
898          // since delay is not implemented yet, we simply add the new event          // since delay is not implemented yet, we simply add the new event
899          // to the event list of the current audio fragmet cycle for now          // to the event list of the current audio fragmet cycle for now
900          RTList<Event>::Iterator itEvent = pEvents->allocAppend();          RTList<Event>::Iterator itEvent = pEvents->allocAppend();
901          if (itEvent) *itEvent = *pEvent; // copy event          if (itEvent) *itEvent = *pEvent; // copy event
902            return pEvents->getID(itEvent);
903        }
904    
905        /**
906         * Called by real-time instrument script functions to ignore the event
907         * reflected by given event ID. The event will be freed immediately to its
908         * pool and cannot be dereferenced by its old ID anymore. Even if its
909         * allocated back from the Pool later on, it will have a different ID.
910         */
911        void AbstractEngineChannel::IgnoreEvent(int id) {
912            RTList<Event>::Iterator it = pEvents->fromID(id);
913            if (it) pEvents->free(it);
914      }      }
915    
916      FxSend* AbstractEngineChannel::AddFxSend(uint8_t MidiCtrl, String Name) throw (Exception) {      FxSend* AbstractEngineChannel::AddFxSend(uint8_t MidiCtrl, String Name) throw (Exception) {

Legend:
Removed from v.2596  
changed lines
  Added in v.2598

  ViewVC Help
Powered by ViewVC