how to rotate a model base on euler angle (pitch, yaw, roll)?

Started by jaychang0917, April 01, 2017, 11:38:22 AM

Previous topic - Next topic

jaychang0917

Is there any method that i can rotate a model by euler angles (pitch, yaw, roll)?
Thanks!

jaychang0917

I tried with the following code, it works.


model.clearRotation();
model.rotateX((float) Math.toRadians(pitch));
model.rotateY((float) Math.toRadians(yaw));
model.rotateZ((float) Math.toRadians(roll));

AeroShark333

I think pretty much everything in jpct works with radians rather than degrees... :P