Skip to content

Commit 0bfee15

Browse files
mvaligurskyMartin Valigursky
andauthored
[Fix] Fix shader passes order (#7598)
Co-authored-by: Martin Valigursky <[email protected]>
1 parent 040f005 commit 0bfee15

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/scene/constants.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -771,12 +771,12 @@ export const SHADER_FORWARD = 0;
771771

772772
export const SHADER_PREPASS = 1;
773773

774+
// shadow pass used by the shadow rendering code
775+
export const SHADER_SHADOW = 2;
776+
774777
// shader pass used by the Picker class to render mesh ID
775778
export const SHADER_PICK = 3;
776779

777-
// shadow pass used by the shadow rendering code
778-
export const SHADER_SHADOW = 4;
779-
780780
/**
781781
* Shader that performs forward rendering.
782782
*

src/scene/shader-pass.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,8 +100,8 @@ class ShaderPass {
100100
// add default passes in the required order, to match the constants
101101
add('forward', SHADER_FORWARD, { isForward: true });
102102
add('prepass', SHADER_PREPASS);
103-
add('pick', SHADER_PICK);
104103
add('shadow', SHADER_SHADOW);
104+
add('pick', SHADER_PICK);
105105
}
106106

107107
/**

0 commit comments

Comments
 (0)