AcademySoftwareFoundation / openvdb

OpenVDB - Sparse volume data structure and tools
http://www.openvdb.org/
Mozilla Public License 2.0
2.62k stars 647 forks source link

Replace boost conversion_traits with std::common_type #1723

Closed Idclip closed 1 week ago

Idclip commented 9 months ago

Re-creating this so that we don't lose visibility on it. It currently cannot be merged due to https://github.com/AcademySoftwareFoundation/openvdb/issues/1700

bpmckinnon commented 9 months ago

One possible option given that std::numeric_limits is overridden is to try using std::numeric_limits::is_specialized instead. https://en.cppreference.com/w/cpp/types/numeric_limits/is_specialized

bpmckinnon commented 9 months ago

I've verified that this is at least a potential option on my windows build... but I can't guarantee it will work in the build environment that is failing.

apradhana commented 9 months ago

As for the problem that Matthew raised in Issue 1700 , I have a fix that I included in the draft PR for supporting half grid. What's needed is adding a cwiseAdd specialization for Vec3<math::half> as shown here.

bpmckinnon commented 5 months ago

Has there been any update on the cwiseAdd function? Otherwise I can add the is_specialized change I proposed.

bpmckinnon commented 2 weeks ago

Before this change can be resubmitted std::is_arithmetic_v should be replaced with std::numeric_limits::is_specialized to prevent the initial issue that was flagged

danrbailey commented 1 week ago

Merging to a feature branch to bring this PR up-to-date before merging to master.