Added ifdef to keep backward compatibility with the FFmpeg library.