New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automatic control of JACK/ALSA MIDI Out ports #1171

Merged
merged 1 commit into from Nov 28, 2014

Conversation

Projects
None yet
2 participants
@Igevorse
Contributor

Igevorse commented Aug 19, 2014

With this feature MuseScore users can deal with MIDI faster and more comfortable. Now they don't need to think about MIDI Out ports number ("-Why it doesn't sound? <...> Ah, I have to increase midi ports number...").

I used "lazy" approach to prevent flooding to JACK/ALSA with a lot of API calls: we add new ports only if we really need to do it (e.g. when opening a score with a lot of staves OR when adding a new instrument).

Example: If we have several scores opened with 1, 3 and 2 midi ports, we'll have 3 midi out ports even if we switch between scores (would not change from 1 to 3 and 2).

Recomputing number of midi ports is also optimized: we don't need to do an extra loop every second/tick/etc.

You can read about this new feature here:
http://igevorse.lited.net/p14.html
http://igevorse.lited.net/p18.html

@Igevorse Igevorse referenced this pull request Aug 19, 2014

Closed

Assigning channels #1083

@Igevorse

This comment has been minimized.

Show comment
Hide comment
@Igevorse

Igevorse Sep 4, 2014

Contributor

Merge conflicts resolved.

Contributor

Igevorse commented Sep 4, 2014

Merge conflicts resolved.

@Igevorse Igevorse changed the title from Automatic control of JACK/ALSA MIDI Out ports to Automatic control of JACK/ALSA MIDI Out ports [DON'T MERGE] Nov 1, 2014

@Igevorse Igevorse changed the title from Automatic control of JACK/ALSA MIDI Out ports [DON'T MERGE] to Automatic control of JACK/ALSA MIDI Out ports Nov 27, 2014

Show outdated Hide outdated libmscore/score.cpp
@@ -322,6 +322,7 @@ void Score::init()
_tempomap = 0;
_layoutMode = LayoutMode::PAGE;
_noteHeadWidth = 0.0; // set in doLayout()
maxPortNumber = 0;

This comment has been minimized.

@lasconic

lasconic Nov 27, 2014

Member

can you name it with _ and call the getter maxPortNumber like other accessors?

@lasconic

lasconic Nov 27, 2014

Member

can you name it with _ and call the getter maxPortNumber like other accessors?

Show outdated Hide outdated libmscore/score.h
@@ -378,6 +378,7 @@ class Score : public QObject {
qreal _noteHeadWidth;
QString accInfo; ///< information used by the screen-reader
int maxPortNumber;

This comment has been minimized.

@lasconic

lasconic Nov 27, 2014

Member

Please add a comment to describe it. Mention it make sense only for rootscore

@lasconic

lasconic Nov 27, 2014

Member

Please add a comment to describe it. Mention it make sense only for rootscore

lasconic added a commit that referenced this pull request Nov 28, 2014

Merge pull request #1171 from Igevorse/instrument-change
Automatic control of JACK/ALSA MIDI Out ports

@lasconic lasconic merged commit bddb38f into musescore:master Nov 28, 2014

1 check passed

continuous-integration/travis-ci The Travis CI build passed
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment