Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrecht Van Lommel <brechtvanlommel@gmail.com>2020-01-26 18:35:58 +0300
committerBrecht Van Lommel <brechtvanlommel@gmail.com>2020-01-27 14:19:49 +0300
commit37889011070ff2ec52159690f652238d2b325185 (patch)
treefcdbb010b251ccad383940f8215cbd7b8ab29d02 /intern/openvdb
parent34c8ba6d3e79e85231b0e63d25e7c43cf5ab4ea9 (diff)
Cleanup: fix compiler warnings
Diffstat (limited to 'intern/openvdb')
-rw-r--r--intern/openvdb/openvdb_util.cc7
1 files changed, 6 insertions, 1 deletions
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);
}