mirror of
https://codeberg.org/unspeaker/tek.git
synced 2025-12-06 19:56:42 +01:00
the definitions are unified alright. it's just not supported yet :D the idea being that tek offers to write out the default configs to ~/.config/tek-v0 where the user can customize them.
This commit is contained in:
parent
9e147cda69
commit
2e5462c4e7
42 changed files with 426 additions and 411 deletions
|
|
@ -86,9 +86,7 @@ impl Cli {
|
|||
let right_tos = Connect::collect(&self.right_to, empty, empty);
|
||||
let audio_froms = &[left_froms.as_slice(), right_froms.as_slice()];
|
||||
let audio_tos = &[left_tos.as_slice(), right_tos.as_slice()];
|
||||
let clip = Arc::new(RwLock::new(MidiClip::new(
|
||||
"Clip", true, 384usize, None, Some(ItemColor::random().into())),
|
||||
));
|
||||
let clip = Arc::new(RwLock::new(MidiClip::new("Clip", true, 384usize, None, Some(ItemColor::random().into()))));
|
||||
Tui::new()?.run(&Jack::new_run(&name, move|jack|{
|
||||
for (index, connect) in midi_froms.iter().enumerate() {
|
||||
midi_ins.push(jack.midi_in(&format!("M/{index}"), &[connect.clone()])?);
|
||||
|
|
@ -96,14 +94,7 @@ impl Cli {
|
|||
for (index, connect) in midi_tos.iter().enumerate() {
|
||||
midi_outs.push(jack.midi_out(&format!("{index}/M"), &[connect.clone()])?);
|
||||
};
|
||||
let config = Configuration::from_path(&match self.mode {
|
||||
LaunchMode::Clock => "config/config_transport.edn",
|
||||
LaunchMode::Sequencer => "config/config_sequencer.edn",
|
||||
LaunchMode::Groovebox => "config/config_groovebox.edn",
|
||||
LaunchMode::Arranger { .. } => "config/config_arranger.edn",
|
||||
LaunchMode::Sampler => "config/config_sampler.edn",
|
||||
_ => todo!("{:?}", self.mode),
|
||||
}, false)?;
|
||||
let configs = Configurations::init();
|
||||
let clock = Clock::new(&jack, self.bpm)?;
|
||||
match self.mode {
|
||||
LaunchMode::Sequencer => tracks.push(Track::new(
|
||||
|
|
@ -117,9 +108,9 @@ impl Cli {
|
|||
_ => {}
|
||||
}
|
||||
let mut app = App {
|
||||
jack: jack.clone(),
|
||||
config,
|
||||
color: ItemTheme::random(),
|
||||
jack: jack.clone(),
|
||||
configs: Configurations::init()?,
|
||||
color: ItemTheme::random(),
|
||||
pool: match self.mode {
|
||||
LaunchMode::Sequencer | LaunchMode::Groovebox => (&clip).into(),
|
||||
_ => Default::default()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue