2
0
Mr.doob 2 жил өмнө
parent
commit
4b78b07fe8

+ 1 - 63
build/three.cjs

@@ -26117,9 +26117,6 @@ class WebXRManager extends EventDispatcher {
 		const controllers = [];
 		const controllerInputSources = [];
 
-		const planes = new Set();
-		const planesLastChangedTimes = new Map();
-
 		//
 
 		let userCamera = null;
@@ -26728,12 +26725,6 @@ class WebXRManager extends EventDispatcher {
 
 		};
 
-		this.getPlanes = function () {
-
-			return planes;
-
-		};
-
 		// Animation Loop
 
 		let onAnimationFrameCallback = null;
@@ -26847,60 +26838,7 @@ class WebXRManager extends EventDispatcher {
 
 			if ( frame.detectedPlanes ) {
 
-				scope.dispatchEvent( { type: 'planesdetected', data: frame.detectedPlanes } );
-
-				let planesToRemove = null;
-
-				for ( const plane of planes ) {
-
-					if ( ! frame.detectedPlanes.has( plane ) ) {
-
-						if ( planesToRemove === null ) {
-
-							planesToRemove = [];
-
-						}
-
-						planesToRemove.push( plane );
-
-					}
-
-				}
-
-				if ( planesToRemove !== null ) {
-
-					for ( const plane of planesToRemove ) {
-
-						planes.delete( plane );
-						planesLastChangedTimes.delete( plane );
-						scope.dispatchEvent( { type: 'planeremoved', data: plane } );
-
-					}
-
-				}
-
-				for ( const plane of frame.detectedPlanes ) {
-
-					if ( ! planes.has( plane ) ) {
-
-						planes.add( plane );
-						planesLastChangedTimes.set( plane, frame.lastChangedTime );
-						scope.dispatchEvent( { type: 'planeadded', data: plane } );
-
-					} else {
-
-						const lastKnownTime = planesLastChangedTimes.get( plane );
-
-						if ( plane.lastChangedTime > lastKnownTime ) {
-
-							planesLastChangedTimes.set( plane, plane.lastChangedTime );
-							scope.dispatchEvent( { type: 'planechanged', data: plane } );
-
-						}
-
-					}
-
-				}
+				scope.dispatchEvent( { type: 'planesdetected', data: frame } );
 
 			}
 

+ 1 - 63
build/three.js

@@ -26122,9 +26122,6 @@ console.warn( 'Scripts "build/three.js" and "build/three.min.js" are deprecated
 			const controllers = [];
 			const controllerInputSources = [];
 
-			const planes = new Set();
-			const planesLastChangedTimes = new Map();
-
 			//
 
 			let userCamera = null;
@@ -26733,12 +26730,6 @@ console.warn( 'Scripts "build/three.js" and "build/three.min.js" are deprecated
 
 			};
 
-			this.getPlanes = function () {
-
-				return planes;
-
-			};
-
 			// Animation Loop
 
 			let onAnimationFrameCallback = null;
@@ -26852,60 +26843,7 @@ console.warn( 'Scripts "build/three.js" and "build/three.min.js" are deprecated
 
 				if ( frame.detectedPlanes ) {
 
-					scope.dispatchEvent( { type: 'planesdetected', data: frame.detectedPlanes } );
-
-					let planesToRemove = null;
-
-					for ( const plane of planes ) {
-
-						if ( ! frame.detectedPlanes.has( plane ) ) {
-
-							if ( planesToRemove === null ) {
-
-								planesToRemove = [];
-
-							}
-
-							planesToRemove.push( plane );
-
-						}
-
-					}
-
-					if ( planesToRemove !== null ) {
-
-						for ( const plane of planesToRemove ) {
-
-							planes.delete( plane );
-							planesLastChangedTimes.delete( plane );
-							scope.dispatchEvent( { type: 'planeremoved', data: plane } );
-
-						}
-
-					}
-
-					for ( const plane of frame.detectedPlanes ) {
-
-						if ( ! planes.has( plane ) ) {
-
-							planes.add( plane );
-							planesLastChangedTimes.set( plane, frame.lastChangedTime );
-							scope.dispatchEvent( { type: 'planeadded', data: plane } );
-
-						} else {
-
-							const lastKnownTime = planesLastChangedTimes.get( plane );
-
-							if ( plane.lastChangedTime > lastKnownTime ) {
-
-								planesLastChangedTimes.set( plane, plane.lastChangedTime );
-								scope.dispatchEvent( { type: 'planechanged', data: plane } );
-
-							}
-
-						}
-
-					}
+					scope.dispatchEvent( { type: 'planesdetected', data: frame } );
 
 				}
 

+ 1 - 63
build/three.module.js

@@ -26115,9 +26115,6 @@ class WebXRManager extends EventDispatcher {
 		const controllers = [];
 		const controllerInputSources = [];
 
-		const planes = new Set();
-		const planesLastChangedTimes = new Map();
-
 		//
 
 		let userCamera = null;
@@ -26726,12 +26723,6 @@ class WebXRManager extends EventDispatcher {
 
 		};
 
-		this.getPlanes = function () {
-
-			return planes;
-
-		};
-
 		// Animation Loop
 
 		let onAnimationFrameCallback = null;
@@ -26845,60 +26836,7 @@ class WebXRManager extends EventDispatcher {
 
 			if ( frame.detectedPlanes ) {
 
-				scope.dispatchEvent( { type: 'planesdetected', data: frame.detectedPlanes } );
-
-				let planesToRemove = null;
-
-				for ( const plane of planes ) {
-
-					if ( ! frame.detectedPlanes.has( plane ) ) {
-
-						if ( planesToRemove === null ) {
-
-							planesToRemove = [];
-
-						}
-
-						planesToRemove.push( plane );
-
-					}
-
-				}
-
-				if ( planesToRemove !== null ) {
-
-					for ( const plane of planesToRemove ) {
-
-						planes.delete( plane );
-						planesLastChangedTimes.delete( plane );
-						scope.dispatchEvent( { type: 'planeremoved', data: plane } );
-
-					}
-
-				}
-
-				for ( const plane of frame.detectedPlanes ) {
-
-					if ( ! planes.has( plane ) ) {
-
-						planes.add( plane );
-						planesLastChangedTimes.set( plane, frame.lastChangedTime );
-						scope.dispatchEvent( { type: 'planeadded', data: plane } );
-
-					} else {
-
-						const lastKnownTime = planesLastChangedTimes.get( plane );
-
-						if ( plane.lastChangedTime > lastKnownTime ) {
-
-							planesLastChangedTimes.set( plane, plane.lastChangedTime );
-							scope.dispatchEvent( { type: 'planechanged', data: plane } );
-
-						}
-
-					}
-
-				}
+				scope.dispatchEvent( { type: 'planesdetected', data: frame } );
 
 			}
 

Файлын зөрүү хэтэрхий том тул дарагдсан байна
+ 0 - 0
build/three.module.min.js


Энэ ялгаанд хэт олон файл өөрчлөгдсөн тул зарим файлыг харуулаагүй болно