mirror of
https://github.com/overte-org/overte.git
synced 2025-08-04 01:43:27 +02:00
Comparaison operators for seq nums
This commit is contained in:
parent
2b29f5c130
commit
d6487dcb81
1 changed files with 4 additions and 4 deletions
|
@ -96,19 +96,19 @@ private:
|
|||
|
||||
|
||||
inline bool operator<(const SeqNum& a, const SeqNum& b) {
|
||||
|
||||
return (glm::abs(a._value - b._value) < SeqNum::THRESHOLD) ? a._value < b._value : b._value < a._value;
|
||||
}
|
||||
|
||||
inline bool operator>(const SeqNum& a, const SeqNum& b) {
|
||||
|
||||
return (glm::abs(a._value - b._value) < SeqNum::THRESHOLD) ? a._value > b._value : b._value > a._value;
|
||||
}
|
||||
|
||||
inline bool operator<=(const SeqNum& a, const SeqNum& b) {
|
||||
|
||||
return (glm::abs(a._value - b._value) < SeqNum::THRESHOLD) ? a._value <= b._value : b._value <= a._value;
|
||||
}
|
||||
|
||||
inline bool operator>=(const SeqNum& a, const SeqNum& b) {
|
||||
|
||||
return (glm::abs(a._value - b._value) < SeqNum::THRESHOLD) ? a._value >= b._value : b._value >= a._value;
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue