mirror of
https://codeberg.org/unspeaker/tek.git
synced 2025-12-08 04:36:45 +01:00
wip: tying it together...
This commit is contained in:
parent
bbafb72e9b
commit
ad2f75bee6
7 changed files with 76 additions and 115 deletions
|
|
@ -73,16 +73,12 @@ pub struct Arrangement<E: Engine> {
|
|||
pub struct ArrangementTrack {
|
||||
/// Name of track
|
||||
pub name: Arc<RwLock<String>>,
|
||||
/// Inputs
|
||||
pub inputs: Vec<Port<MidiIn>>,
|
||||
/// MIDI player/recorder
|
||||
pub player: PhrasePlayer,
|
||||
/// Outputs
|
||||
pub outputs: Vec<Port<MidiIn>>,
|
||||
/// Preferred width of track column
|
||||
pub width: usize,
|
||||
/// Identifying color of track
|
||||
pub color: Color,
|
||||
/// MIDI player/recorder
|
||||
pub player: PhrasePlayer,
|
||||
}
|
||||
#[derive(Default, Debug)]
|
||||
pub struct Scene {
|
||||
|
|
@ -515,11 +511,9 @@ impl ArrangementTrack {
|
|||
pub fn new (clock: &Arc<TransportTime>, name: &str, color: Option<Color>) -> Self {
|
||||
Self {
|
||||
name: Arc::new(RwLock::new(name.into())),
|
||||
inputs: vec![],
|
||||
player: PhrasePlayer::new(clock),
|
||||
outputs: vec![],
|
||||
width: name.len() + 2,
|
||||
color: color.unwrap_or_else(random_color)
|
||||
color: color.unwrap_or_else(random_color),
|
||||
player: PhrasePlayer::new(clock),
|
||||
}
|
||||
}
|
||||
pub fn longest_name (tracks: &[Self]) -> usize {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue