Skip to content

Commit 75279cd

Browse files
fix programvalue update for length 4 arrays (#517)
Fixed an issue where program values were not properly updated. The problem was in the Effect utils itself were simply the mapping was wrong.
2 parents a4a5a81 + 80a67d4 commit 75279cd

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/core/renderers/webgl/shaders/effects/EffectUtils.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,8 +66,8 @@ export const updateFloat32ArrayLength4 = (values: ShaderEffectValueMap) => {
6666
const floatArray = values.programValue;
6767
floatArray[0] = validatedValue[0]!;
6868
floatArray[1] = validatedValue[1]!;
69-
floatArray[2] = validatedValue[1]!;
70-
floatArray[3] = validatedValue[1]!;
69+
floatArray[2] = validatedValue[2]!;
70+
floatArray[3] = validatedValue[3]!;
7171
} else {
7272
values.programValue = new Float32Array(validatedValue);
7373
}

0 commit comments

Comments
 (0)