提交 fb14834c 编写于 作者: M Mr.doob

Revert "WebGLRenderer: Moved layer test to renderObject. See #11083."

This reverts commit 8c72ccc7.
上级 c732e5da
......@@ -1304,6 +1304,10 @@ function WebGLRenderer( parameters ) {
if ( ! object.visible ) return;
var visible = object.layers.test( camera.layers );
if ( visible ) {
if ( object.isLight ) {
lights.push( object );
......@@ -1378,6 +1382,8 @@ function WebGLRenderer( parameters ) {
}
}
var children = object.children;
for ( var i = 0, l = children.length; i < l; i ++ ) {
......@@ -1438,8 +1444,6 @@ function WebGLRenderer( parameters ) {
function renderObject( object, scene, camera, geometry, material, group ) {
if ( object.layers.test( camera.layers ) === false ) return;
object.modelViewMatrix.multiplyMatrices( camera.matrixWorldInverse, object.matrixWorld );
object.normalMatrix.getNormalMatrix( object.modelViewMatrix );
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册