Skip to content

Commit

Permalink
wow: fix for WebGPU
Browse files Browse the repository at this point in the history
  • Loading branch information
will authored and magcius committed Oct 8, 2024
1 parent 110f251 commit 2a8fbb9
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/WorldOfWarcraft/program.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1002,20 +1002,20 @@ void calcBillboardMat(inout mat4 m) {
mat4 getBoneTransform(uint boneIndex) {
vec4 mx = texelFetch(TEXTURE(u_TextureBoneMatrix), ivec2(1, boneIndex), 0);
vec4 my = texelFetch(u_TextureBoneMatrix, ivec2(2, boneIndex), 0);
vec4 mz = texelFetch(u_TextureBoneMatrix, ivec2(3, boneIndex), 0);
vec4 my = texelFetch(TEXTURE(u_TextureBoneMatrix), ivec2(2, boneIndex), 0);
vec4 mz = texelFetch(TEXTURE(u_TextureBoneMatrix), ivec2(3, boneIndex), 0);
return transpose(mat4(mx, my, mz, vec4(0, 0, 0, 1)));
}
mat4 getPostBillboardTransform(uint boneIndex) {
vec4 mx = texelFetch(u_TextureBoneMatrix, ivec2(4, boneIndex), 0);
vec4 my = texelFetch(u_TextureBoneMatrix, ivec2(5, boneIndex), 0);
vec4 mz = texelFetch(u_TextureBoneMatrix, ivec2(6, boneIndex), 0);
vec4 mx = texelFetch(TEXTURE(u_TextureBoneMatrix), ivec2(4, boneIndex), 0);
vec4 my = texelFetch(TEXTURE(u_TextureBoneMatrix), ivec2(5, boneIndex), 0);
vec4 mz = texelFetch(TEXTURE(u_TextureBoneMatrix), ivec2(6, boneIndex), 0);
return transpose(mat4(mx, my, mz, vec4(0, 0, 0, 1)));
}
vec4 getBoneParams(uint boneIndex) {
return texelFetch(u_TextureBoneMatrix, ivec2(0, boneIndex), 0);
return texelFetch(TEXTURE(u_TextureBoneMatrix), ivec2(0, boneIndex), 0);
}
Mat4x3 getBoneMatrix(uint index) {
Expand Down

0 comments on commit 2a8fbb9

Please sign in to comment.