SPB Git

Repository Public

gs_two_hands.sonata 1.5 KB 59 lines

1// ORIX Sonata2// File: Examples/gs_two_hands.sonata3// Description: Two tracks of the same instrument, a melody and an accompaniment, panned slightly apart: the left hand is a pattern called once per bar.4//5// Author: Simon-Pierre Boucher6// Contact: contact@spboucher.ai7//8// category: Getting started9// title: Two Hands10// teaches: several tracks, pan, gain, patterns, rests11//12// expect: notes 4913// expect: tracks 214// expect: duration 10.9091s15// expect: deterministic16pattern waltz_bar(root: Pitch, upper: List<Pitch>) {17    play root duration 1/4 velocity 0.718    chord upper duration 1/4 velocity 0.4519    chord upper duration 1/4 velocity 0.4520}2122composition "Two Hands" {23    tempo 132bpm24    signature 3/425    key A minor2627    instrument right: GrandPiano {28        gain -4dB29        pan 0.1530        play E5 duration 1/231        play C5 duration 1/432        play D5 duration 1/233        play B4 duration 1/434        play C5 duration 1/435        play B4 duration 1/436        play A4 duration 1/437        play G#4 duration 3/438        play A4 duration 1/239        play C5 duration 1/440        play B4 duration 1/241        play E5 duration 1/442        play A4 duration 3/4 tie43        play A4 duration 3/444    }4546    instrument left: GrandPiano {47        gain -9dB48        pan -0.1549        waltz_bar(A2, [C4, E4])50        waltz_bar(G2, [B3, D4])51        waltz_bar(F2, [A3, C4])52        waltz_bar(E2, [G#3, B3])53        waltz_bar(A2, [C4, E4])54        waltz_bar(E2, [G#3, D4])55        waltz_bar(A2, [C4, E4])56        play A1 duration 3/457    }58}59
Files main
Menu

Theme