Skip to content

Instantly share code, notes, and snippets.

ffmpeg -f lavfi -i color=color=black:s=1920x1080 -vf "drawtext=fontfile=/Library/Fonts/Arial.ttf:fontsize=80:fontcolor=white:x=(w-text_w)/2:y=(h-text_h-line_h)/2:text='Lossless codecs vs corruption',drawtext=fontfile=/Library/Fonts/Arial.ttf:fontsize=30:fontcolor=white:x=(w-text_w)/2:y=(h-text_h-line_h)/2+80:text='by Dave Rice',fade=in:0:20,fade=out:55:20" -c:v rawvideo -pix_fmt uyvy422 -t 3 -vtag 2vuy intro_title.mov
ffmpeg -f lavfi -i color=color=black:s=1920x1080 -vf "drawtext=fontfile=/Library/Fonts/Arial.ttf:fontsize=100:fontcolor=white:x=(w-text_w)/2:y=(h-text_h-line_h)/2:text='JPEG-LS',fade=in:0:20,fade=out:55:20" -c:v rawvideo -pix_fmt uyvy422 -t 3 -vtag 2vuy jpegls_title.mov
ffmpeg -f lavfi -i mandelbrot=s=1920x1080 -c:v jpegls -bsf noise -t 10 jpegls.mov
ffmpeg -f lavfi -i color=color=black:s=1920x1080 -vf "drawtext=fontfile=/Library/Fonts/Arial.ttf:fontsize=100:fontcolor=white:x=(w-text_w)/2:y=(h-text_h-line_h)/2:text='Lossless JPEG',fade=in:0:20,fade=out:55:20" -c:v rawvideo -pix_fmt uyvy422 -t 3
@dericed
dericed / ffmpeg pixel formats
Created August 11, 2012 00:35
snapshot of pixel format list from ffmpeg, ffmpeg version 0.11.1.git built on Aug 8 2012 11:29:53
Pixel formats:
I.... = Supported Input format for conversion
.O... = Supported Output format for conversion
..H.. = Hardware accelerated format
...P. = Paletted format
....B = Bitstream format
FLAGS NAME NB_COMPONENTS BITS_PER_PIXEL
-----
IO... yuv420p 3 12
IO... yuyv422 3 16
#nttw4 talk, December 5, 2019, Dave Rice at #nttw4,
#video at https://twitter.com/nttwconf/status/1202509295973216257
Good morning,
During my first full-time archivist gig, I worked with a large audio collection
and, in adherence to the best practices of my community, would digitize audio
tapes to Broadcast Wave Files. I was a new archivist and working as the only
archivist in a media organization so I felt that relief from looking to the
best practices of our communities as a way of reducing my own decision-making
@dericed
dericed / padmovie
Created April 28, 2015 03:33
Bash script to use ffmpeg to pad an input with a color and silence at one or both ends.
#!/bin/bash
# suffix to use on the output file
suffix="_padded"
# color must be a value from http://ffmpeg.org/ffmpeg-utils.html#Color
color="black"
# seconds_at_start must be an integer
seconds_at_start=2
# seconds_at_end must be an integer
seconds_at_end=10
@dericed
dericed / sips-r.sh
Created September 10, 2015 16:45
recursive use of sips to create a directory of thumbnails from a directory of images
#!/bin/bash
if [[ ! "${#}" == 2 ]] ; then
echo "Please provide input and output directories, and no other arguments."
exit 1
fi
input="${1}"
output="${2}"
#!/bin/bash
_fix(){
FILE="${1}"
NAME="$(basename "${FILE}")"
SDTP_OFFSET="$(mediaconch -mt "${FILE}" | xmlstarlet sel -N mt="https://mediaarea.net/mediatrace" -t -m "mt:MediaTrace/mt:media/mt:block[@name='File header']/mt:block[@name='Track']/mt:block[@name='Media']/mt:block[@name='Media Information']/mt:block[@name='Sample Table']/mt:block[@name='Sample Dependency']/mt:block[@name='Header']/mt:data[@name='Name']" -v @offset)"
if [[ "${SDTP_OFFSET}" = "" ]] ; then
echo "${NAME} has no sample dependency table anyway, skipping"
else
echo "${NAME} has a sample dependency table at ${SDTP_OFFSET}"
<?xml version="1.0" encoding="utf-8"?>
<rss xmlns:atom="http://www.w3.org/2005/Atom" xmlns:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd" xmlns:content="http://purl.org/rss/1.0/modules/content/" version="2.0">
<channel>
<title>No Time to Wait 4</title>
<link>https://mediaarea.net/NoTimeToWait4</link>
<description>The fourth annual No Time to Wait conference shall take place December 5th and 6th, 2019 (with an optional workshop/codeday on December 4th) at the Vera and Donald Blinken Open Society Archives in downtown Budapest, Hungary. #nttw4</description>
<language>en</language>
<pubDate>Sat, 25 Jan 2019 12:00:00 -0500</pubDate>
<category>Technology</category>
<category>Education</category>
This file has been truncated, but you can view the full file.
790700ffffffffff675c1aaa4bf39496cc573c7c686f89c4aedd5c4f15686f2304a9e267586e747980c5a90a6132d277796b41b51e5f39837578ce01a868674b3a787f0d2fafd360de7d777d7d1fadc3
790701ffffffffff4755808c9460918f5f470eae92ac3c969db2cfbb4e8dad088b8ee551d30a97267b8b8e1b38a8b89a46cc8b92544faee297242c8a92cb60d44fb25a688d936153af42d16358929a1e
790702ffffffffff74723f9f9dba5f1332747252c4dced41c9d2726e659e9fcdbaaa447772f29fa6499799ce746a5aa0a74e949bd76f63df9495de909ab27069a89698fc8e934f67605f9899d78d92e7
79070350ce30c0d130548e8a97b48f903cffc1aa9f414e979abeccafd999e51a9292224ad801b762f59197714ab9973168ff999c945bc8820f66849596b5662db15670f59a9bd65dbc156073b5a1a402
7907045103cfa0ff6e71ae999972ffa54d716a539aa774b3abde655abb8f992392947f6f634393a30a8d912563415e95a49f8c946d62403e8d98758991756651fd929d10868c08550fc096a1c88a9103
79070552ffc9e7045b6af4a19981654db67175e341c0bc58342c77760926ae176154b77b79d83ab0ef50f2087d7c864ebf5654f3727979c4d7a05350d7447b7c2bc0a27c29ad72767878c8a7dc000000
79070653ffd2d3d350512e97a8108d8e52432599c75befa3a5e037cba7