lottie/parser: wrap the trim offset value before normalize. 97/188197/1
authorsubhransu mohanty <sub.mohanty@samsung.com>
Mon, 3 Sep 2018 03:31:16 +0000 (12:31 +0900)
committersubhransu mohanty <sub.mohanty@samsung.com>
Mon, 3 Sep 2018 03:31:16 +0000 (12:31 +0900)
Change-Id: I5bce3b840cc54d626ea2397d35c4a7ef90e7be7e

src/lottie/lottiemodel.h

index 61e0d9b402698dfda4924b3390df600bd1c234b2..7d4518ea0d9f869ceb1a4380aa6d4231dca65dbe 100644 (file)
@@ -656,7 +656,7 @@ public:
     {visitor->visit(this);}
     float start(int frameNo) const {return mStart.value(frameNo)/100.0f;}
     float end(int frameNo) const {return mEnd.value(frameNo)/100.0f;}
-    float offset(int frameNo) const {return mOffset.value(frameNo)/ 360.0f;}
+    float offset(int frameNo) const {return fmod(mOffset.value(frameNo), 360.0f)/ 360.0f;}
     LOTTrimData::TrimType type() const {return mTrimType;}
 public:
     LOTAnimatable<float>             mStart{0};