In case of running out of prefetch pipes, truncate the sample to the preloaded part.
[calfbox.git] / API
blob07f95223ac3281d0570b59aad775c45af67d5cc4
1 @module >> @chorus, @phaser, ...
3 @moduleslot/status() ->
4     /insert_engine(string engine),
5     /insert_preset(string preset),
6     /bypass(int bypassed)
7 @moduleslot/insert_engine(string engine)
8 @moduleslot/insert_preset(string engine)
9 @moduleslot/engine/{add: @module}
10 @moduleslot/set_bypass(int bypassed)
12 @track/add_clip(int pos, int offset, int length, string pattern)
14 /master/
15 /master/status() -> /sample_rate, /tempo, /timesig, /playing, /pos, /pos_ppqn
16 /master/tell() -> /playing, /pos, /pos_ppqn
17 /master/set_tempo(float tempo)
18 /master/set_timesig(int num, int denom)
19 /master/play()
20 /master/stop()
21 /master/seek_samples(int samples)
22 /master/seek_ppqn(int ppqn)
24 /meter/
25 /meter/get_peak() -> /peak(float left, float right)
26 /meter/get_rms() -> /rms(float left, float right)
28 /config/
29 /config/sections([string prefix]) -> [/section(string name)]
30 /config/keys(string section, string ?prefix) -> [/section(string name)]
31 /config/get(string section, string key) -> /value(string value)
32 /config/set(string section, string key, string value)
33 /config/delete(string section, string key)
34 /config/delete_section(string section)
35 /config/save(string ?filename)
37 /engine/
38 /engine/status() -> /scene(object scene)
39 /engine/render_stereo(int nframes)
40 /engine/master_effect/{add: @moduleslot}
41 /engine/new_scene() -> uuid
42 /engine/new_recorder() -> uuid
44 /scene/
45 /scene/transpose(int semitones)
46 /scene/clear()
47 /scene/load(string scene_name)
48 /scene/add_layer(int layer_pos, string layer_name)
49 /scene/add_instrument_layer(int layer_pos, string instrument_name)
50 /scene/delete_layer(int pos)
51 /scene/move_layer(int oldpos, int newpos)
52 /scene/instr/
53 /scene/instr/<name>/status() ->
54     /engine(string name),
55     /aux_offset(int first_aux_output_no),
56     /outputs(int stereo_output_count)
57 /scene/instr/<name>/output/<index>/status() ->
58     /gain_linear(float gain),
59     /gain(float gain_dB),
60     /output(int output_bus),
61     {add: @moduleslot/status()}
62 /scene/instr/<name>/output/<index>/gain(float gain_dB),
63 /scene/instr/<name>/output/<index>/output(int output_bus)
64 /scene/instr/<name>/output/<index>/{add: @moduleslot}
65 /scene/instr/<name>/aux/<index>/status() ->
66     /gain_linear(float gain),
67     /gain(float gain_dB),
68     /bus(string output_bus),
69     {add: @moduleslot/status()} XXXKF ????
70 /scene/instr/<name>/aux/<index>/gain(float gain_dB)
71 /scene/instr/<name>/aux/<index>/bus(string bus)
72 /scene/instr/<name>/aux/<index>/{add: @moduleslot}
73 /scene/layer/<index>/
74 /scene/layer/<index>/status() ->
75     /enable(int),
76     /instrument_name(string iname),
77     /instrument_uuid(string uuid),
78     /consume(int consume),
79     /ignore_scene_transpose(int ignore),
80     /disable_aftertouch(int disable),
81     /transpose(int semitones),
82     /fixed_note(int note),
83     /low_note(int note),
84     /high_note(int note),
85     /in_channel(int channel),
86     /out_channel(int channel)
87 /scene/layer/<index>/enable(int)
88 /scene/layer/<index>/instrument_name(string iname)
89 /scene/layer/<index>/consume(int consume)
90 /scene/layer/<index>/ignore_scene_transpose(int ignore)
91 /scene/layer/<index>/disable_aftertouch(int disable)
92 /scene/layer/<index>/transpose(int semitones)
93 /scene/layer/<index>/fixed_note(int note)
94 /scene/layer/<index>/low_note(int note)
95 /scene/layer/<index>/high_note(int note)
96 /scene/layer/<index>/in_channel(int channel)
97 /scene/layer/<index>/out_channel(int channel)
98 /scene/aux/<name>/status
99 /scene/aux/<name>/slot/{add: @module}
100 /scene/load_aux(string name)
101 /scene/delete_aux(string name)
102 /scene/status() ->
103     /name(string),
104     /title(string),
105     /transpose(int semitones),
106     [/layer(string uuid)],
107     [/instrument(string instance, string engine)],
108     [/aux(string name, string uuid)]
110 /rt/
111 /rt/status() -> /audio_channels(int inputs, int outputs)
112 /song/
113 /song/status() -> [/track(int index, string name, int items)], [/pattern(int index, string name, int length)]
114 /waves/
115 /waves/status() -> /bytes(int bytes), /max_bytes(int max_bytes), /count(int count)
116 /waves/list() -> [/waveform(int id)]
117 /waves/info(int id) -> /filename(string), /name(string), /bytes(int)
118 /on_idle() -> {any}
119 /send_event_to(string output, int)
120 /send_event_to(string output, int, int)
121 /send_event_to(string output, int, int, int)
122 /play_note(int ch, int note, int velocity) (plays a note with duration=1 on the next buffer)
123 /play_drum_pattern(string pattern)
124 /play_drum_track(string track)
125 /play_blob(blob serialized_pattern, int length_ticks)
126 /stop_pattern()
127 /get_pattern() -> /pattern(blob serialized_pattern, int length_ticks)
128 /print_s(string)
129 /print_i(int)
130 /print_f(float)
131 /new_meter() -> /uuid
132 /new_recorder(string filename) -> /uuid