You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The functions cwiseAdd, cwiseLessThan and cwiseGreaterThan in openvdb/math/Math.h should only be enabled for POD types, but are not guarded, so they break when grids with non-POD types are used.
A simple fix is something like:
template<typename Type1, typename Type2,
typename = std::enable_if_t<
std::is_trivial<Type1>::value && std::is_trivial<Type2>::value
>
>
inline bool cwiseGreaterThan(const Type1& a, const Type2& b)
This should result in no functional change for OpenVDB as shipped, but permit third parties to extend support for custom non-POD types.
The text was updated successfully, but these errors were encountered:
Describe the bug
The functions
cwiseAdd
,cwiseLessThan
andcwiseGreaterThan
inopenvdb/math/Math.h
should only be enabled for POD types, but are not guarded, so they break when grids with non-POD types are used.A simple fix is something like:
This should result in no functional change for OpenVDB as shipped, but permit third parties to extend support for custom non-POD types.
The text was updated successfully, but these errors were encountered: