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

Different behavior on shared methods (SynthEvent/SampleEvent) #146

Closed
vustav opened this issue Jan 27, 2022 · 5 comments
Closed

Different behavior on shared methods (SynthEvent/SampleEvent) #146

vustav opened this issue Jan 27, 2022 · 5 comments
Assignees

Comments

@vustav
Copy link

vustav commented Jan 27, 2022

event.positionEvent(pos) works as intended on SampleEvents but on SynthEvents they play at full steps, ex. a SynthEvent set to play at 3 1/4 will play at 3 etc.

@igorski igorski self-assigned this Jan 28, 2022
@vustav
Copy link
Author

vustav commented Apr 24, 2022

Noticed now that after using synthEvent.setEventStart(posInSamples) they will play at the right position one time, then settling at the nearest full step before. This means I can get around this by updating positions every time the sequencer is at 0.

Still strange and as I said it works fine on SampleEvents so I don't think I'm using it the wrong way.

@igorski
Copy link
Owner

igorski commented Apr 26, 2022

Hi @vustav thanks for pointing this out, looks like a bug in the synthesis routine and has indeed to do with first time playback. Will address this shortly.

@igorski igorski added the bug label Apr 26, 2022
@igorski
Copy link
Owner

igorski commented Apr 27, 2022

This has been addressed in f592455

Can you verify whether this addresses the issue in the context of your application ? If all is correct, you no longer need to update the event positions whenever the sequencer reaches the zero offset any longer. Additionally, if you were using BaseSynthEvent.invalidateProperties() before, there is no need to do so any longer as the engine handles this internally. If you were using that method to reposition the event, you can use the setPosition|setEventStart-methods from the (Base)AudioEvent API instead.

@vustav
Copy link
Author

vustav commented Apr 27, 2022

Works perfect now!

@igorski
Copy link
Owner

igorski commented Apr 27, 2022

Excellent! Thanks so much for pointing out the issue.

@igorski igorski closed this as completed Apr 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants