-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Normals got flipped #10
Comments
@emackey Thanks for catching this! I was making an optimization that inadvertently broke the generated tangents such that the handedness is wrong. I didn't notice because most of the sample models have tangents specified. I will make a fix. |
@bghgary Great! Looking forward to merging a fix into my gltf-vscode extension. On a related note, ThreeJS still isn't processing these normals correctly either. That bug is reported separately in donmccurdy/three-gltf-viewer#10. |
This should be fixed with f8f5db0 The PR for BabylonJS is here: BabylonJS/Babylon.js#2222 |
Well... I merged this into my fork, but it doesn't look like anything changed. Maybe the fix didn't get deployed to a release branch or something yet? https://emackey.github.io/BabylonJS-glTFLoader/?model=NormalTangentTest |
Oops, sorry about that. I pushed the wrong version. Fixed now. |
Awesome! Fix confirmed. |
Hi guys,
An update to BabylonJS was recently pushed to this repo (in 6a74f09), and the direction of the Y-axis on the normal maps has flipped during that update. If I load the NormalTangentTest object with the latest version of this repo, I get mixed-up normal maps, like this:
Prior to the update to BabylonJS, the same model produces correct normals:
As an experiment, I tried loading the so-called "DirectX normals" (as described in KhronosGroup/glTF#952), where the green channel intensity is inverted. These normals do produce the correct output in master on this repo, but, I believe they do not meet the glTF 2.0 spec as it stands.
The text was updated successfully, but these errors were encountered: