Modify decode_packet interface

Return AVFrame* directly instead of bool and getting decoded
frame later.
Modify demuxer::flush API

Remove unecessary flush() calls
Implement more accurate seeking.

Seeking with avformat_seek_file(pts) doesn't seem to work
reliably. You cannot seek to the first frame, for example.

To fix this, I add index entries for the video keyframes and do
avformat_seek_file(AVSEEK_FLAG_BYTE) instead.