From 5f24d63d89009a91035f586a1d80fa61fcd2d681 Mon Sep 17 00:00:00 2001 From: Ulf Hermann Date: Mon, 30 Jun 2014 14:01:38 +0200 Subject: Properly collect polish timings from all render loops Previously the polish timings were collected incorrectly from the windows render loop and not at all from the basic render loop. By collecting the polish times at the right places we can get rid of the 2-argument profile macro as well. Task-number: QTBUG-39876 Change-Id: I0b4aaf87162c652b8dcea6cd4f54db053f8312fe Reviewed-by: Gunnar Sletta --- src/quick/scenegraph/qsgwindowsrenderloop.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/quick/scenegraph/qsgwindowsrenderloop.cpp') diff --git a/src/quick/scenegraph/qsgwindowsrenderloop.cpp b/src/quick/scenegraph/qsgwindowsrenderloop.cpp index 5961c96319..70f80689f5 100644 --- a/src/quick/scenegraph/qsgwindowsrenderloop.cpp +++ b/src/quick/scenegraph/qsgwindowsrenderloop.cpp @@ -376,7 +376,7 @@ void QSGWindowsRenderLoop::render() "animations ticked in %dms", int((qsg_render_timer.nsecsElapsed() - time_start)/1000000)); - Q_QUICK_SG_PROFILE1(QQuickProfiler::SceneGraphWindowsAnimations, ( + Q_QUICK_SG_PROFILE(QQuickProfiler::SceneGraphWindowsAnimations, ( qsg_render_timer.nsecsElapsed() - time_start)); // It is not given that animations triggered another maybeUpdate() @@ -418,6 +418,8 @@ void QSGWindowsRenderLoop::renderWindow(QQuickWindow *window) d->polishItems(); QSG_RENDER_TIMING_SAMPLE(time_polished); + Q_QUICK_SG_PROFILE(QQuickProfiler::SceneGraphPolishFrame, (time_polished - time_start)); + emit window->afterAnimating(); RLDEBUG(" - syncing"); @@ -443,12 +445,10 @@ void QSGWindowsRenderLoop::renderWindow(QQuickWindow *window) << ", swap=" << (time_swapped - time_rendered) / 1000000 << " - " << window; - Q_QUICK_SG_PROFILE2(QQuickProfiler::SceneGraphWindowsPolishFrame, - QQuickProfiler::SceneGraphRenderLoopFrame, ( + Q_QUICK_SG_PROFILE(QQuickProfiler::SceneGraphRenderLoopFrame, ( time_synced - time_polished, time_rendered - time_synced, - time_swapped - time_rendered, - time_polished - time_start)); + time_swapped - time_rendered)); } QT_END_NAMESPACE -- cgit v1.2.3