Views from Marco Island

Compressing video with ffmpeg

I was looking into what was taking up space in my Dropbox account and found some older videos, each a few gigabytes in size, where I didn’t really care if there was a small loss of quality to make them much smaller. I found some options with ffmpeg that worked pretty well

ffmpeg -i input_file -vcodec libx265 -crf 34 output_file

This will re-encode the file using x265. The “-crf” option specifies the amount of compression, with a range from 0-51: “0” being lossless and “23” the default. With the default I was able to halve the storage space required with negligible video loss. I upped it to “34”, as above, and while there was a bit of loss in video clarity, it didn’t matter for the video content. The result? A file originally ~ 2.4 GB in size was reduced to ~ 300 MB.

I had a folder of such videos, so used this Bash one-liner to process each file and output a new processed file.

for file in ./*.mp4; do ffmpeg -i ${file} -vcodec libx265 -crf 34 ${file%.*}_processed.mp4; done

${file%.*}_processed.mp4 means from the original file, keep the filename (removing the extension) and replaced it with “_processed.mp4”.

Main board, front panel, transistor matching – MFOS Soundlab mini synth mk II

The main board is coming along, this is before I placed the remaining capacitors and IC sockets.

Here I’m matching transistors with an ATmega328-based component tester.

And then the placing the potentiometers, sockets, and switches on the front panel

Errors while running Rust on Virtualbox

I got the following error when running “cargo run” on my “Roguelike” follo-along project (https://bfnightly.bracketproductions.com/rustbook)

Err` value: CreationErrors([NoAvailablePixelFormat, NoAvailablePixelFormat])'

I found the error was due to 3D acceleration being enabled on my Linux Mint 19-based development environment, running on Virtualbox 6.1.10. That is, make sure you have this in your vboxmanage line in your Vagrantfile:

vb.customize ["modifyvm", :id, "--accelerate3d", "off"] # Disable 3d acceleration until Virtualbox team fixes it

Remembering back as to why I had that line set to “on”, I think I was playing around with getting the Android emulator to work in Virtualbox, which as of 6.1 supports nested virtualization. I came close to getting that working, ultimately I don’t think it’s possible right now.