Просмотр исходного кода

PixelationPassNode: Fix zero normal processing. (#32159)

Michael Herzog 5 месяцев назад
Родитель
Сommit
94f32836d0
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      examples/jsm/tsl/display/PixelationPassNode.js

+ 1 - 1
examples/jsm/tsl/display/PixelationPassNode.js

@@ -193,7 +193,7 @@ class PixelationNode extends TempNode {
 
 			const nei = property( 'float', 'nei' );
 
-			If( this.normalEdgeStrength.greaterThan( 0.0 ), () => {
+			If( this.normalEdgeStrength.greaterThan( 0.0 ).and( normal.length().greaterThan( 0 ) ), () => {
 
 				nei.assign( normalEdgeIndicator( depth, normal ) );
 

粤ICP备19079148号