未验证 提交 e1b6c60e 编写于 作者: M Mr.doob 提交者: GitHub

Merge pull request #14379 from ClinicalGraphics/fix/inverted-normals-camera-scale-negative

determine if normals are flipped by a reflection in the normalMatrix instead of object.matrixWorld
......@@ -676,7 +676,7 @@ function WebGLRenderer( parameters ) {
this.renderBufferDirect = function ( camera, fog, geometry, material, object, group ) {
var frontFaceCW = ( object.isMesh && object.matrixWorld.determinant() < 0 );
var frontFaceCW = ( object.isMesh && object.normalMatrix.determinant() < 0 );
state.setMaterial( material, frontFaceCW );
......@@ -1406,7 +1406,7 @@ function WebGLRenderer( parameters ) {
if ( object.isImmediateRenderObject ) {
var frontFaceCW = ( object.isMesh && object.matrixWorld.determinant() < 0 );
var frontFaceCW = ( object.isMesh && object.normalMatrix.determinant() < 0 );
state.setMaterial( material, frontFaceCW );
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册