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

y to pitch converter #2398

Closed
walterbender opened this issue Jul 9, 2020 · 5 comments · Fixed by #2429
Closed

y to pitch converter #2398

walterbender opened this issue Jul 9, 2020 · 5 comments · Fixed by #2429
Assignees
Milestone

Comments

@walterbender
Copy link
Member

Now that we have a staff display, it would be handy to have a block that converts from Y to pitch. (We'd have to assume natural as opposed to sharp or flat, but it would still be quite useful.)

@aviral243
Copy link
Member

Would this work as an argument to some block (pitch) and play the corresponding pitch?

@walterbender
Copy link
Member Author

If the block is attached to a pitch number block, it is just the pitch number.
If it is attached to the nth model pitch block, it takes into account the key.
If it is attached to print block, it is nth model pitch with key.
If it is attached to a pitch block, it is nth model pitch with key.
If it is unattached to anything, it is just pitch number.

@pikurasa
Copy link
Collaborator

If the block is attached to a pitch number block, it is just the pitch number.

If it is attached to a pitch number block, it takes into account "set pitch number offset" (if present)

@aviral243
Copy link
Member

If it is attached to the nth model pitch block, it takes into account the key.

Regarding this, taking into account the key would translate like this:

Default mapping:
0 - C4
12.5 - D4
.. and so, till 75, for all 7 notes of C major.

Assuming to be in key G major:
0 - G4,
12.5 - A4
.. and so.

Am I right here? @walterbender @pikurasa

@walterbender
Copy link
Member Author

C4 is always 0. The mode/key doesn't matter.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants