2
0
Эх сурвалжийг харах

WebGPUObjects: Add runtime error when using THREE.Geometry.

Mugen87 4 жил өмнө
parent
commit
599eb63350

+ 6 - 0
examples/jsm/renderers/webgpu/WebGPUObjects.js

@@ -15,6 +15,12 @@ class WebGPUObjects {
 		const updateMap = this.updateMap;
 		const updateMap = this.updateMap;
 		const frame = this.info.render.frame;
 		const frame = this.info.render.frame;
 
 
+		if ( geometry.isGeometry ) {
+
+			throw 'THREE.WebGPURenderer: Geometries of type THREE.Geometry are not supported. Please use BufferGeometry.';
+
+		}
+
 		if ( updateMap.get( geometry ) !== frame ) {
 		if ( updateMap.get( geometry ) !== frame ) {
 
 
 			this.geometries.update( geometry );
 			this.geometries.update( geometry );