void VectorAnimationTask::Finalize()
{
+ ConditionalWait::ScopedLock lock( mConditionalWait );
+
// Release some objects in the main thread
if( mAnimationFinishedTrigger )
{
bool VectorAnimationTask::Rasterize()
{
- bool stopped = false, needAnimationFinishedTrigger;
+ bool stopped = false, needAnimationFinishedTrigger, resourceReady;
uint32_t currentFrame, startFrame, endFrame;
int32_t loopCount, currentLoopCount;
PlayState playState;
currentLoopCount = mCurrentLoop;
needAnimationFinishedTrigger = mNeedAnimationFinishedTrigger;
playState = mPlayState;
+ resourceReady = mResourceReady;
mResourceReady = true;
mCurrentFrameUpdated = false;
{
DALI_LOG_INFO( gVectorAnimationLogFilter, Debug::Verbose, "VectorAnimationTask::Rasterize: Rendering failed. Try again later.[%d] [%p]\n", currentFrame, this );
mUpdateFrameNumber = false;
+
+ if( !resourceReady )
+ {
+ ConditionalWait::ScopedLock lock( mConditionalWait );
+ mResourceReady = false;
+ }
}
}
if( stopped && renderSuccess )
{
+ ConditionalWait::ScopedLock lock( mConditionalWait );
+
mPlayState = PlayState::STOPPED;
mForward = true;
mCurrentLoop = 0;