By Balvana
on Tue, 09/11/2012 - 11:41
hey, can someone please explain to me how the SampleUtils::setRotationMatrix() Method works?I would like to rotate my 3D Modell with touch eventse.g.: If you move your finger to the left/right/up/down the model should rotate in that direction as long as the finger touches the screenwell i kind of found out how to handle touches and I also get the coordinates of the touch but I can't figure out how to properly use them with SampleUtils::setRotationMatrix()
can I use the SampleUtils::setRotationMatrix() Method to rotate my 3D Model around 2 Axes at the same time?I'm a bit confused about that ^^;I would be very grateful for any suggestions :3-best regards
How does SampleUtils::setRotationMatrix() work?
Take a look at the Dominoes sample for an example of how to handle touch events, project them onto the target, and to apply rotations to your models.
How does SampleUtils::setRotationMatrix() work?
Thanks, that really helped me a lot :3
I'm now able to read out the touch events and can adjust the angle of the cube accordingly for x and y axis.