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

Add support for offset_cc #170

Merged
merged 5 commits into from
Apr 16, 2020
Merged

Add support for offset_cc #170

merged 5 commits into from
Apr 16, 2020

Conversation

paulfd
Copy link
Member

@paulfd paulfd commented Apr 7, 2020

Closes #159

It will be cleaner once the changes from #166 are merged

@paulfd paulfd linked an issue Apr 13, 2020 that may be closed by this pull request
@jpcima
Copy link
Collaborator

jpcima commented Apr 15, 2020

Rebased in order to make it readable (since the base branch changed after the PR)

@@ -59,6 +59,12 @@ bool sfz::Region::parseOpcode(const Opcode& opcode)
case hash("offset_random"):
setValueFromOpcode(opcode, offsetRandom, Default::offsetRange);
break;
case hash("offset_cc&"):
if (opcode.parameters.back() > config::numCCs)
Copy link
Collaborator

Choose a reason for hiding this comment

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

I note there exist multiple occurrences of ccNumber > config::numCCs in code.
There is also for (int cc = 0; cc < config::numCCs; cc++).
One of these has to be wrong. Perhaps instead the checks should use >=.

Copy link
Member Author

Choose a reason for hiding this comment

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

You're right it should be >= in all these checks.

@jpcima jpcima merged commit 4f573a6 into sfztools:develop Apr 16, 2020
@paulfd paulfd deleted the offset-cc branch January 21, 2022 10:24
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.

Add support for offset_cc
2 participants