From 8c7781a6d47c8afe1409fe289799b1d6d1b4df10 Mon Sep 17 00:00:00 2001 From: sam gateau Date: Tue, 11 Sep 2018 15:57:57 -0700 Subject: [PATCH] use the std::chrono duration the way it should be --- libraries/gpu-gl-common/src/gpu/gl/GLBackendQuery.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/gpu-gl-common/src/gpu/gl/GLBackendQuery.cpp b/libraries/gpu-gl-common/src/gpu/gl/GLBackendQuery.cpp index 8aa0f3c699..61423bf970 100644 --- a/libraries/gpu-gl-common/src/gpu/gl/GLBackendQuery.cpp +++ b/libraries/gpu-gl-common/src/gpu/gl/GLBackendQuery.cpp @@ -63,7 +63,7 @@ void GLBackend::do_endQuery(const Batch& batch, size_t paramOffset) { #endif --_queryStage._rangeQueryDepth; - auto duration_ns = (std::chrono::high_resolution_clock::now() - glquery->_batchElapsedTimeBegin); + auto duration_ns = std::chrono::duration_cast(std::chrono::high_resolution_clock::now() - glquery->_batchElapsedTimeBegin); glquery->_batchElapsedTime = duration_ns.count(); PROFILE_RANGE_END(render_gpu_gl_detail, glquery->_profileRangeId);