public Point projectScreen(Vector23f p) { Ray3f eye2P = new Ray3f(eye, p); Vector23f proj = eye2P.intersect(viewPlane); proj.x -= (eye.x - width / 2); proj.y -= (eye.y - height / 2); return new Point((int) proj.x, (int) proj.y); }
public void moveEye(float deltaX, float deltaY, float deltaZ) { eye.x -= deltaX; eye.y -= deltaY; if (eye.z - deltaZ > 0) { eye.z -= deltaZ; } findViewPlane(); }
public void moveEyeTo(float x, float y) { eye.x = x; eye.y = y; }