KhronosGroup / glTF-Sample-Assets

To store all models and other assets related to glTF
255 stars 30 forks source link

MorphPrimitivesTest.gltf morphs positions but not normals, lighting on morphed mesh looks incorrect #134

Open droettger opened 6 days ago

droettger commented 6 days ago

The model MorphPrimitivesTest.gltf provides position, normal, and texcoord0 attributes but only morphs positions. As consequence the morphed mesh uses normals of the flat mesh with all normals pointing to (0,1,0) and the lighting looks incorrect. This would not happen if the model wouldn't provide normal attributes (resulting in face normals calculated on the morphed positions) or proper morph targets for the normal attribute.