tomato is a python script to glitch AVI files
- utilities inspired by Way Spurr-Chen's moshy.
- functionality based off of Tomasz Sulej's research on AVI file structure.
It was designed to operate video frame ordering, substraction and duplication.
Modes called through -mode [mode]
void
- does nothingrandom
- randomizes frame orderreverse
- reverse frame orderinvert
- switches each consecutive frame witch each otherbloom
- duplicatesc
times p-frame numbern
pulse
- duplicates groups ofc
p-frames everyn
framesoverlapped
- copy group ofc
frames taken from everyn
th positionjiggle
- take frame from around current position.n
parameter is spread size [broken]
Other parameters :
-c and -n
- reserved for the modes-ff [0 or 1]
- ignore first frame (default 1)-a [0 or 1]
- activate audio (default 0)-k [0 to 1]
- kill frames with too much data (default 0.7)
python tomato.py -i input.avi
Takes out iframes
python tomato.py -i input.avi -m bloom -c 50 -n 100
Duplicate 50 times the 100th frame
python tomato.py -i input.avi -m pulse -c 5 -n 10
Duplicates 5 times a frame every 10 frame
python tomato.py -i input.avi -m random
Shuffles all of the frames in the video
python tomato.py -i input.avi -m overlapped -c 4 -n 2
Copy 4 frames taken starting from every 2nd frame. [1 2 3 4 3 4 5 6 5 6 7 8 7 8...]
I made tomato because I wanted to be able to glitch avi files regardless of the contained codec, the resolution and the file size while still being super duper fast and not needing to encode anything.
It reorders the frames inside the movi tag of your AVI file.
Libraries used : numpy, argparse, os, re, random, struct, itertools
I recommend preparing your AVI files with ffmpeg and the codec library of your choice. To read your glitched files I recommend VLC or Xine if you're under Linux. Both are great for visualizing content (especially xine for the random mode) but keep in mind you should always be experimenting and using different visualizers or tools to bake your files.
If you have any questions or ideas feel free to send me an email at kaspar.ravel@gmail.com
For more info on development : https://www.kaspar.wtf/blog/tomato-v2-0-avi-breaker