Skip to content

Commit

Permalink
Material: Fix .needsUpdate + .alphaHash
Browse files Browse the repository at this point in the history
  • Loading branch information
donmccurdy committed Oct 4, 2023
1 parent a238892 commit f571a17
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions docs/scenes/material-browser.html
Original file line number Diff line number Diff line change
Expand Up @@ -352,6 +352,7 @@
// folder.add( material, 'polygonOffsetFactor' );
// folder.add( material, 'polygonOffsetUnits' );
folder.add( material, 'alphaTest', 0, 1 ).step( 0.01 ).onChange( needsUpdate( material, geometry ) );
folder.add( material, 'alphaHash' ).onChange( needsUpdate( material, geometry ) );
folder.add( material, 'visible' );
folder.add( material, 'side', constants.side ).onChange( needsUpdate( material, geometry ) );

Expand Down
2 changes: 2 additions & 0 deletions src/renderers/webgl/WebGLPrograms.js
Original file line number Diff line number Diff line change
Expand Up @@ -500,6 +500,8 @@ function WebGLPrograms( renderer, cubemaps, cubeuvmaps, extensions, capabilities
_programLayers.enable( 16 );
if ( parameters.anisotropy )
_programLayers.enable( 17 );
if ( parameters.alphaHash )
_programLayers.enable( 18 );

array.push( _programLayers.mask );
_programLayers.disableAll();
Expand Down

0 comments on commit f571a17

Please sign in to comment.