-
-
Notifications
You must be signed in to change notification settings - Fork 608
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
Vertices in LoadObj is incorrect when TINYOBJLOADER_USE_DOUBLE is on #231
Comments
At least compiling loader_example.cc with Have you defined
|
Thanks for the pointer. Adding |
https://github.com/syoyo/tinyobjloader/blob/master/tiny_obj_loader.h#L130
Using templated type for real_t will solve such a confusion #233 |
Thanks. Looking forward to a solution to #233. |
You can contribute to support better double-precision support(and also quadruple-precision floating point if required) |
Taking another look on the
By something like this, after the add_library(): if(TINYOBJLOADER_USE_DOUBLE)
target_compile_definitions(${LIBRARY_NAME} PUBLIC TINYOBJLOADER_USE_DOUBLE)
endif() Other targets within the project as well in external CMake projects using the |
Given below minimal obj file
test.obj
Please see below minimal code
If
TINYOBJLOADER_USE_DOUBLE
is set to on in CMake while compiling tinyobjloader, the output is all wrong as shown below:whereas if
TINYOBJLOADER_USE_DOUBLE
is set to off in CMake while compiling tinyobjloader, the output is as expected like below:@syoyo @noma please take a look, many thanks.
The text was updated successfully, but these errors were encountered: