Skip to content
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

api: support non-traditional key signatures #81

Merged
merged 4 commits into from
Apr 4, 2020

Conversation

webern
Copy link
Owner

@webern webern commented Apr 1, 2020

Closes #70
Replaces #77

Sourcecode/private/mx/impl/NoteReader.cpp Outdated Show resolved Hide resolved
Sourcecode/private/mx/impl/NoteWriter.cpp Outdated Show resolved Hide resolved
Sourcecode/private/mx/impl/PropertiesWriter.cpp Outdated Show resolved Hide resolved
Sourcecode/include/mx/api/KeyData.h Outdated Show resolved Hide resolved
@webern webern force-pushed the feature/non-traditional-key branch from ecf149b to 615b160 Compare April 2, 2020 01:44
const auto intAlter = static_cast<int>( xmlAlter );
const auto micro = xmlAlter - static_cast<mx::core::DecimalType> ( intAlter );
const auto microDistance = std::abs( micro );
if( microDistance >= 0.000000000001 )
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you want, you can use std::numeric_limits<double>::epsilon() which gives the smallest increment of the numeric type T you provide it with.

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll play around with that.

Copy link
Contributor

@p-groarke p-groarke left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can't wait to use this :) Ty for adding it!

@webern webern merged commit 7f4be10 into master Apr 4, 2020
@webern webern deleted the feature/non-traditional-key branch June 20, 2020 23:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[feature] mx::api NonTraditionalKey equivalent
2 participants