Commit Graph

196 Commits

Author SHA1 Message Date
Youngbok Shin
386e6ebbff lottie: fix doubled scale issue
The scale was calculated based on length 2.
So, its result was also doubled.
It should be half before return scale result.

Change-Id: I66a5fa9ba235bd5ebcde89b9b3c01c0f128d217e
2018-08-23 19:31:28 +09:00
subhransu mohanty
2e59b9fb93 lottie: remove dead code.
Change-Id: I81d8c6e3e0c4b6b6d9cff03f70e8818af57dfade
2018-08-23 17:19:43 +09:00
Youngbok Shin
eea5add913 lottie: fixed regression caused by last commit
There was issue caused by item inside of groups.

Change-Id: If9057db4f183fc2956d3bd43dca92fc5bb628202
2018-08-23 17:07:48 +09:00
subhransu mohanty
5775d02261 lottie: refactor the lottie scene graph processing.
Change-Id: I739aa19abaf7f141b556b67083df4461945461d9
2018-08-23 15:28:33 +09:00
subhransu mohanty
43d77af0d1 lottie/vector : added addPath() api to vpath.
Change-Id: I3fd7ee9ba8add8f7109c23c0b6e62388b3fda5bf
2018-08-23 13:15:49 +09:00
subhransu mohanty
f0515f36b8 lottie/vector: return correct number from segments() api.
Change-Id: Ifb90d0f7567ba0737f70c7b7abfc467e94004780
2018-08-23 13:13:08 +09:00
Hermet Park
857fde3fa7 lottieplayer: polishing getFrameDuration(), getFrameRate()
Change-Id: I4344a6689c7ee8890e33978bfc5ca6a2c401da36
2018-08-23 00:38:29 +00:00
Jaeun Choi
d2c954d535 lottie/example: add frame information in lottieviewer example
Change-Id: If9245244bfd3e8d8050e18b5ea09fcaf240a867d
2018-08-23 00:36:25 +00:00
Jaeun Choi
02e660cff7 lottie/example: add APIs in lottieview to get frame rate and total frame number
Change-Id: I25d14d37776cd6bf07bcba1f0fc6a1c88e66dd71
2018-08-23 00:34:57 +00:00
Youngbok Shin
318151a35d lottie: remove the combined alpha value and method from path item
Alpha(opacity) values are not applied to path items.
Fill, Stroke and etc will handle opacity.

Change-Id: I8e05989e7f85797a00508c7ca151b1805d44f454
2018-08-23 00:27:37 +00:00
Jaeun Choi
25784d646a lottie: add APIs in lottieplayer to get frame rate and total frame number
Change-Id: Ib81eed03adf520927b3b434b67425168b07f13b1
2018-08-22 05:14:27 +00:00
Hermet Park
830ef02827 binding/c: more compatible with C compiler.
Change-Id: I9fea4817cc913913f65c4b228cb0a42aae2cb2f8
2018-08-22 04:53:44 +00:00
Jaeun Choi
388736bfbe lottie: fixed lottieviewer example
Change-Id: I5ede2096f3e00dd4b343a05b337dd67070f6ac66
2018-08-21 17:28:31 +09:00
subhransu mohanty
17bc03eb44 lottie/example: updated lottieviewer example.
Change-Id: I97e30598090f16e4370f1d08dc94315789d82a3d
2018-08-21 14:25:50 +09:00
subhransu mohanty
3b4f97911f lottie/parser: changed the datatype of gradient member object .
Change-Id: I2b1ca35904f1d5af39c0c76be47af582f9b93041
2018-08-21 14:07:24 +09:00
Youngbok Shin
8ea21ce487 lottie/example: add complex gradient examples and remove simple one
Change-Id: I6003e3ca3209125c119feaaae55da35327b52a2c
2018-08-21 13:57:22 +09:00
subhransu mohanty
bfbe3c986a lottie: fixed warnings generated by '-Wextra' flag.
Change-Id: I73c122f61e628bdbdb6ab98bb68b7d32ab9f4ec0
2018-08-21 13:26:08 +09:00
Youngbok Shin
d23e61c69d lottie/example: add a missing example lottie file
It is good to test matte feature and managing multiple layers.

Change-Id: Ie87cc18d0b37b35858c765339d129dc35f2c2986
2018-08-21 13:20:22 +09:00
subhransu mohanty
8a0d4d746b lottie: build fix.
Change-Id: Ie008c71e2fcb3bcf7197245e26880e71e2bedc32
2018-08-21 04:01:24 +00:00
Jaeun Choi
617b257ec4 lottie: add "lottieviewer" example
lottieviewer shows each frame image according to slider value.
since edc compilation is not supported yet,
do the following steps to run this example:

$ cd example
$ edje_cc layout.edc
$ mv layout.edj ../build/example

Change-Id: I00f7d8b743e9028d1e8006104e63bef5d96084b6
2018-08-21 03:53:11 +00:00
sub.mohanty@samsung.com
ed0b8f5b4c lottie/render: added support to render difference mask mode.
Change-Id: Ia6ccba78181c87c6b49124026494b324ba93a846
2018-08-21 03:52:40 +00:00
sub.mohanty@samsung.com
bb877fd7d2 lottie/parser: updated parser to parse difference mask mode
Change-Id: I607d4f56a849d1cb928926c2d4ecc30cf1313e7e
2018-08-21 03:52:19 +00:00
subhransu mohanty
6fb25316ee lottie: refactor VRaster class.
Change-Id: Iadd382d34fcaa67a4cb60b44f22af38051f6f09a
2018-08-21 03:50:57 +00:00
subhransu mohanty
c12a9916a5 lottie:convert remaining raw pointer to unique_ptr.
Change-Id: If85e7b8ffbbacd2cd305e6a3ef6d98ccd8ed7172
2018-08-21 03:50:50 +00:00
sub.mohanty@samsung.com
ded7532e57 lottie/vector: added Xor operation to Rle object
Change-Id: I48cb3680a22ce3fb7f07048385dd5cc518ff9c7e
2018-08-21 03:49:40 +00:00
Hermet Park
8bba2bc8d4 lottieplayer: handling error code.
Change-Id: I24c88fad24b821e18e7071e6bd82a828b8fd358e
2018-08-21 02:24:10 +00:00
Hermet Park
ca6738b3da add c interface.
Change-Id: Ifc81f35479aa6e0ef18ead5b863ae80b34f98f85
2018-08-21 02:08:34 +00:00
Hermet Park
d49fb641e0 refactor infrastructure.
Split common delcaration from lottieplayer.h
This common delcaration will be used in c interface header files.

Change-Id: Icb3e3f182b2f27fc2d7c9bed36ac29c45c813b66
2018-08-21 00:46:52 +00:00
Youngbok Shin
083ec1abb8 lottie: apply matte feature to LOTCompLayerItem
The LOTCompLayerItem's MatteRle has to be inherited to its all children layers.
You can test it with "personal_character.json".

Change-Id: I225e16397441f9771286c6fcc821b5050b165ecc
2018-08-21 09:45:08 +09:00
subhransu mohanty
57b58412b6 lottie/render: handle the case when resulting mask is null.
Change-Id: Ie78a1465474ec408bff0deafdff509f3b3a199d8
2018-08-20 18:22:16 +09:00
Jaeun Choi
bbdd2e246f lottie: add getImage() API in lottieview
Change-Id: Ic72bb47752797811cbe7c464e02c81bcfd0a9a11
2018-08-20 06:03:49 +00:00
subhransu mohanty
f41c6624e5 lottie: use unique_ptr instead of raw pointer.
Change-Id: Ic5b416c72a96427dff3a99316550d8edb7ffece9
2018-08-20 13:44:59 +09:00
subhransu mohanty
fa087b44e8 lottie/parser: treat root layer as a special precomp layer.
Change-Id: Ic9a2b171ee349f132e52db5395a92587c9e44c08
2018-08-20 04:42:50 +00:00
subhransu mohanty
5895944d4c lottie/player: refactor to use std::find_if instead of unorder_map.
Change-Id: Ic146357db1312aa0ff122fa6859a64098e350740
2018-08-20 13:38:05 +09:00
subhransu mohanty
9ce5e8138f lottie: build fix.
Change-Id: I5405a17d67066fc5cd10d816f4ed044fb8819471
2018-08-20 12:54:29 +09:00
Hermet Park
ddde576886 lotplayer: improve header format.
1. add namespace.
2. remove unnecessary export attribute.
3. hide prviate member.

This is one ongoing improvement.

Change-Id: I342e4d5e65370190ac55972b02f2fede1aee6d06
2018-08-20 03:30:09 +00:00
Hermet Park
20823b49fe lottieplayer: Add render option to update buffer forcely.
plus code refactoring.

Change-Id: Icef131a7df5fa9766ff9cfe7513b1865692719f5
2018-08-20 03:29:31 +00:00
Hermet Park
9c958d0de5 enable build example in default.
enable this under *aggressive development step.

Change-Id: I8ff728c94ef899441e8f528609248a9451ac7c0b
2018-08-20 12:06:44 +09:00
Hermet Park
d76883080a update gitignore
Change-Id: Ib1ccc3feb6155384c1c0bb7e101abbec19c2386c
2018-08-17 21:27:05 +09:00
subhransu mohanty
02404178e8 lottie/parser: Added support for separate position attribute in transform object.
Transform object can have separate x and y or a point object.

Change-Id: I0ad0073b3cb958336539ad520434c3284894c6b9
2018-08-17 06:33:43 +00:00
subhransu mohanty
5af0cb88f8 lottie/player: refactor lottieplayer.
Change-Id: Ia9b484e8be756d2e90f6b0d2a837f56e46f40e4c
2018-08-16 19:29:43 +09:00
subhransu mohanty
1a6b8c8e0e lottie/vector: refactor VPath class to use emplace_back instead of push_back to avoid temporary object creation.
Change-Id: I0abc1be410a3758c447de8b4600c472f6298bcc7
2018-08-16 14:30:57 +09:00
subhransu mohanty
da553c4dab lottie/optimization: keep drawablelist in layer to avoid memory allocation in every frame.
Change-Id: I80eebb9e1ab16a424a26a17ce67274c7518efca9
2018-08-16 13:37:21 +09:00
Youngbok Shin
ff13f55ad4 lottie: pass matteSource and bitmap to layer's render function
matteSource layer has to be handled in other way.
For now, matteSource layer does not be applied to layers.
But, matteSource layer will be invisible.
In some test cases, it helps to check other layers which are overlayed by
a wrongly drawn matteSource layer. Anyway, the matte feature will be implemented soon.

Change-Id: Ib1e47e7ce9012b73a1729341d130defa561061c6
2018-08-16 04:16:46 +00:00
subhransu mohanty
308d8cf4ba lottie/parser: refactor lottie model objects.
Change-Id: I89160d918b36300b4f98a8059106c356e96643d0
2018-08-16 02:44:17 +00:00
subhransu mohanty
c326d5464c lottie/parser: inherit from data object instead of group object as composition has only a root layer.
Change-Id: I15f07d5d7ae2f8add4ac2b2de92628a33ab492e0
2018-08-16 02:42:56 +00:00
subhransu mohanty
12bad1cc4e lottie/render: keep mRle object in valid state after moving the object.
Change-Id: I15c377dc53dbe5b87184ca4751c3473f486a3121
2018-08-16 10:03:07 +09:00
subhransu mohanty
95d9dd1447 lottie/player: refactor composition class to keep a precomplayer instead of list of layers.
Change-Id: I7398392e52233e4c3d0452b03bcfd46261253601
2018-08-14 10:09:39 +00:00
subhransu mohanty
1c4bd6c966 lottie/example: delete the animator only when its created.
Change-Id: Id6a4a7e704a8da298c0cae91a7065b80163f843d
2018-08-14 10:08:33 +00:00
Hermet Park
e6b7dd8551 lottieplayer: fix broken animation.
A patch occured regression bug, because its depeneded patch was rebased.
call setPos() properly even in deferred method.

Change-Id: I89fa849304b6e5d260cc88c3863d8879c7bb463b
2018-08-14 18:57:00 +09:00