X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fuifw%2Fdali-toolkit.git;a=blobdiff_plain;f=automated-tests%2Fsrc%2Fdali-toolkit%2Fdali-toolkit-test-utils%2Ftest-application.cpp;h=8bb7176a0f5aca266910af7a9160ce203dbb4c7a;hp=66366765eae5bf8502888b596ebfb3a4c7970179;hb=e37f48bb34e81585a6ed436bd7a2f9dce02c19f5;hpb=e2d3bdc173f657ddf0a0c58062a61bbbaaf6f9da diff --git a/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/test-application.cpp b/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/test-application.cpp index 6636676..8bb7176 100644 --- a/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/test-application.cpp +++ b/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/test-application.cpp @@ -62,13 +62,15 @@ void TestApplication::Initialize() // We always need the first update! mStatus.keepUpdating = Integration::KeepUpdating::STAGE_KEEP_RENDERING; - mCore = Dali::Integration::Core::New( - mRenderController, - mPlatformAbstraction, - mGlAbstraction, - mGlSyncAbstraction, - mGestureManager, - mDataRetentionPolicy); + mCore = Dali::Integration::Core::New( mRenderController, + mPlatformAbstraction, + mGlAbstraction, + mGlSyncAbstraction, + mGestureManager, + mDataRetentionPolicy, + Integration::RenderToFrameBuffer::FALSE, + Integration::DepthBufferAvailable::TRUE, + Integration::StencilBufferAvailable::TRUE ); mCore->ContextCreated(); mCore->SurfaceResized( mSurfaceWidth, mSurfaceHeight ); @@ -77,6 +79,11 @@ void TestApplication::Initialize() Dali::Integration::Log::LogFunction logFunction(&TestApplication::LogMessage); Dali::Integration::Log::InstallLogFunction(logFunction); + Dali::Integration::Trace::LogContextFunction logContextFunction(&TestApplication::LogContext); + Dali::Integration::Trace::InstallLogContextFunction( logContextFunction ); + + Dali::Integration::Trace::LogContext( true, "Test" ); + mCore->SceneCreated(); } @@ -86,6 +93,18 @@ TestApplication::~TestApplication() delete mCore; } +void TestApplication::LogContext( bool start, const char* tag ) +{ + if( start ) + { + fprintf(stderr, "INFO: Trace Start: %s", tag); + } + else + { + fprintf(stderr, "INFO: Trace End: %s", tag); + } +} + void TestApplication::LogMessage(Dali::Integration::Log::DebugPriority level, std::string& message) { switch(level) @@ -171,7 +190,7 @@ void TestApplication::DoUpdate( unsigned int intervalMilliseconds, const char* l unsigned int nextVSyncTime = mLastVSyncTime + intervalMilliseconds; float elapsedSeconds = intervalMilliseconds / 1e3f; - mCore->Update( elapsedSeconds, mLastVSyncTime, nextVSyncTime, mStatus ); + mCore->Update( elapsedSeconds, mLastVSyncTime, nextVSyncTime, mStatus, false, false ); GetRenderController().Initialize(); @@ -181,7 +200,7 @@ void TestApplication::DoUpdate( unsigned int intervalMilliseconds, const char* l bool TestApplication::Render( unsigned int intervalMilliseconds, const char* location ) { DoUpdate( intervalMilliseconds, location ); - mCore->Render( mRenderStatus ); + mCore->Render( mRenderStatus, false ); mFrame++; @@ -207,7 +226,7 @@ bool TestApplication::GetRenderNeedsUpdate() bool TestApplication::RenderOnly( ) { // Update Time values - mCore->Render( mRenderStatus ); + mCore->Render( mRenderStatus, false ); mFrame++;