/*
- * Sixth 3D engine. Author: Svjatoslav Agejenko.
+ * Sixth 3D engine. Author: Svjatoslav Agejenko.
* This project is released under Creative Commons Zero (CC0) license.
*/
package eu.svjatoslav.sixth.e3d.gui;
import eu.svjatoslav.sixth.e3d.geometry.Point3D;
+import eu.svjatoslav.sixth.e3d.math.TransformsStack;
import eu.svjatoslav.sixth.e3d.math.Vertex;
-import eu.svjatoslav.sixth.e3d.math.TransformsPipeline;
+
+/**
+ * Tracks the position of the user in the 3D space.
+ * <p>
+ * It can be used to determine the angle between the user and the object.
+ * Also, it can be used to determine the distance between the user and the object.
+ */
public class UserRelativityTracker {
}
- public void analyze(final TransformsPipeline transformPipe,
+ public void analyze(final TransformsStack transformPipe,
final RenderingContext renderingContext) {
- center.transform(transformPipe, renderingContext);
+ center.calculateLocationRelativeToViewer(transformPipe, renderingContext);
if (right != null) {
- right.transform(transformPipe, renderingContext);
- down.transform(transformPipe, renderingContext);
+ right.calculateLocationRelativeToViewer(transformPipe, renderingContext);
+ down.calculateLocationRelativeToViewer(transformPipe, renderingContext);
}
}