Type correction.
This commit is contained in:
parent
d72bfeb539
commit
8c0f05c04b
|
@ -78,12 +78,12 @@ int CRSSIInterpolator::interpolate(uint16_t val) const
|
||||||
if (it == m_map.begin())
|
if (it == m_map.begin())
|
||||||
return it->second;
|
return it->second;
|
||||||
|
|
||||||
unsigned int x2 = it->first;
|
uint16_t x2 = it->first;
|
||||||
int y2 = it->second;
|
int y2 = it->second;
|
||||||
|
|
||||||
--it;
|
--it;
|
||||||
unsigned int x1 = it->first;
|
uint16_t x1 = it->first;
|
||||||
int y1 = it->second;
|
int y1 = it->second;
|
||||||
|
|
||||||
float p = float(val - x1) / float(x2 - x1);
|
float p = float(val - x1) / float(x2 - x1);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue