Experimental imperative-style music sequence generator engine

https://news.ycombinator.com/rss Hits: 9
Summary

pattrns pattrns is an experimental imperative-style music sequence generator engine. It allows you to programmatically create music sequences either in plain Rust as library (static, compiled) or in Lua as a scripting engine (dynamic, interpreted). So it's also suitable for live coding music. In addition to its imperative event generator approach, it also supports the creation of musical events using tidalcycle's mini-notation. This crate only deals with the generation of raw musical events. It does not generate audio. You must use an application with built-in support for pattrns to use it. Conceptional Overview pattrns generates musical sequences using three distinct components, stages: Rhythm : ( pulse in scripts) dynamic pulse generator to define a rhythmical pulse train. : ( in scripts) dynamic pulse generator to define a rhythmical pulse train. Gate : ( gate in scripts) optional pulse filter between rhythm and event emitter. : ( in scripts) optional pulse filter between rhythm and event emitter. Emitter: ( event in scripts), dynamic note or parameter event generator which gets triggered by the pulse train. By separating the rhythmical from the tonal part of a musical sequence, each part can be freely modified, composed and (re)combined as it fits. Documentation & Guides Read the Scripting Book. It contains an introduction, guides, full Lua API documentation and bunch of script examples. The Rust backend uses standard Rust documentation features. The docs are currently not hosted online (yet), but you can generate them locally via cargo doc --open . Applications Online Playground is a simple browser based playground app. It allows you to learn and test how pattrns works. Renoise uses pattrns in its phrase editor. Integration Examples examples/play.rs demonstrates how to use patterns using only Rust: it defines and plays a little music thing. The content can only be changed at compile time. examples/play-script.rs is an example using the Lua API: it also defines ...

First seen: 2025-07-13 06:53

Last seen: 2025-07-13 14:55