From: Joogab Yun Date: Tue, 10 Sep 2019 09:16:54 +0000 (+0900) Subject: [Tizen] Log patch to show first swapbuffers call after resume X-Git-Tag: accepted/tizen/unified/20190911.111623~2 X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fuifw%2Fdali-adaptor.git;a=commitdiff_plain;h=c2c11b62a84124d5b61cc91ed4a6d2698a852980 [Tizen] Log patch to show first swapbuffers call after resume This reverts commit 6a17b1520b157712457cbf6a8af394b02782d062. Change-Id: I80e7c91a1ba15098b9afd6c1748754c6ce503eba --- diff --git a/dali/internal/adaptor/common/combined-update-render-controller.cpp b/dali/internal/adaptor/common/combined-update-render-controller.cpp index 94693d2..66f32d5 100644 --- a/dali/internal/adaptor/common/combined-update-render-controller.cpp +++ b/dali/internal/adaptor/common/combined-update-render-controller.cpp @@ -633,6 +633,11 @@ void CombinedUpdateRenderController::UpdateRenderThread() eglImpl.MakeContextCurrent( EGL_NO_SURFACE, eglImpl.GetContext() ); } + if( timeToSleepUntil == 0 ) + { + eglImpl.SetFirstFrameAfterResume(); + } + Integration::RenderStatus renderStatus; AddPerformanceMarker( PerformanceInterface::RENDER_START ); diff --git a/dali/internal/graphics/gles/egl-implementation.cpp b/dali/internal/graphics/gles/egl-implementation.cpp index 3885134..ae95d25 100755 --- a/dali/internal/graphics/gles/egl-implementation.cpp +++ b/dali/internal/graphics/gles/egl-implementation.cpp @@ -81,7 +81,8 @@ EglImplementation::EglImplementation( int multiSamplingLevel, mDepthBufferRequired( depthBufferRequired == Integration::DepthBufferAvailable::TRUE ), mStencilBufferRequired( stencilBufferRequired == Integration::StencilBufferAvailable::TRUE ), mIsSurfacelessContextSupported( false ), - mIsKhrCreateContextSupported( false ) + mIsKhrCreateContextSupported( false ), + mIsFirstFrameAfterResume( false ) { } @@ -310,6 +311,11 @@ void EglImplementation::SwapBuffers( EGLSurface& eglSurface ) { if ( eglSurface != EGL_NO_SURFACE ) // skip if using surfaceless context { + if( mIsFirstFrameAfterResume ) + { + DALI_LOG_RELEASE_INFO( "EglImplementation::SwapBuffers: First SwapBuffers call.\n" ); + mIsFirstFrameAfterResume = false; + } eglSwapBuffers( mEglDisplay, eglSurface ); } } @@ -536,6 +542,11 @@ void EglImplementation::SetGlesVersion( const int32_t glesVersion ) mGlesVersion = glesVersion; } +void EglImplementation::SetFirstFrameAfterResume() +{ + mIsFirstFrameAfterResume = true; +} + EGLDisplay EglImplementation::GetDisplay() const { return mEglDisplay; diff --git a/dali/internal/graphics/gles/egl-implementation.h b/dali/internal/graphics/gles/egl-implementation.h index 1c9cab3..c0cf433 100644 --- a/dali/internal/graphics/gles/egl-implementation.h +++ b/dali/internal/graphics/gles/egl-implementation.h @@ -182,6 +182,11 @@ public: void SetGlesVersion( const int32_t glesVersion ); /** + * Sets Whether the frame is the first after Resume. + */ + void SetFirstFrameAfterResume(); + + /** * returns the display with which this object was initialized * @return the EGL Display. */ @@ -245,6 +250,8 @@ private: bool mStencilBufferRequired; bool mIsSurfacelessContextSupported; bool mIsKhrCreateContextSupported; + + bool mIsFirstFrameAfterResume; }; } // namespace Adaptor