From bdbfd6b08856a445446bfd845f1c43109d184250 Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Fri, 12 Jun 2015 13:47:35 +0100 Subject: Remove PassReason stuff. This feels wrong: it means that it is possible for FFmpegDecoder to discard packets. I can't see how this is ok in all cases: maybe we were lucky that it worked at all. --- src/lib/ffmpeg_decoder.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/lib/ffmpeg_decoder.cc') diff --git a/src/lib/ffmpeg_decoder.cc b/src/lib/ffmpeg_decoder.cc index 416ac0248..6f91922eb 100644 --- a/src/lib/ffmpeg_decoder.cc +++ b/src/lib/ffmpeg_decoder.cc @@ -137,7 +137,7 @@ FFmpegDecoder::flush () } bool -FFmpegDecoder::pass (PassReason reason) +FFmpegDecoder::pass () { int r = av_read_frame (_format_context, &_packet); @@ -160,11 +160,11 @@ FFmpegDecoder::pass (PassReason reason) int const si = _packet.stream_index; shared_ptr fc = _ffmpeg_content; - if (si == _video_stream && !_ignore_video && reason != PASS_REASON_SUBTITLE) { + if (si == _video_stream && !_ignore_video) { decode_video_packet (); } else if (fc->subtitle_stream() && fc->subtitle_stream()->uses_index (_format_context, si)) { decode_subtitle_packet (); - } else if (reason != PASS_REASON_SUBTITLE) { + } else { decode_audio_packet (); } -- cgit v1.2.3