72 hi = ts_hi * tb_hi.
num * tb_lo.
den;
73 lo = ts_lo * tb_lo.
num * tb_hi.
den;
104 int keyframes_to_find,
114 int terminated_count = 0;
126 if (sp->
pos_hi == INT64_MAX) {
129 sp->
ts_hi = INT64_MAX;
130 sp->
pos_hi = INT64_MAX - 1;
195 if (sp->
pos_hi == INT64_MAX) {
198 sp->
ts_hi = INT64_MAX;
199 sp->
pos_hi = INT64_MAX - 1;
201 if (terminated_count == keyframes_to_find)
209 if (sp->
pos_lo == INT64_MAX) {
214 }
else if (sp->
ts_lo < ts) {
222 if (sp->
pos_hi == INT64_MAX) {
227 if (*found_hi >= keyframes_to_find && first_iter) {
233 }
else if (sp->
ts_hi > ts) {
257 int keyframes_to_find = 0;
260 int found_lo = 0, found_hi = 0;
271 if (stream_index >= 0) {
293 sp->
ts_lo = INT64_MAX;
295 sp->
ts_hi = INT64_MAX;
308 if (!keyframes_to_find) {
317 curpos =
FFMAX(pos - step / 2, 0);
325 &found_lo, &found_hi,
327 if (found_lo == keyframes_to_find && found_hi == keyframes_to_find)
362 min_distance = INT64_MAX;
364 if (sp->
pos_lo != INT64_MAX
371 if (sp->
pos_hi != INT64_MAX
376 if (distance < min_distance) {
381 if (min_distance == INT64_MAX) {