mirror of
https://github.com/RPCSX/rpcsx.git
synced 2026-04-04 14:08:37 +00:00
Reduce std::numeric_limits dependency
Please, stop pretending... You need these templates for generic code. In other words, in another templates. Stop increasing compilation time for no reason.
This commit is contained in:
parent
bc7acf9f7a
commit
6e05dcadb6
8 changed files with 18 additions and 19 deletions
|
|
@ -132,10 +132,10 @@ private:
|
|||
const s32 rem = calibData.sensNumer % calibData.sensDenom;
|
||||
const s32 output = (quot * biased) + ((rem * biased) / calibData.sensDenom);
|
||||
|
||||
if (output > std::numeric_limits<s16>::max())
|
||||
return std::numeric_limits<s16>::max();
|
||||
else if (output < std::numeric_limits<s16>::min())
|
||||
return std::numeric_limits<s16>::min();
|
||||
if (output > INT16_MAX)
|
||||
return INT16_MAX;
|
||||
else if (output < INT16_MIN)
|
||||
return INT16_MIN;
|
||||
else return static_cast<s16>(output);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue