Skip to content

Commit

Permalink
Shader only remove shader to material mainPass.
Browse files Browse the repository at this point in the history
  • Loading branch information
clementlandrin committed Nov 18, 2024
1 parent c5c5ddb commit ba450b2
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions hrt/prefab/Shader.hx
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,7 @@ class Shader extends Prefab {
}

function removeShader( obj : h3d.scene.Object, material : h3d.mat.Material, shader : hxsl.Shader ) {
for ( p in material.getPasses() )
p.removeShader(shader);
material.mainPass.removeShader(shader);
}

function checkMaterial(mat: h3d.mat.Material) {
Expand Down

0 comments on commit ba450b2

Please sign in to comment.