The tutorial mentions that the call to `av_register_all()` is required, although it seems it's deprecated since ffmpeg 4.0. See the official [changelog](https://github.com/FFmpeg/FFmpeg/blob/70d25268c21cbee5f08304da95be1f647c630c15/doc/APIchanges#L86) and the commit diff of the removal of the call [from official code examples](http://ffmpeg.org/pipermail/ffmpeg-devel/2018-February/225051.html).