# Opens a file as a take and plays it both ways: a 2 s log sweep (40 Hz to # 16 kHz) over a quiet 440 Hz tone. console open test/sweep.wav frames 2 expect takes.len 1 expect selected 0 expect transport.value stopped key right expect transport.value forward frames 30 expect-audio 1 screenshot .zig-cache/micscope/forward.png key left expect transport.value backward expect backward true frames 20 key space expect transport.value stopped # Space resumes the way it last went. key space expect transport.value backward key space # Seeking: keys, and a click on the take's timeline. key end expect seek.value 1 click 400 150 expect seek.serial 2 # Ctrl+wheel (or a pinch) on a take's timeline zooms its time around the # pointer; Z zooms back out. hold left_ctrl wheel 400 150 3 release left_ctrl key z key right frames 30 screenshot .zig-cache/micscope/played.png # A second take goes under the first and is selected; up is older. console open test/sweep.wav expect takes.len 2 expect selected 1 key up expect selected 0 key down expect selected 1 # A click on the first take selects it. click 400 150 expect selected 0 frames 2 screenshot .zig-cache/micscope/two-takes.png # Deleting it leaves the second. Its file stays: going back to before the # deletion reads it again. console save two key delete expect takes.len 1 expect selected 0 console load two frames 2 expect takes.len 2 key delete expect takes.len 1 # A counter that names a take file already written (--fresh keeps the # files; a seek back finds the future's) is moved past it by draw. console set next_id 1 frames 2 expect next_id 3 # More takes than fit: the camera follows the bottom until the wheel pans # it, then 0 shows the whole strip. console open test/sweep.wav console open test/sweep.wav console open test/sweep.wav expect follow true wheel 400 400 2 expect follow false frames 2 screenshot .zig-cache/micscope/panned.png key 0 expect follow true frames 2 screenshot .zig-cache/micscope/overview.png # Ctrl+wheel off the timelines zooms the view. hold left_ctrl wheel 1150 400 1 release left_ctrl frames 2 screenshot .zig-cache/micscope/zoomed-view.png # The buttons on top do what the keys do, for touch screens. click 832 18 expect transport.value recording click 832 18 expect transport.value stopped click 890 18 expect transport.value forward click 890 18 expect transport.value stopped click 1238 18 expect a4 441 frames 2 screenshot .zig-cache/micscope/buttons.png