This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
javascript: (function() { | |
let counter; | |
let tapTimes = []; | |
function initialize() { | |
const tapTempoElement = document.getElementById("tap-tempo-counter"); | |
if (tapTempoElement) { | |
counter = tapTempoElement | |
} else { | |
counter = document.createElement("div"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Recorder } from "./recorder.ts"; | |
type Nullable <T> = T | null; | |
export class InputRecorder { | |
private callback: (url: string) => void; | |
private _launchButton: Nullable<HTMLButtonElement>; | |
private _recordButton: Nullable<HTMLButtonElement>; | |
private _stopButton: Nullable<HTMLButtonElement>; | |
private _errorLabel: Nullable<HTMLDivElement>; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- drummer | |
-- 4 track pattern sequencer | |
-- pattern notation looks like this 'x---x---x---x---' | |
-- update sequence track with set(track, pattern) | |
-- | |
-- queue a new sequence | |
-- progress(seq table, period - by default 16) | |
-- | |
-- control transport | |
-- start() stop() reset() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- ffmpeg batch convert mp3 to 128k mp3 | |
for i in *.mp3; do ffmpeg -i "$i" -codec:a libmp3lame -b:a 128k "${i%.*}128.mp3"; done | |
-- ffmpeg batch convert audio files from flac to wav | |
for i in *.flac; do ffmpeg -i "$i" "${i%.*}.wav"; done | |
-- batch convert aiff to wav with sox | |
find -E . -maxdepth 1 -iregex '.*\.(aif|aiff)' -exec bash -c '$0 "$1" "${1%.*}.wav"' sox {} \; | |
-- ffmpeg john cage 4'33 |