[WiiC] Wiic returns invalid IR coordinates!
Brought to you by:
gabriele82rm
|
From: Christian M. <chr...@sm...> - 2011-04-18 15:07:44
|
Hi again, I found the error and I tried to fix it with the following one: So do at line 410 in wiicpp.cpp for(index = 0; index < 4; index++) instead of for(index = 0; index < mpWiimotePtr->ir.num_dots; index++) since in case if the dot at [2] is not visible any more, the number of ir.num_dots=3. So it ll iterate [0],[1],[2]. but it will not iterate to [3] which is a valid point!!! and [2] will be an invalid point like (0,1023) So iterate over the whole vector of size 4! then with isVisble() function such points like (0,1023) are filtered out and you get all correct points I dont know whether this is the correct solution but it has worked in my case. Cheers Christian |