Skip to content

Instantly share code, notes, and snippets.

@on-three
on-three / gist:9e40cbf33765dbd3ffbb
Last active October 11, 2022 14:09
VLC capture window by xwindows id (window capture and streaming WITH audio)
1: Get the audio output device you'll record off:
pacmd list-sources | awk '/name:.+\.monitor/'
name: <alsa_output.pci-0000_01_00.1.hdmi-stereo.monitor>
name: <alsa_output.pci-0000_00_1b.0.analog-stereo.monitor>
2: Get the x windows id (linux) of the window you'll capture
xwininfo -name "Nestopia"
xwininfo: Window id: 0x3a00003 "Nestopia"
...
@on-three
on-three / gist:651ae0cb58d2fd463116
Last active November 9, 2021 08:37
ascii shit
▒▒▒▌▒▒▒▒▒▒▒▒▒▒▒▒▒▄▀▒▒▒▒▒▒▒▒▒▐▒▒
▒▒▐▒▒▒▒▒▒▒▌▒▒▒▒▒▌▒▒▒▒▒▐▒▒▌▒▒▒▌▒
▒▒▌▐▒▒▒▒▒▐▒▒▒▒▄▌▒▒▄▀▒▄▌▌▒▐▒▒▒▌▒
▒▒▌▌▒▒▒▒▌▌▒▒▒█▐▒▄▀░▄▀▐░▐▒▐▒▒▐▒▒
▒▒▌▌▒▒▒▐▐▒▒▒▐░▌▀░▄▀░░▌░▐▒▐▒▒▄▒▐
▄▀▄▒▒▒▒▌▒▒▄▀▌▐▌▀▀▄▄▄▐░░▌▒▒▄▀▌▒▐
▐░░▌▒▒▐▒▄▀░▐▄▄▄▀▀▄░▌▀▀▀▐▒▄▀░▌▒▌
▌░▌▐▒▒▄▀░░░███▀▐░▐▌░░░▄▀▀░▀▄▐▒▌
▐▐░▌▒▐░░░░░▐███░░░░░░░░░░░▀▀▌▒▒
▄░░▀▄▌░░░░░░▀▀░░░░░░░░░░█▀▌▐▒▒▒
@on-three
on-three / gist:11326444
Created April 26, 2014 17:48
AVI synth montage script
This is the avisynth script ("montage.avs"):
---
Setmemorymax(512)
SetMTMode(2,4)
grid=24
a1=directshowsource("input1.webm",audio=false).converttorgb
l=ceil(float(a1.framecount)/(grid*grid))
function HRepeat(clip c, int g, int l, int x, int y) {
@on-three
on-three / gist:f6bc18204767a2b545f1
Created May 14, 2014 01:49
Extracting .zip files with Shift-JIS (Japanese) filenames
unzip -O shift-jis <filename>.zip
[00007f15b0024930] main decoder error: Could not convert timestamp 0 for FFmpeg
[0000564f28a58c90] pulse audio output debug: underflow
[00007f15b8000c40] main input debug: Buffering 0%
[00007f15b8000c40] main input debug: Buffering 4%
[00007f15b8000c40] main input debug: Buffering 9%
[00007f15b8000c40] main input debug: Buffering 14%
[00007f15b8000c40] main input debug: Buffering 19%
[00007f15b8000c40] main input debug: Buffering 23%
[00007f15b8000c40] main input debug: Buffering 28%
[00007f15b8000c40] main input debug: Buffering 33%
@on-three
on-three / cocos2dx-build-notes-linuxmint-18.txt
Created December 22, 2018 19:46
build cocos2dx on linuxmint 18
cat /proc/version
Linux version 4.4.0-138-generic (buildd@lcy01-amd64-006) (gcc version 5.4.0 20160609 (Ubuntu 5.4.0-6ubuntu1~16.04.10) ) #164-Ubuntu SMP Tue Oct 2 17:16:02 UTC 2018
# typical install fails
git clone ....
cd to-the-repo
git submodule update --init
./download-deps.py
./build/install-deps-linux.sh
cd build
@on-three
on-three / 7.BANE.mp3.phonemes.txt
Created March 15, 2018 06:35
example phoneme file generated off .wav file (itself generated from text via Text to Speech)
SIL F UH Y UW K SIL
SIL 0.000 0.070 1.000000
F 0.080 0.190 1.000000
UH 0.200 0.240 1.000000
Y 0.250 0.390 1.000000
UW 0.400 0.680 1.000000
K 0.690 0.740 1.000000
SIL 0.750 0.830 1.000000
[#4] Niji no Conquistador - LOVE鮗コ 諱句袖 繧・o繧・ --no-config --no-fs --no-border --autofit=1280x720 │+dij
│ --geometry=1280x720+1600+0 --audio-display=no --vo=direct3d --terminal=yes --force-window=yes --af=drc=2:0.25 --softvol │+Dionysus
│ --user-agent=Mozilla/5.0 --cache=auto --cache-initial=1000 --cache-pause --network-timeout=1 │+donics
│ --script=C:\Users\Owner\AppData\Roaming\mpv\maws-assist.lua [01:29:55/01:29:57] (99%)
@on-three
on-three / gist:4d9d218311aa20ff2f8f
Created September 26, 2014 08:19
snapshot http stream with vlc via command line
cvlc http://URL --rat1 --video-filter=scene --vout=dummy --aout=dummy --scene-ratio=24 --scene-prefix=$PREFIX --scene-path=$SNAPSHOT_PATH --scene-width=$WIDTH --scene-replace vlc://quit
@on-three
on-three / gist:8eaa1db3e4d647fa2d35
Created August 21, 2015 04:59
vlc stream dektop
cvlc screen:// :screen-fps=30 :live-caching=300 :screen-top=100 :screen-left=100 :screen-width=1280 :screen-height=720 --sout '#transcode{vcodec=h264,acodec=mpga,ab=128,channels=2,samplerate=44100}:http{mux=ffmpeg{mux=flv},dst=:8085/}' :sout-keep