ffmpeg_player: add <stdexcept> include to fix building with g++-4.7
ffmpeg_player: use av_frame_alloc if available

The avcodec_alloc_frame method has been deprecated in the libav
master branch in favour of the new av_frame_alloc method. To avoid
the deprecation, and to support ffmpeg and 9.x versions of libav,
the choice of avcodec_alloc_frame vs av_frame_alloc is placed
in a configure check.