summarylogtreecommitdiffstats
path: root/openvdb8.patch
diff options
context:
space:
mode:
Diffstat (limited to 'openvdb8.patch')
-rw-r--r--openvdb8.patch16
1 files changed, 16 insertions, 0 deletions
diff --git a/openvdb8.patch b/openvdb8.patch
new file mode 100644
index 000000000000..bb44c7946cdf
--- /dev/null
+++ b/openvdb8.patch
@@ -0,0 +1,16 @@
+diff --git a/intern/openvdb/openvdb_util.cc b/intern/openvdb/openvdb_util.cc
+index a221a537851..899b41ff09b 100644
+--- a/intern/openvdb/openvdb_util.cc
++++ b/intern/openvdb/openvdb_util.cc
+@@ -27,5 +27,10 @@ ScopeTimer::ScopeTimer(const std::string &message) : m_message(message), m_timer
+
+ ScopeTimer::~ScopeTimer()
+ {
+- std::printf("%s: %fms\n", m_message.c_str(), m_timer.delta());
++#if OPENVDB_LIBRARY_MAJOR_VERSION_NUMBER >= 7
++ double delta = m_timer.milliseconds();
++#else
++ double delta = m_timer.delta(); /* Deprecated in OpenVDB 7. */
++#endif
++ std::printf("%s: %fms\n", m_message.c_str(), delta);
+ }