The (float) cast is not necessary, and makes it harder to read.

This commit is contained in:
hiker
2014-11-25 14:00:43 +11:00
parent 51be8195bc
commit 63e5acdf2b

View File

@@ -44,7 +44,7 @@ Wiimote::Wiimote(wiimote_t* wiimote_handle, int wiimote_id,
gamepad_config->setPlugged();
// Determine number of bits in the bit mask of all buttons.
int button_count = (int)( log((float)WIIMOTE_BUTTON_ALL) / log((float)2.0f))+1;
int button_count = (int)( log((float)WIIMOTE_BUTTON_ALL) / log(2.0f))+1;
m_gamepad_device = new GamePadDevice(getIrrId(),
gamepad_name.c_str(),