Logo Search packages:      
Sourcecode: rosegarden version File versions  Download package

void Rosegarden::RosegardenDocument::transposeRecordedSegment ( Segment s ) [protected]

Transpose an entire segment relative to its destination track. This is used for transposing a source MIDI recording segment on a per-track basis, so that the results all come out with the same sound as the original recording.

Definition at line 2009 of file RosegardenDocument.cpp.

References Rosegarden::Segment::fillWithRests(), and Rosegarden::Segment::setStartTime().

                Segment *recordMIDISegment = it->second;
                if (recordMIDISegment->size() == 0) {
                    recordMIDISegment->setStartTime (m_composition.getBarStartForTime(absTime));

            // Now insert the new event
            insertRecordedEvent(rEvent, device, channel, isNoteOn);
            delete rEvent;

        if (haveNotes) {

            QSettings settings;
            settings.beginGroup( GeneralOptionsConfigGroup );

            int tracking = settings.value("recordtracking", 0).toUInt() ;
            if (tracking == 1) { // notation
                for (RecordingSegmentMap::const_iterator it = m_recordMIDISegments.begin();
                     it != m_recordMIDISegments.end(); ++it) {

                    Segment *recordMIDISegment = it->second;

                    EventQuantizeCommand *command = new EventQuantizeCommand
                         "Notation Options",
                    // don't add to history

            // this signal is currently unused - leaving just in case
            // recording segments are updated through the SegmentObserver::eventAdded() interface
            //         emit recordMIDISegmentUpdated(m_recordMIDISegment, updateFrom);

Here is the call graph for this function:

Generated by  Doxygen 1.6.0   Back to index