From db38573ca0592bc9f564a1d5798c07b6c9ee507c Mon Sep 17 00:00:00 2001 From: Florin Malita Date: Tue, 9 Jan 2018 12:19:32 -0500 Subject: [skotty] Pre-initialize animated props Force an initial tick on animation initialization. This prevents inconsistent state flashing if the client starts rendering before the first tick. TBR= Change-Id: Iaec3146b4085c980e6501d6a65dd8f2421a2895f Reviewed-on: https://skia-review.googlesource.com/92740 Reviewed-by: Florin Malita Commit-Queue: Florin Malita --- experimental/skotty/Skotty.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'experimental') diff --git a/experimental/skotty/Skotty.cpp b/experimental/skotty/Skotty.cpp index 9d11812765..d118516d16 100644 --- a/experimental/skotty/Skotty.cpp +++ b/experimental/skotty/Skotty.cpp @@ -897,6 +897,9 @@ Animation::Animation(const ResourceProvider& resources, AttachContext ctx = { resources, assets, fAnimators }; fDom = AttachComposition(json, &ctx); + // In case the client calls render before the first tick. + this->animationTick(0); + LOG("** Attached %d animators\n", fAnimators.count()); } -- cgit v1.2.3