瀏覽代碼

WebGLRenderer: Removed .setFaceCulling()

Mugen87 7 年之前
父節點
當前提交
0cf3714dd2

+ 0 - 2
docs/api/constants/Renderer.html

@@ -18,7 +18,6 @@
 		THREE.CullFaceFrontBack
 		</code>
 		<div>
-		These are used by the WebGLRenderer's [page:WebGLRenderer.setFaceCulling setFaceCulling] method.<br /><br />
 		[page:constant CullFaceNone] disables face culling.<br />
 		[page:constant CullFaceBack] culls back faces (default).<br />
 		[page:constant CullFaceFront] culls front faces.<br />
@@ -31,7 +30,6 @@
 		THREE.FrontFaceDirectionCCW
 		</code>
 		<div>
-		These are used by the WebGLRenderer's [page:WebGLRenderer.setFaceCulling setFaceCulling] method.<br /><br />
 		[page:constant FrontFaceDirectionCW] sets the winding order for polygons to clockwise.<br />
 		[page:constant FrontFaceDirectionCCW] sets the winding order for polygons to counter-clockwise (default).
 		</div>

+ 2 - 0
docs/api/deprecated/DeprecatedList.html

@@ -539,6 +539,8 @@
 
 			WebGLRenderer.updateShadowMap() has been removed.<br /><br />
 
+			WebGLRenderer.setFaceCulling() has been removed.<br /><br />
+
 			WebGLRenderer.setTexture is deprecated, use [page:WebGLRenderer.setTexture2D]() instead.<br /><br />
 
 			WebGLRenderer.shadowMapEnabled is now [page:WebGLRenderer.shadowMap.enabled].<br /><br />

+ 0 - 7
docs/api/renderers/WebGLRenderer.html

@@ -414,13 +414,6 @@
 		<h3>[method:null setClearColor]( [page:Color color], [page:Float alpha] )</h3>
 		<div>Sets the clear color and opacity.</div>
 
-		<h3>[method:null setFaceCulling]( [page:Renderer cullFace], [page:Renderer frontFace] )</h3>
-		<div>
-		See [page:Renderer WebGLRenderer constants] for all possible values for [page:Renderer cullFace] and [page:Renderer frontFace].<br />
-		Used for setting the gl.frontFace and gl.cullFace states in the GPU, thus enabling/disabling face culling when rendering.<br />
-		If cullFace is set to [page:Renderer CullFaceNone], culling will be disabled.<br />
-		</div>
-
 		<h3>[method:null setPixelRatio]( [page:number value] )</h3>
 		<div>Sets device pixel ratio. This is usually used for HiDPI device to prevent bluring output canvas.</div>
 

+ 0 - 4
editor/js/libs/tern-threejs/threejs.js

@@ -4821,10 +4821,6 @@
           "!type": "fn(camera, lights, fog, material, object)",
           "!doc": "Renders an immediate Object using a camera."
         },
-        "setFaceCulling": {
-          "!type": "fn(cullFace, frontFace)",
-          "!doc": "If cullFace is false, culling will be disabled."
-        },
         "setDepthTest": {
           "!type": "fn(depthTest: boolean)",
           "!doc": "This sets, based on depthTest, whether or not the depth data needs to be tested against the depth buffer."

+ 6 - 1
src/Three.Legacy.js

@@ -1333,7 +1333,12 @@ Object.assign( WebGLRenderer.prototype, {
 
 		console.warn( 'THREE.WebGLRenderer: .updateShadowMap() has been removed.' );
 
-	}
+	},
+	setFaceCulling: function () {
+
+		console.warn( 'THREE.WebGLRenderer: .setFaceCulling() has been removed.' );
+
+	},
 
 } );
 

+ 0 - 9
src/renderers/WebGLRenderer.js

@@ -2310,15 +2310,6 @@ function WebGLRenderer( parameters ) {
 
 	}
 
-	// GL state setting
-
-	this.setFaceCulling = function ( cullFace, frontFaceDirection ) {
-
-		state.setCullFace( cullFace );
-		state.setFlipSided( frontFaceDirection === FrontFaceDirectionCW );
-
-	};
-
 	// Textures
 
 	function allocTextureUnit() {