uint32_t nextVSyncTime = mLastVSyncTime + intervalMilliseconds;
float elapsedSeconds = static_cast<float>(intervalMilliseconds) * 0.001f;
- mCore->Update(elapsedSeconds, mLastVSyncTime, nextVSyncTime, mStatus, false, false);
+ mCore->Update(elapsedSeconds, mLastVSyncTime, nextVSyncTime, mStatus, false, false, false);
GetRenderController().Initialize();
return mImpl->GetMaximumUpdateCount();
}
-void Core::Update(float elapsedSeconds, uint32_t lastVSyncTimeMilliseconds, uint32_t nextVSyncTimeMilliseconds, UpdateStatus& status, bool renderToFboEnabled, bool isRenderingToFbo)
+void Core::Update(float elapsedSeconds, uint32_t lastVSyncTimeMilliseconds, uint32_t nextVSyncTimeMilliseconds, UpdateStatus& status, bool renderToFboEnabled, bool isRenderingToFbo, bool uploadOnly)
{
- mImpl->Update(elapsedSeconds, lastVSyncTimeMilliseconds, nextVSyncTimeMilliseconds, status, renderToFboEnabled, isRenderingToFbo);
+ mImpl->Update(elapsedSeconds, lastVSyncTimeMilliseconds, nextVSyncTimeMilliseconds, status, renderToFboEnabled, isRenderingToFbo, uploadOnly);
}
void Core::PreRender(RenderStatus& status, bool forceClear, bool uploadOnly)
* whether a Notification event should be sent, regardless of whether the multi-threading is used.
* @param[in] renderToFboEnabled Whether rendering into the Frame Buffer Object is enabled.
* @param[in] isRenderingToFbo Whether this frame is being rendered into the Frame Buffer Object.
+ * @param[in] uploadOnly uploadOnly Upload the resource only without rendering.
*/
void Update(float elapsedSeconds,
uint32_t lastVSyncTimeMilliseconds,
uint32_t nextVSyncTimeMilliseconds,
UpdateStatus& status,
bool renderToFboEnabled,
- bool isRenderingToFbo);
+ bool isRenderingToFbo,
+ bool uploadOnly);
/**
* This is called before rendering any scene in the next frame. This method should be preceded
mRenderManager->ContextDestroyed();
}
-void Core::Update( float elapsedSeconds, uint32_t lastVSyncTimeMilliseconds, uint32_t nextVSyncTimeMilliseconds, Integration::UpdateStatus& status, bool renderToFboEnabled, bool isRenderingToFbo )
+void Core::Update( float elapsedSeconds, uint32_t lastVSyncTimeMilliseconds, uint32_t nextVSyncTimeMilliseconds, Integration::UpdateStatus& status, bool renderToFboEnabled, bool isRenderingToFbo, bool uploadOnly )
{
// set the time delta so adaptor can easily print FPS with a release build with 0 as
// it is cached by frametime
lastVSyncTimeMilliseconds,
nextVSyncTimeMilliseconds,
renderToFboEnabled,
- isRenderingToFbo );
+ isRenderingToFbo,
+ uploadOnly );
// Check the Notification Manager message queue to set needsNotification
status.needsNotification = mNotificationManager->MessagesToProcess();
/**
* @copydoc Dali::Integration::Core::Update()
*/
- void Update( float elapsedSeconds, uint32_t lastVSyncTimeMilliseconds, uint32_t nextVSyncTimeMilliseconds, Integration::UpdateStatus& status, bool renderToFboEnabled, bool isRenderingToFbo );
+ void Update( float elapsedSeconds, uint32_t lastVSyncTimeMilliseconds, uint32_t nextVSyncTimeMilliseconds, Integration::UpdateStatus& status, bool renderToFboEnabled, bool isRenderingToFbo, bool uploadOnly );
/**
* @copydoc Dali::Integration::Core::PreRender()
uint32_t lastVSyncTimeMilliseconds,
uint32_t nextVSyncTimeMilliseconds,
bool renderToFboEnabled,
- bool isRenderingToFbo )
+ bool isRenderingToFbo,
+ bool uploadOnly )
{
const BufferIndex bufferIndex = mSceneGraphBuffers.GetUpdateBufferIndex();
}
}
-
std::size_t numberOfRenderInstructions = 0;
for ( auto&& scene : mImpl->scenes )
{
}
}
- for ( auto&& scene : mImpl->scenes )
+ if(!uploadOnly)
{
- if ( scene && scene->root && scene->taskList )
+ for(auto&& scene : mImpl->scenes)
{
- RenderTaskList::RenderTaskContainer& tasks = scene->taskList->GetTasks();
-
- // check the countdown and notify
- bool doRenderOnceNotify = false;
- mImpl->renderTaskWaiting = false;
- for ( auto&& renderTask : tasks )
+ if(scene && scene->root && scene->taskList)
{
- renderTask->UpdateState();
+ RenderTaskList::RenderTaskContainer& tasks = scene->taskList->GetTasks();
- if( renderTask->IsWaitingToRender() &&
- renderTask->ReadyToRender( bufferIndex ) /*avoid updating forever when source actor is off-stage*/ )
+ // check the countdown and notify
+ bool doRenderOnceNotify = false;
+ mImpl->renderTaskWaiting = false;
+ for(auto&& renderTask : tasks)
{
- mImpl->renderTaskWaiting = true; // keep update/render threads alive
+ renderTask->UpdateState();
+
+ if(renderTask->IsWaitingToRender() &&
+ renderTask->ReadyToRender(bufferIndex) /*avoid updating forever when source actor is off-stage*/)
+ {
+ mImpl->renderTaskWaiting = true; // keep update/render threads alive
+ }
+
+ if(renderTask->HasRendered())
+ {
+ doRenderOnceNotify = true;
+ }
}
- if( renderTask->HasRendered() )
+ if(doRenderOnceNotify)
{
- doRenderOnceNotify = true;
+ DALI_LOG_INFO(gRenderTaskLogFilter, Debug::General, "Notify a render task has finished\n");
+ mImpl->notificationManager.QueueCompleteNotification(scene->taskList->GetCompleteNotificationInterface());
}
}
-
- if( doRenderOnceNotify )
- {
- DALI_LOG_INFO(gRenderTaskLogFilter, Debug::General, "Notify a render task has finished\n");
- mImpl->notificationManager.QueueCompleteNotification( scene->taskList->GetCompleteNotificationInterface() );
- }
}
}
* @param[in] nextVSyncTimeMilliseconds The estimated time, in milliseconds, of the next VSync.
* @param[in] renderToFboEnabled Whether rendering into the Frame Buffer Object is enabled.
* @param[in] isRenderingToFbo Whether this frame is being rendered into the Frame Buffer Object.
+ * @param[in] uploadOnly uploadOnly Upload the resource only without rendering.
* @return True if further updates are required e.g. during animations.
*/
uint32_t Update( float elapsedSeconds,
uint32_t lastVSyncTimeMilliseconds,
uint32_t nextVSyncTimeMilliseconds,
bool renderToFboEnabled,
- bool isRenderingToFbo );
+ bool isRenderingToFbo,
+ bool uploadOnly );
/**
* Set the default surface rect.