I love that media has moved from custom plugins (Flash…gross) to basic HTML
elements. Treating these media sources as just another element allows us to use CSS filters to adjust display, for example. The less we need to do with ffmpeg or plugins, the better.
I’ve been noticing that many video sites have implemented a feature to adjust video playback speed, which is awesome if you’re trying to get through some sports highlights faster or to see that monster slam dunk in super slow motion. I was hoping it didn’t require some special type of server to send the file in slower or faster chunks and I was right: all you need is the
const video = document.querySelector("video");
// Slow it to 50% speed
video.playbackRate = 0.5;
// Twice as fast!