protected void doRowEvent ( ) { final PatternRow patternRow = currentPattern . getPatternRow ( currentRow ) ; if ( patternRow == null ) return ; patternRow . setRowPlayed ( ) ; final int nChannels = mod . getNChannels ( ) ; for ( int c = 0 ; c < nChannels ; c ++ ) { // get pattern and channel memory data for current channel final PatternElement element = patternRow . getPatternElement ( c ) ; final ChannelMemory aktMemo = channelMemory [ c ] ; // reset all effects on this channel resetAllEffects ( aktMemo , element , false ) ; // Now copy the pattern data but remain old values for note and instrument aktMemo . currentElement = element ; if ( element . getPeriod ( ) > 0 ) aktMemo . assignedNotePeriod = element . getPeriod ( ) ; if ( element . getNoteIndex ( ) > 0 ) aktMemo . assignedNoteIndex = element . getNoteIndex ( ) ; if ( element . getInstrument ( ) > 0 ) { aktMemo . assignedInstrumentIndex = element . getInstrument ( ) ; aktMemo . assignedInstrument = mod . getInstrumentContainer ( ) . getInstrument ( element . getInstrument ( ) - 1 ) ; } aktMemo . effekt = element . getEffekt ( ) ; aktMemo . effektParam = element . getEffektOp ( ) ; aktMemo . volumeEffekt = element . getVolumeEffekt ( ) ; aktMemo . volumeEffektOp = element . getVolumeEffektOp ( ) ; // Key Off? if ( element . getPeriod ( ) == Helpers . KEY_OFF || element . getNoteIndex ( ) == Helpers . KEY_OFF ) { aktMemo . keyOff = true ; } else if ( element . getPeriod ( ) == Helpers . NOTE_CUT || element . getNoteIndex ( ) == Helpers . NOTE_CUT ) { aktMemo . fadeOutVolume = 0 ; } else if ( ! isNoteDelayEffekt ( aktMemo ) ) // If this is a noteDelay, we lose for now, this is all done later! { setNewInstrumentAndPeriod ( aktMemo ) ; } processEffekts ( false , aktMemo ) ; } }
Do the Events of a new Row!