changes to work with ffmpeg 2.1