|
@@ -3,7 +3,7 @@
|
|
* @author mrdoob / http://mrdoob.com/
|
|
* @author mrdoob / http://mrdoob.com/
|
|
*/
|
|
*/
|
|
|
|
|
|
-import { FrontSide, BackSide, DoubleSide, RGBAFormat, NearestFilter, PCFShadowMap, RGBADepthPacking } from '../../constants.js';
|
|
|
|
|
|
+import { FrontSide, BackSide, DoubleSide, RGBAFormat, NearestFilter, PCFShadowMap, RGBADepthPacking, NoBlending } from '../../constants.js';
|
|
import { WebGLRenderTarget } from '../WebGLRenderTarget.js';
|
|
import { WebGLRenderTarget } from '../WebGLRenderTarget.js';
|
|
import { MeshDepthMaterial } from '../../materials/MeshDepthMaterial.js';
|
|
import { MeshDepthMaterial } from '../../materials/MeshDepthMaterial.js';
|
|
import { MeshDistanceMaterial } from '../../materials/MeshDistanceMaterial.js';
|
|
import { MeshDistanceMaterial } from '../../materials/MeshDistanceMaterial.js';
|
|
@@ -100,12 +100,10 @@ function WebGLShadowMap( _renderer, _objects, maxTextureSize ) {
|
|
|
|
|
|
if ( lights.length === 0 ) return;
|
|
if ( lights.length === 0 ) return;
|
|
|
|
|
|
- // TODO Clean up (needed in case of contextlost)
|
|
|
|
- var _gl = _renderer.context;
|
|
|
|
var _state = _renderer.state;
|
|
var _state = _renderer.state;
|
|
|
|
|
|
// Set GL state for depth map.
|
|
// Set GL state for depth map.
|
|
- _state.disable( _gl.BLEND );
|
|
|
|
|
|
+ _state.setBlending( NoBlending );
|
|
_state.buffers.color.setClear( 1, 1, 1, 1 );
|
|
_state.buffers.color.setClear( 1, 1, 1, 1 );
|
|
_state.buffers.depth.setTest( true );
|
|
_state.buffers.depth.setTest( true );
|
|
_state.setScissorTest( false );
|
|
_state.setScissorTest( false );
|