explicit float postfix added to some numbers in order to get visual studio to shut up

This commit is contained in:
freem
2014-07-26 16:06:18 -05:00
parent 3239e4698d
commit ec66fc21bb
+19 -19
View File
@@ -1541,36 +1541,36 @@ float Profile::CalculateCaloriesFromHeartRate(float HeartRate, float Duration)
// Names for the constants in the equations. // Names for the constants in the equations.
// Assumes male and unknown voomax. // Assumes male and unknown voomax.
float gender_factor= -55.0969; float gender_factor= -55.0969f;
float heart_factor= 0.6309; float heart_factor= 0.6309f;
float voo_factor= 0; float voo_factor= 0.0f;
float weight_factor= 0.1988; float weight_factor= 0.1988f;
float age_factor= 0.2017; float age_factor= 0.2017f;
if(m_Voomax > 0) if(m_Voomax > 0)
{ {
if(m_IsMale) if(m_IsMale)
{ {
gender_factor= -95.7735; gender_factor= -95.7735f;
heart_factor= 0.634; heart_factor= 0.634f;
voo_factor= 0.404; voo_factor= 0.404f;
weight_factor= 0.394; weight_factor= 0.394f;
age_factor= 0.271; age_factor= 0.271f;
} }
else else
{ {
gender_factor= -59.3954; gender_factor= -59.3954f;
heart_factor= 0.45; heart_factor= 0.45f;
voo_factor= 0.380; voo_factor= 0.380f;
weight_factor= 0.103; weight_factor= 0.103f;
age_factor= 0.274; age_factor= 0.274f;
} }
} }
else if(!m_IsMale) else if(!m_IsMale)
{ {
gender_factor= -20.4022; gender_factor= -20.4022f;
heart_factor= 0.6309; heart_factor= 0.6309f;
weight_factor= 0.1988; weight_factor= 0.1988f;
age_factor= 0.2017; age_factor= 0.2017f;
} }
return ((gender_factor + (heart_factor * HeartRate) + return ((gender_factor + (heart_factor * HeartRate) +
(voo_factor * m_Voomax) + (weight_factor * kilos) + (age_factor + age)) (voo_factor * m_Voomax) + (weight_factor * kilos) + (age_factor + age))