2 * Copyright (c) 2020 Samsung Electronics Co., Ltd. All rights reserved.
4 * Permission is hereby granted, free of charge, to any person obtaining a copy
5 * of this software and associated documentation files (the "Software"), to deal
6 * in the Software without restriction, including without limitation the rights
7 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8 * copies of the Software, and to permit persons to whom the Software is
9 * furnished to do so, subject to the following conditions:
11 * The above copyright notice and this permission notice shall be included in all
12 * copies or substantial portions of the Software.
14 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
17 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
19 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
23 #ifndef _RLOTTIE_COMMON_H_
24 #define _RLOTTIE_COMMON_H_
26 #if defined _WIN32 || defined __CYGWIN__
28 #define RLOTTIE_API __declspec(dllexport)
30 #define RLOTTIE_API __declspec(dllimport)
34 #define RLOTTIE_API __attribute__ ((visibility ("default")))
42 * @defgroup Lottie_Animation Lottie_Animation
44 * Lottie Animation is a modern style vector based animation design. Its animation
45 * resource(within json format) could be generated by Adobe After Effect using
46 * bodymovin plugin. You can find a good examples in Lottie Community which
47 * shares many free resources(see: www.lottiefiles.com).
49 * This Lottie_Animation is a common engine to manipulate, control Lottie
50 * Animation from the Lottie resource - json file. It provides a scene-graph
51 * node tree per frames by user demand as well as rasterized frame images.
56 * @ingroup Lottie_Animation
91 typedef struct LOTGradientStop
94 unsigned char r, g, b, a;
105 typedef struct LOTMask {
113 unsigned char mAlpha;
125 typedef struct LOTMarker {
131 typedef struct LOTMarkerList {
136 typedef struct LOTNode {
138 #define ChangeFlagNone 0x0000
139 #define ChangeFlagPath 0x0001
140 #define ChangeFlagPaint 0x0010
141 #define ChangeFlagAll (ChangeFlagPath & ChangeFlagPaint)
151 unsigned char r, g, b, a;
155 unsigned char enable;
165 LOTGradientType type;
166 LOTGradientStop *stopPtr;
170 } start, end, center, focal;
179 unsigned char mAlpha;
181 float m11; float m12; float m13;
182 float m21; float m22; float m23;
183 float m31; float m32; float m33;
188 LOTBrushType mBrushType;
189 LOTFillRule mFillRule;
196 typedef struct LOTLayerNode {
211 struct LOTLayerNode **ptr;
222 unsigned char mAlpha;
231 #endif // _RLOTTIE_COMMON_H_