From 3ac7f3a80c187d0d6487bc1c8a8041795ca374f0 Mon Sep 17 00:00:00 2001 From: Garrett Johnson Date: Fri, 17 May 2024 10:59:07 +0900 Subject: [PATCH] Update EnvironmentControls.js --- src/three/controls/EnvironmentControls.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/three/controls/EnvironmentControls.js b/src/three/controls/EnvironmentControls.js index 00b4b7c87..ebc7d6872 100644 --- a/src/three/controls/EnvironmentControls.js +++ b/src/three/controls/EnvironmentControls.js @@ -308,9 +308,9 @@ export class EnvironmentControls extends EventDispatcher { pointerTracker.getStartCenterPoint( _startCenterPoint ); // adjust the drag requirement by the dpr - const dpr = window.devicePixelRatio; + const dragThreshold = 2.0 * window.devicePixelRatio; const parallelDelta = _centerPoint.distanceTo( _startCenterPoint ); - if ( Math.abs( separateDelta ) > dpr || parallelDelta > dpr ) { + if ( Math.abs( separateDelta ) > dragThreshold || parallelDelta > dragThreshold ) { if ( Math.abs( separateDelta ) > parallelDelta ) {