projects
/
sixth-3d.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Improved code readability
[sixth-3d.git]
/
src
/
main
/
java
/
eu
/
svjatoslav
/
sixth
/
e3d
/
math
/
Orientation.java
diff --git
a/src/main/java/eu/svjatoslav/sixth/e3d/math/Orientation.java
b/src/main/java/eu/svjatoslav/sixth/e3d/math/Orientation.java
index
714b781
..
86db200
100644
(file)
--- a/
src/main/java/eu/svjatoslav/sixth/e3d/math/Orientation.java
+++ b/
src/main/java/eu/svjatoslav/sixth/e3d/math/Orientation.java
@@
-8,9
+8,17
@@
import eu.svjatoslav.sixth.e3d.geometry.Point3D;
public class Orientation implements Cloneable {
public class Orientation implements Cloneable {
+
private double s1, c1, s2, c2;
private double s1, c1, s2, c2;
+ /**
+ * The angle of rotation around the XZ axis.
+ */
private double angleXZ = 0;
private double angleXZ = 0;
+
+ /**
+ * The angle of rotation around the YZ axis.
+ */
private double angleYZ = 0;
public Orientation() {
private double angleYZ = 0;
public Orientation() {
@@
-28,6
+36,9
@@
public class Orientation implements Cloneable {
return new Orientation(angleXZ, angleYZ);
}
return new Orientation(angleXZ, angleYZ);
}
+ /**
+ * Computes the sine and cosine of the angles.
+ */
private void computeMultipliers() {
s1 = Math.sin(angleXZ);
c1 = Math.cos(angleXZ);
private void computeMultipliers() {
s1 = Math.sin(angleXZ);
c1 = Math.cos(angleXZ);