Skip to content

Commit

Permalink
setting the zoom depth correctly
Browse files Browse the repository at this point in the history
  • Loading branch information
Kevin Harrington committed May 24, 2024
1 parent 19323bd commit 5850658
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -913,7 +913,7 @@ private void buildCamera() {
hand = new Group(cylinder.getMesh());

camera.setNearClip(.1);
camera.setFarClip(1000.0);
//camera.setFarClip(1000.0);//this is set in VirtualCameraMobileBase
getSubScene().setCamera(camera);

camera.setRotationAxis(Rotate.Z_AXIS);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -120,8 +120,8 @@ public void setZoomDepth(double zoomDepth) {
if (zoomDepth < -9000)
zoomDepth = -9000;
this.zoomDepth = zoomDepth;
if(zoomDepth>5000)
camera.setFarClip(zoomDepth*2);
if(zoomDepth<-5000)
camera.setFarClip(-zoomDepth*2);
else
camera.setFarClip(10000);
zoomAffine.setTz(getZoomDepth());
Expand Down

0 comments on commit 5850658

Please sign in to comment.