magcius / noclip.website

A digital museum of video game levels
https://noclip.website/
Other
3.27k stars 259 forks source link

WOTLK terrain sometimes weirdly checkerboxed #654

Open wgreenberg opened 7 months ago

wgreenberg commented 7 months ago

For example, here on Strand of the Ancients: image

This might be a texture decoding issue, or maybe the heightmapped ADT terrain?

magcius commented 7 months ago

Improved by 6d8a82e91371a2ba9b47da4135ac6c2682bf3ba3. The crater here still seems to have a seam; up to you whether you want to keep this issue open for that, or close and open a new one.

magcius commented 7 months ago
    alphaBlend.r = 1.0 - saturate(dot(alphaBlend.gba, vec3(1.0)));
    vec4 tex = tex0*alphaBlend.r + tex1*alphaBlend.g + tex2*alphaBlend.b + tex3*alphaBlend.a;
    // vec4 tex = mix(mix(mix(tex0, tex1, alphaBlend.g), tex2, alphaBlend.b), tex3, alphaBlend.a);

Treating the weights as if they are weight blends like heightmap texturing does fixes Strand of the Ancients, but it breaks Alterac Valley. Screenshots attached. Strand of the Ancient's WDT doesn't appear to have the "hasHeightTexturing" flag marked, but that might just be us not parsing out the flags correctly.

image

image