diff options
author | wm4 <wm4@nowhere> | 2019-06-02 23:29:40 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2019-09-19 20:37:05 +0200 |
commit | 911718c413a80ee5e3bc30a9510b6aaaba35d2ad (patch) | |
tree | 1cb1b5675bd768d7046f970de7ce8d05e7bf75a3 /player/screenshot.h | |
parent | 1f13bd09427b2784a59168e6807b7c134c79addb (diff) | |
download | mpv-911718c413a80ee5e3bc30a9510b6aaaba35d2ad.tar.bz2 mpv-911718c413a80ee5e3bc30a9510b6aaaba35d2ad.tar.xz |
demux: use binary search for cache seek index
Not sure if this is bug-free. You _always_ make bugs when writing a
binary search from scratch (and such is the curse of C, though if I did
this in C++ it would probably end in blood). It seems to work though,
checking against the normal linear search.
It's slightly faster. Not much.
I wonder if the termination condition can be written in a nicer/elegant
way. I guess the fact that it's not a == predicate makes this slightly
messier?
Diffstat (limited to 'player/screenshot.h')
0 files changed, 0 insertions, 0 deletions