diff options
| author | Carl Hetherington <cth@carlh.net> | 2015-05-13 10:15:26 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2015-05-13 10:15:26 +0100 |
| commit | 9922c1f2eaea674ba2ff6cce5f5853655fd8ad7a (patch) | |
| tree | 9427c2cb655f8788c31bb5410d70451d11ae3665 /src/lib/subtitle_decoder.cc | |
| parent | 83e5567530d0be24490abdda46d196e4279c5030 (diff) | |
Don't bother decoding video frames when we're seeking around trying to find subtitles.
Diffstat (limited to 'src/lib/subtitle_decoder.cc')
| -rw-r--r-- | src/lib/subtitle_decoder.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/lib/subtitle_decoder.cc b/src/lib/subtitle_decoder.cc index ac9a67e33..edb291ab8 100644 --- a/src/lib/subtitle_decoder.cc +++ b/src/lib/subtitle_decoder.cc @@ -70,7 +70,7 @@ SubtitleDecoder::get (list<T> const & subs, list<ContentTimePeriod> const & sp, * (a) give us what we want, or * (b) hit the end of the decoder. */ - while (!pass() && (subs.empty() || (subs.back().period().to < sp.back().to))) {} + while (!pass(PASS_REASON_SUBTITLE) && (subs.empty() || (subs.back().period().to < sp.back().to))) {} /* Now look for what we wanted in the data we have collected */ /* XXX: inefficient */ @@ -82,6 +82,8 @@ SubtitleDecoder::get (list<T> const & subs, list<ContentTimePeriod> const & sp, } } + /* XXX: should clear out _decoded_* at some point */ + return out; } |
