How to get per step events with Sunvox lib?

Multi-platform modular music creation studio
Post Reply
maks
Posts: 43
Joined: Sat Mar 26, 2022 4:28 am

How to get per step events with Sunvox lib?

Post by maks »

Hi,
I know that Sunvox lib doesn't deal with Midi system messages which is fine because my code already has a Midi implementation, but what I'm stuck on is how to handle midi output from a Sunvox pattern track?
What I mean is that there is: sv_audio_callback() and sv_audio_callback2() to get audio data frames output but I can't see anything similar to register a callback to get the per step note/velocity data (for each track in a pattern) so I would send that out via Midi to external instruments.

The Sunvox app itself has Midi out for each instrument, so I guess it has some sort of implementation for this.

Not sure if I have missed something obvious in the (very good!) Sunvox lib documentation, so I'm sorry if this is a silly question.
User avatar
NightRadio
Site Admin
Posts: 3941
Joined: Fri Jan 23, 2004 12:28 am
Location: Ekaterinburg. Russia
Contact:

Re: How to get per step events with Sunvox lib?

Post by NightRadio »

Sorry but MIDI is not implemented in SunVox lib at all. And you can't capture output events from the engine.
The only advice I can give is to process the contents of the patterns manually using the sv_get_current_line() and sv_get_pattern_data() functions
Post Reply