kvark / obj

Basic Wavefront OBJ loader
Apache License 2.0
29 stars 12 forks source link

fix: `impl std::fmt::Display for IndexTuple` is incorrect for normal without texture coordinate #32

Closed ishbosamiya closed 6 months ago

ishbosamiya commented 6 months ago

When using IndexTuple(0, None, Some(0)), the output should be 1//1 but the output was 1/1.

1/1 implies position index followed by texture coordinate index where as 1//1 implies position index followed by no texture coordinate index followed by normal index which is the expected output.

Reference