Clean up difference comparison in representation.cc
Change-Id: Ibde83d1b8b2f644899f93790978d906dba5d4c14
This commit is contained in:
parent
1600909c4b
commit
f21d93dd65
|
@ -420,7 +420,7 @@ bool Representation::ApproximiatelyEqual(int64_t time1, int64_t time2) const {
|
||||||
std::min(frame_duration_,
|
std::min(frame_duration_,
|
||||||
static_cast<uint32_t>(kErrorThresholdSeconds *
|
static_cast<uint32_t>(kErrorThresholdSeconds *
|
||||||
media_info_.reference_time_scale()));
|
media_info_.reference_time_scale()));
|
||||||
return time1 <= time2 + error_threshold && time2 <= time1 + error_threshold;
|
return std::abs(time1 - time2) <= error_threshold;
|
||||||
}
|
}
|
||||||
|
|
||||||
int64_t Representation::AdjustDuration(int64_t duration) const {
|
int64_t Representation::AdjustDuration(int64_t duration) const {
|
||||||
|
|
Loading…
Reference in New Issue