Skip to content

Commit dc8c362

Browse files
committed
Editor: Scale down touchscreen zoom
1 parent 625d234 commit dc8c362

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

editor/js/EditorControls.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -364,7 +364,8 @@ class EditorControls extends THREE.EventDispatcher {
364364

365365
touches[ 0 ].set( event.pageX, event.pageY, 0 ).divideScalar( window.devicePixelRatio );
366366
touches[ 1 ].set( position.x, position.y, 0 ).divideScalar( window.devicePixelRatio );
367-
var distance = touches[ 0 ].distanceTo( touches[ 1 ] );
367+
// Divide by 10 to offset inherent over-sensitivity (https://github.com/mrdoob/three.js/issues/32442)
368+
var distance = touches[ 0 ].distanceTo( touches[ 1 ] ) / 10;
368369
scope.zoom( delta.set( 0, 0, prevDistance - distance ) );
369370
prevDistance = distance;
370371

0 commit comments

Comments
 (0)