| ▲ | waveywaves 8 hours ago | |
This is callback heavy audio code so this was the bigger problem for me mainly and learning about lifetimes was a pain initially. cpal's stream callback wants 'static which means you can't just pass references around. You end up using channels (crossbeam / std::sync::mpsc) between the audio thread and everything else. Once I structured around that it got smoother. I also got a lot of help from AI to understand and reimplement a lot of the parts for this as you can tell from the commit messages. | ||