MuseScore  3.4
Music composition and notation
Public Member Functions | Private Attributes | List of all members
Ms::VoiceOverlapDetector Class Reference

Detect overlap in a voice, which is when a voice has two or more notes active at the same time. More...

#include <musicxmlsupport.h>

Public Member Functions

 VoiceOverlapDetector ()
 
void addNote (const int startTick, const int endTick, const QString &voice, const int staff)
 
void dump () const
 
void newMeasure ()
 
bool stavesOverlap (const QString &voice) const
 

Private Attributes

QMap< QString, NoteList_noteLists
 The notelists for all the voices. More...
 

Detailed Description

Detect overlap in a voice, which is when a voice has two or more notes active at the same time.

In theory this should not happen, as voices only move forward in time, but Sibelius 7 reuses voice numbers in multi- staff parts, which leads to overlap.

Current implementation does not detect voice overlap within a staff, but only between staves.

Constructor & Destructor Documentation

◆ VoiceOverlapDetector()

Ms::VoiceOverlapDetector::VoiceOverlapDetector ( )

Member Function Documentation

◆ addNote()

void Ms::VoiceOverlapDetector::addNote ( const int  startTick,
const int  endTick,
const QString &  voice,
const int  staff 
)

◆ dump()

void Ms::VoiceOverlapDetector::dump ( ) const

◆ newMeasure()

void Ms::VoiceOverlapDetector::newMeasure ( )

◆ stavesOverlap()

bool Ms::VoiceOverlapDetector::stavesOverlap ( const QString &  voice) const

Member Data Documentation

◆ _noteLists

QMap<QString, NoteList> Ms::VoiceOverlapDetector::_noteLists
private

The notelists for all the voices.


The documentation for this class was generated from the following files: