I'm attempting to integrate NanoVDB into my C++ project using Visual Studio 2022, and I was encountering multiple syntax errors in the GridBuilder.h file. The errors suggest issues with the syntax that were unexpected by the compiler. Here are the errors:
Error C2760: Syntax error: ')' was unexpected here; expected ';'
Error C2760: Syntax error: 'const' was unexpected here; expected ')'
Error C3329: Syntax error: expected 'identifier' not ')'
Error C3878: Syntax error: unexpected token ')' following 'expression_statement'
To fix the issue I set Properties-->C/C++-->Command Line-->Additional Options with Zc:__cplusplus /std:c++20. And It actually worked and fix the issue.
Now I am encountering error in CreateNnaoGrid.h file. The error is
Error C2039: 'gridClass': is not a member of 'openvdb::v11_0::Grid'
Note: I've also built the project on Linux and encountered the same errors
Questions:
1) Has anyone else faced this issue, and how did you resolve it?
2) Could this be related to a version mismatch between OpenVDB and NanoVDB?
3) Any suggestions on how to troubleshoot or fix this error would be greatly appreciated.
I'm attempting to integrate NanoVDB into my C++ project using Visual Studio 2022, and I was encountering multiple syntax errors in the GridBuilder.h file. The errors suggest issues with the syntax that were unexpected by the compiler. Here are the errors:
Error C2760: Syntax error: ')' was unexpected here; expected ';' Error C2760: Syntax error: 'const' was unexpected here; expected ')' Error C3329: Syntax error: expected 'identifier' not ')' Error C3878: Syntax error: unexpected token ')' following 'expression_statement'
To fix the issue I set Properties-->C/C++-->Command Line-->Additional Options with Zc:__cplusplus /std:c++20. And It actually worked and fix the issue.
Now I am encountering error in CreateNnaoGrid.h file. The error is
Error C2039: 'gridClass': is not a member of 'openvdb::v11_0::Grid'
Note: I've also built the project on Linux and encountered the same errors
Questions:
1) Has anyone else faced this issue, and how did you resolve it? 2) Could this be related to a version mismatch between OpenVDB and NanoVDB? 3) Any suggestions on how to troubleshoot or fix this error would be greatly appreciated.
Thank you