multimodalart HF Staff commited on
Commit
1de78c3
·
verified ·
1 Parent(s): 8fa262e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -359,7 +359,7 @@ class CameraControl3D(gr.HTML):
359
  const arcPoints = [];
360
  for (let i = 0; i <= 32; i++) {
361
  const angle = THREE.MathUtils.degToRad(-30 + (90 * i / 32));
362
- arcPoints.push(new THREE.Vector3(2.0, ELEVATION_RADIUS * Math.sin(angle) + CENTER.y, ELEVATION_RADIUS * Math.cos(angle)));
363
  }
364
  const arcCurve = new THREE.CatmullRomCurve3(arcPoints);
365
  const elevationArc = new THREE.Mesh(
@@ -400,7 +400,7 @@ class CameraControl3D(gr.HTML):
400
  cameraGroup.lookAt(CENTER);
401
 
402
  azimuthHandle.position.set(AZIMUTH_RADIUS * Math.sin(azRad), 0.05, AZIMUTH_RADIUS * Math.cos(azRad));
403
- elevationHandle.position.set(2.0, ELEVATION_RADIUS * Math.sin(elRad) + CENTER.y, ELEVATION_RADIUS * Math.cos(elRad));
404
 
405
  const orangeDist = distance + 0.5;
406
  distanceHandle.position.set(
@@ -473,7 +473,7 @@ class CameraControl3D(gr.HTML):
473
  if (azimuthAngle < 0) azimuthAngle += 360;
474
  }
475
  } else if (dragTarget.userData.type === 'elevation') {
476
- const plane = new THREE.Plane(new THREE.Vector3(1, 0, 0), 2.0);
477
  if (raycaster.ray.intersectPlane(plane, intersection)) {
478
  const relY = intersection.y - CENTER.y;
479
  const relZ = intersection.z;
 
359
  const arcPoints = [];
360
  for (let i = 0; i <= 32; i++) {
361
  const angle = THREE.MathUtils.degToRad(-30 + (90 * i / 32));
362
+ arcPoints.push(new THREE.Vector3(-0.8, ELEVATION_RADIUS * Math.sin(angle) + CENTER.y, ELEVATION_RADIUS * Math.cos(angle)));
363
  }
364
  const arcCurve = new THREE.CatmullRomCurve3(arcPoints);
365
  const elevationArc = new THREE.Mesh(
 
400
  cameraGroup.lookAt(CENTER);
401
 
402
  azimuthHandle.position.set(AZIMUTH_RADIUS * Math.sin(azRad), 0.05, AZIMUTH_RADIUS * Math.cos(azRad));
403
+ elevationHandle.position.set(-0.8, ELEVATION_RADIUS * Math.sin(elRad) + CENTER.y, ELEVATION_RADIUS * Math.cos(elRad));
404
 
405
  const orangeDist = distance + 0.5;
406
  distanceHandle.position.set(
 
473
  if (azimuthAngle < 0) azimuthAngle += 360;
474
  }
475
  } else if (dragTarget.userData.type === 'elevation') {
476
+ const plane = new THREE.Plane(new THREE.Vector3(1, 0, 0), -0.8);
477
  if (raycaster.ray.intersectPlane(plane, intersection)) {
478
  const relY = intersection.y - CENTER.y;
479
  const relZ = intersection.z;