class FFmpegDecoder : public VideoDecoder, public AudioDecoder
{
public:
- FFmpegDecoder (boost::shared_ptr<Film>, DecodeOptions, Job *);
+ FFmpegDecoder (boost::shared_ptr<Film>, DecodeOptions);
~FFmpegDecoder ();
float frames_per_second () const;
bool seek (double);
bool seek_to_last ();
+ void seek_forward ();
+ void seek_back ();
private:
bool pass ();
- bool do_seek (double p, bool);
+ bool do_seek (double p, bool, bool);
PixelFormat pixel_format () const;
AVSampleFormat audio_sample_format () const;
int bytes_per_audio_sample () const;
- void out_with_sync ();
- void filter_and_emit_video (AVFrame *);
- double frame_time () const;
+ void filter_and_emit_video ();
void setup_general ();
void setup_video ();
void setup_audio ();
void setup_subtitle ();
+ void decode_audio_packet ();
+
void maybe_add_subtitle ();
- boost::shared_ptr<AudioBuffers> deinterleave_audio (uint8_t* data, int size);
+ boost::shared_ptr<AudioBuffers> deinterleave_audio (uint8_t** data, int size);
void film_changed (Film::Property);
AVPacket _packet;
- boost::optional<double> _first_video;
- boost::optional<double> _first_audio;
-
std::list<boost::shared_ptr<FilterGraph> > _filter_graphs;
boost::mutex _filter_graphs_mutex;
};