(
// MAIN LAUNCH (loads necessary files and definitions)

var appEnvironment, cond;

s.boot;

appEnvironment = Environment.make;
appEnvironment.push;

// load
"a_lot_of_tiles_trivial_scan_tiler.scd".loadRelative;
"a_lot_of_tiles_trivial_scan_visualizer.scd".loadRelative;
"a_lot_of_tiles_trivial_scan_sonifier.scd".loadRelative;
"a_lot_of_tiles_trivial_scan_gui.scd".loadRelative;
"a_lot_of_tiles_trivial_scan_transcriber.scd".loadRelative;

// init
~dir = thisProcess.nowExecutingPath.dirname;
~loadedTransform = nil;
~transform = [2, 1, 0, 1, 0, 0, 0];
~tileMap = ~mapAll.value(6 /*max depth*/, ~transform);
~layoutState = 0;
~tempo = 120;
~dur = 0.125 * (120/~tempo);
~continuousPlay = false;

// launch
~launchTileVisualizer.value;
~launchGui.value;

appEnvironment.pop;
)
