-
Notifications
You must be signed in to change notification settings - Fork 6
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
Sync code execution to host transport #5
Comments
Hi @hellocatfood! Thanks for opening this issue. There is some background processing even when the transport is not playing, but the patterns aren’t executed and don’t produce any values during this time. It just first returns note off to cutoff playing notes and then returns an empty buffer. The gui and gpu stuff is ongoing forever, but it shouldn’t affect the audio thread. There is still a kind of an issue, that you have to execute your code any time you reopen the project. I’m going to make it execute all tabs from the rightmost to the leftmost when plugin is loaded from the state. |
I think the main reason I ask for this is so that it kept in syn with whatever else is happening in the host. For example I have a drum pattern created with kotoist that I want to be played back in sync with the melody I have created in midi in Ardour |
Ah, I see. This happens because there is no reset mechanism in the pattern itself. Also, patterns know nothing about position. They just produce next values when it's time for them. One after another. If you need to reset them or start from a particular position, take a look at |
I've updated these callbacks to receive cursor position and tempo. |
Thank you! I'll let you know how it goes trying it out. |
Is there a way to have the code execute only once transport is started in the host?
Using Ardour and the code example you provided, the code is executed when I press Run in Kotoist and then can be heard when I press play in Ardour. Playback stops when I stop transport, but it appears that the code is still being executed in the background.
The text was updated successfully, but these errors were encountered: