diff options
author | wm4 <wm4@nowhere> | 2017-11-10 12:11:33 +0100 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2017-11-10 12:11:33 +0100 |
commit | 2485b899c303f60a837baaaf704a3c8eb631ed9b (patch) | |
tree | 98104eecabd2d30d63daad6df1072a092b56bc6f /demux/codec_tags.h | |
parent | 968a24772e649e6f19b4e924c2e25f08de1e7875 (diff) | |
download | mpv-2485b899c303f60a837baaaf704a3c8eb631ed9b.tar.bz2 mpv-2485b899c303f60a837baaaf704a3c8eb631ed9b.tar.xz |
demux: avoid wasting time by stopping packet search as early as possible
The packet queue is sorted, so we can stop the search if we have found a
packet, and the next packet in the queue has a higher PTS than the seek
PTS (for the sake of SEEK_FORWARD, we still consider the first packet
with a higher PTS).
Also, as a mostly cosmetic change, but which might be "faster", check
target for NULL, instead of target_diff for a magic float value.
Diffstat (limited to 'demux/codec_tags.h')
0 files changed, 0 insertions, 0 deletions