I’m trying to write a CAD-Software with JME for he Company i’m working at.
The complete geometric data is stored outside of JME in an database. JME ist only used to visualize the current state of the database. Every geometrical object has identifiers to store the orientation of the objects e.g.
angleX=90; angleY=0; angleZ=90;
when i want to rotate an object i just add something to the angles, e.g. angleX = angleX+5.
Then i create the graphics with jme and use node.rotate((float)Math.toRadians(box.angleX),(float)Math.toRadians(box.angleY),(float)Math.toRadians(box.angleZ));
for the rotation. The problem is that the result isn’t always what i expected.
E.g. when Z is 0 or 180, then everything works fine. But when Z is 90 or 270 then every change oft the x or y value results in a rotation of the object around the y-axis.
I would expect that the rotation axes always stay the same, but they are changing depending on the values the different axes have. Can please sombody explain to me what is going wrong here?