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

Microtuning affects oscillator display #1590

Closed
mkruselj opened this issue Feb 18, 2020 · 2 comments · Fixed by #1591
Closed

Microtuning affects oscillator display #1590

mkruselj opened this issue Feb 18, 2020 · 2 comments · Fixed by #1591
Labels
UI Issues related to UI look&feel

Comments

@mkruselj
Copy link
Collaborator

  1. Load ED2-5 microtuning from factory tuning library
  2. Pick one of the oscillators (click on a tab)
  3. Osc waveform changes

Obviously waveform display is drawn by sending a MIDI note number then rendered by the resulting tone, but microtuning messes with this. I assume this is middle C (261 Hz in 12-TET 440 Hz). A number of microtunings mess this frequency up, so maybe there should be a way to force the waveform display to always draw at 261 Hz?

@mkruselj mkruselj added the UI Issues related to UI look&feel label Feb 18, 2020
@baconpaul
Copy link
Collaborator

float disp_pitch_rs = disp_pitch + 12.0 * log2(dsamplerate / 44100.0);

The code is in pitch space. 95.15-48+some goop is the pitch but that must imply a frequency so I can find that frequency or close to it in pitch space instead ... should be a smallish fix. Nice find!

@baconpaul
Copy link
Collaborator

OK I've confirmed the note being played is around note 42 but what we really want is "the note where the pitch is 11.414" (pitch is basically frequency / 8.16etc... and is the internal representation surge uses).

So the fix here is to, if in non-standard-tuning, find a pair of notes which bracket the ignored tuning. Not that hard but a bit tedious. Will fix before we ship 1.6.6

baconpaul added a commit to baconpaul/surge that referenced this issue Feb 18, 2020
The OSC display pitch is a note but that note gives a radically
different frequency on short and long scales, improperly changing the
oscillator display. Instead search for a note which has the pitch
we want when in non-standard tuning.

Closes surge-synthesizer#1590
baconpaul added a commit that referenced this issue Feb 18, 2020
The OSC display pitch is a note but that note gives a radically
different frequency on short and long scales, improperly changing the
oscillator display. Instead search for a note which has the pitch
we want when in non-standard tuning.

Closes #1590
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
UI Issues related to UI look&feel
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants