Merge pull request #1193 from RachelBryk/ir-input-display

Fix IR input display.
This commit is contained in:
skidau 2014-10-02 13:48:17 +10:00
commit 68edddf10e
1 changed files with 4 additions and 2 deletions

View File

@ -628,9 +628,11 @@ static void SetWiiInputDisplayString(int remoteID, u8* const data, const Wiimote
s_InputDisplay[controllerID].append(accel);
}
if (irData) // incomplete
if (irData)
{
std::string ir = StringFromFormat(" IR:%d,%d", ((u8*)irData)[0], ((u8*)irData)[1]);
u16 x = irData[0] | ((irData[2] >> 4 & 0x3) << 8);
u16 y = irData[1] | ((irData[2] >> 2 & 0x3) << 8);
std::string ir = StringFromFormat(" IR:%d,%d", x, y);
s_InputDisplay[controllerID].append(ir);
}