platform/core/graphics/tizenvg.git
3 years agoMerge "tvgShape: fixed missing check in Shape::fill" into tizen
Hermet Park [Fri, 28 Aug 2020 05:03:38 +0000 (05:03 +0000)]
Merge "tvgShape: fixed missing check in Shape::fill" into tizen

3 years agosw_engine: + exceptional handling for safety
Hermet Park [Fri, 28 Aug 2020 02:28:59 +0000 (11:28 +0900)]
sw_engine: + exceptional handling for safety

Change-Id: I3ee6ca40590c5af5fd7243f419eaf96197ba757b

3 years agotvgShape: fixed missing check in Shape::fill 97/242397/1
Mateusz Palkowski [Wed, 26 Aug 2020 09:26:40 +0000 (11:26 +0200)]
tvgShape: fixed missing check in Shape::fill

Without this check, setting same fill twice results in crash later.

Change-Id: I38e7026c52a250f65923c4e3008868ed471bf885

3 years agosw_engine: applied async rasterizing based on task scheduler.
Hermet Park [Wed, 26 Aug 2020 07:39:10 +0000 (16:39 +0900)]
sw_engine: applied async rasterizing based on task scheduler.

Now, we have 2 points for asynchronous behaviors.

1. update shapes:

Each shape update will be performed by async when you push shape to canvas.
Meaning, if you have time gap between update and rendering in process main-loop,
you can have a benefit by this.

2. rasterization by canvas:

Canvas.draw() will be performed asynchnously until you call canvas.sync();
Meaing, if you can trigger tvg rendering eariler than composition time.
You can have a benefit by this.

If these 1, 2 points might not work for your program,
You can just toggle off async by setting threads number zero at initialization.

Or if you could apply either point of them for your program,
It might be good for performance.

But the best approach is to make both async properly.
Though this might need to fine-grained tuning integration between your program & tvg,
You could achieve the best peformance by parallelzing tasks as possible without any jobs delaying.

Change-Id: I04f9a61ebb426fd897624f5b24c83841737e6b5b

3 years agoSwRenderer: fixing unnecessary nesting in prepare() 36/242236/3
Mira Grudzinska [Mon, 24 Aug 2020 21:31:50 +0000 (23:31 +0200)]
SwRenderer: fixing unnecessary nesting in prepare()

Validating the above by adding shape/canvas update to testCapi.cpp

Change-Id: I7db8d014f4aff7b5b2884c2dca5af119329e9d43

3 years agosvg_loader: applied asynchronous threads tasks for optimal performance. 39/242039/6
Hermet Park [Fri, 21 Aug 2020 12:13:39 +0000 (21:13 +0900)]
svg_loader: applied asynchronous threads tasks for optimal performance.

Change-Id: I6575a6a6302c0ae52d1256a5f79f4c080002a4aa

3 years agotaskscheduler: initialize member correctly
Shinwoo Kim [Mon, 24 Aug 2020 08:06:26 +0000 (17:06 +0900)]
taskscheduler: initialize member correctly

This patch will fix runtime crash caused by incorrect init variables.

3 years agoUpdate README.md
Hermet Park [Mon, 24 Aug 2020 05:45:36 +0000 (14:45 +0900)]
Update README.md

update gitter channel address.

3 years agomeson: added compiler flags to optimize binary size 93/241993/1
Subhransu Mohanty [Fri, 21 Aug 2020 07:53:56 +0000 (16:53 +0900)]
meson: added compiler flags to optimize binary size

this reduced library size from 153KB to 119KB.

Change-Id: Ie70e5412b42d864fbaa827eec21b3cbc1e8f26af

3 years agocommon initializer: don't try initialize engine duplicatedly. 64/241964/1 accepted/tizen/unified/20200824.134426 submit/tizen/20200823.213148
Hermet Park [Fri, 21 Aug 2020 06:56:04 +0000 (15:56 +0900)]
common initializer: don't try initialize engine duplicatedly.

Change-Id: I58c715745b8db40fe759582545082f2e6e10626a

3 years agocommon taskscheduler: revise functionalities. 48/241448/10
Hermet Park [Thu, 20 Aug 2020 08:04:32 +0000 (17:04 +0900)]
common taskscheduler: revise functionalities.

initialization interfaces has been changed for threads count.

if you want to set concrete threads count by system, please specify thread count with it.

std threads:
tvg::Initializer::init(tvg::CanvasEngine::Sw, std::thread::hardware_concurrency());

if your system provides designed threads info, you can use it.

efl:
tvg_engine_init(TVG_ENGINE_SW, eina_cpu_count());

I recommend to avoid max threads usage for better performance.

Change-Id: I22cfa315768f73fa941be136956cdbb2cf837c20

3 years agoupdated AUTHORS
Hermet Park [Thu, 20 Aug 2020 08:52:11 +0000 (17:52 +0900)]
updated AUTHORS

Change-Id: Ie0bb862f8ba20e682bf3bb7469455fa52a5d5498

3 years agosvg path: changes in processing cmds T,Q,S 67/240567/4
Mira Grudzinska [Sun, 16 Aug 2020 13:23:42 +0000 (15:23 +0200)]
svg path: changes in processing cmds T,Q,S

Change-Id: I979bb8cbcbdd4fd1374205feac6acedc58bdd3e1

3 years agoMerge "tvg: added task support that runs on a threadpool." into tizen
Hermet Park [Thu, 20 Aug 2020 08:02:07 +0000 (08:02 +0000)]
Merge "tvg: added task support that runs on a  threadpool." into tizen

3 years agocode refactoring 40/241440/1
Hermet Park [Thu, 20 Aug 2020 07:16:46 +0000 (16:16 +0900)]
code refactoring

remove unnecessary condition.
implementation won't be included multiple times not like headers.

Thus this condition is unnecessary.

Change-Id: Id37e675c40ce7213a06c950da8e5ca17ff7245c9

3 years agosw_engine: fix loss of data when it's converting. 14/241414/1
Hermet Park [Thu, 20 Aug 2020 03:18:51 +0000 (12:18 +0900)]
sw_engine: fix loss of data when it's converting.

if SwCoord type is determined to 4byte,
it could lose remarkable value that occur stroking jiggling.

This fixes the issue.

Change-Id: Ib2fed2a3bfc9188a30522f35837439364d446a73

3 years agosw_engine: replace rgba8888 with abgr8888 46/241346/4
Hermet Park [Wed, 19 Aug 2020 09:32:32 +0000 (18:32 +0900)]
sw_engine: replace rgba8888 with abgr8888

Actually Dali rendering system requires abgr8888.

We could add more colorspaces if it's necessary.

Change-Id: Ia42a6575d1313629e55efc3077e302992c47b6c0

3 years agocode refactoring 03/241303/2
Hermet Park [Wed, 19 Aug 2020 05:50:49 +0000 (14:50 +0900)]
code refactoring

Now, stabilizing is pretty enough.

Remove assert code so that we never abort process in any cases.
This also reduce the binary size.

Change-Id: Ia7d2d5c5a0757b12481eaebad7a86aade6a89c1e

3 years agoremove print/cout logs. 96/241196/1
Hermet Park [Tue, 18 Aug 2020 11:35:13 +0000 (20:35 +0900)]
remove print/cout logs.

we need a comprehensive logging interface for this.

right now, leave as "LOG:" to replace later.

Change-Id: I25321223cd48ec13a1de5e4140cfea75a2f42866

3 years agosw_engine: code refactoring 95/241195/3
Hermet Park [Tue, 18 Aug 2020 11:19:31 +0000 (20:19 +0900)]
sw_engine: code refactoring

introduce compositor table for runtime colorspace switching.

Change-Id: If179d1e1625f995e114d66cf1bf13742c54ed4f7

3 years agosw_engine: convert colorspace ARGB -> RGBA in default. 12/241112/5
Hermet Park [Sat, 15 Aug 2020 07:29:46 +0000 (16:29 +0900)]
sw_engine: convert colorspace ARGB -> RGBA in default.

We can use RGBA colorspace rather ARGB for pixel data.
This would be better for many rendering system,
since it's more widely preferred than ARGB including opengl.

Change-Id: Ibbfe6a511d77bf0ef30ce261995467c11164d306

3 years agopicture svg: introduce load() with memory data input source. 86/241086/2 accepted/tizen/unified/20200820.034622 submit/tizen/20200817.223215
Hermet Park [Fri, 14 Aug 2020 10:35:39 +0000 (19:35 +0900)]
picture svg: introduce load() with memory data input source.

picture now affords the memory data as input source so that
user can pass svg data memory directly.

Change-Id: I246c09b682a2d60e53ad556ce0c90337142ee4f1

3 years agocommon initializer: introduce thread count api. 79/241079/2
Hermet Park [Fri, 14 Aug 2020 09:51:38 +0000 (18:51 +0900)]
common initializer: introduce thread count api.

this interface controls the number of threads working behind.

default is 0 == only syncrhonous.

Change-Id: I8404f33359e6213acc5e578061568fede50cd9a6

3 years agoloader svg: code refactoring. 78/241078/2
Hermet Park [Fri, 14 Aug 2020 09:47:03 +0000 (18:47 +0900)]
loader svg: code refactoring.

renamed svg loader path.

Change-Id: I0219721540ea981d15d17b9571c1ee9b37651fb8

3 years agodisable gl_engine in default. 75/241075/1
Hermet Park [Fri, 14 Aug 2020 08:44:17 +0000 (17:44 +0900)]
disable gl_engine in default.

We don't include gl compile before it works properly.

For development & test please turn it on in meson_option.txt locally.

Change-Id: I2ff8b06f8e1b496922f70ec580662e8886a9b93d

3 years agoremove std async usage. 04/241004/11
Hermet Park [Thu, 13 Aug 2020 11:39:34 +0000 (20:39 +0900)]
remove std async usage.

we can't control any threads count that could drop the performance.

remove async() and will come back with fine-tuned threading-pool.

Change-Id: I17c39792234acfce6db334abc0ce12da23978a9a

3 years agotvg: added task support that runs on a threadpool. 39/240939/2
Subhransu Mohanty [Thu, 13 Aug 2020 04:01:53 +0000 (13:01 +0900)]
tvg: added task support that runs on a  threadpool.

this patch adds an async() function that takes a shared_task
and runs asyncronously in a threadpool.

Change-Id: I02a47df6938656828f924fbf5e2bc075073b329b

3 years agocommon: code refactoring. 99/240999/1 submit/tizen/20200813.110752
Hermet Park [Thu, 13 Aug 2020 11:05:37 +0000 (20:05 +0900)]
common: code refactoring.

we can return nullptr directly here.

Change-Id: Ic1d987f2701d20ff1b69af2854f9cfee7e2fe065

3 years agogl_engine: engine should return shape data for resuing it. 96/240996/2
Hermet Park [Thu, 13 Aug 2020 10:59:01 +0000 (19:59 +0900)]
gl_engine: engine should return shape data for resuing it.

Change-Id: I45f7ecbdb707b0751894e01d273b149402e089af

3 years agosw_engine: fix potential data overflow. 95/240995/1
Hermet Park [Thu, 13 Aug 2020 10:50:46 +0000 (19:50 +0900)]
sw_engine: fix potential data overflow.

Change-Id: Ie800fda74d44ad3741f7a92f12681f7f753ee50c

3 years agosvg_loader: free allocated data properly. 91/240991/2
Hermet Park [Thu, 13 Aug 2020 10:41:34 +0000 (19:41 +0900)]
svg_loader: free allocated data properly.

also renamed internal function for consistency.

createNode()
cloneNode()
freeSVGNode() ?

Change-Id: Ie9b22e92d5e918e947f8476ad0d4682fc7a3be65

3 years agosw_engine: remove unnecessary assert() call 87/240987/1
Hermet Park [Thu, 13 Aug 2020 10:29:23 +0000 (19:29 +0900)]
sw_engine: remove unnecessary assert() call

Change-Id: I8cb249b6b7f32992f7ce9c86e408546c14856330

3 years agosw_engine: fix data overflow case. 86/240986/1
Hermet Park [Thu, 13 Aug 2020 10:27:02 +0000 (19:27 +0900)]
sw_engine: fix data overflow case.

Change-Id: I01f90a8a6b3bca38142c8c16d1990b5b1a09d081

3 years agosw_engine renderer: initialize member data in default. 84/240984/1
Hermet Park [Thu, 13 Aug 2020 10:15:33 +0000 (19:15 +0900)]
sw_engine renderer: initialize member data in default.

static analizyer bothers us due to this.
we'd rather initialize members for free of them.

Change-Id: I23b769b94be7514a8bf6e6d683ddb90b3cd613c4

3 years agocommon: code refactoring. 83/240983/1
Hermet Park [Thu, 13 Aug 2020 10:13:17 +0000 (19:13 +0900)]
common: code refactoring.

we can return nullptr directly here.

Change-Id: I35e04dc9850b3b3b75e1e02b4c81a61b79f2c43f

3 years agosvg_loader: initialize member data in default. 82/240982/2
Hermet Park [Thu, 13 Aug 2020 10:08:34 +0000 (19:08 +0900)]
svg_loader: initialize member data in default.

static analizyer bothers us due to this.
we'd rather initialize members for free of them.

Change-Id: I6dd76427b0fe2f9ff09034fe3ab11080a8d72a2e

3 years agogl_engine renderer: initialize member data in default. 79/240979/1
Hermet Park [Thu, 13 Aug 2020 10:02:31 +0000 (19:02 +0900)]
gl_engine renderer: initialize member data in default.

static analizyer bothers us due to this.
we'd rather initialize members for free of them.

Change-Id: Ifa6ebffdfdcb31d2dd3a1d6b911226928f654e3f

3 years agosw_engine: remove unnecessary assert() call 78/240978/1
Hermet Park [Thu, 13 Aug 2020 10:00:09 +0000 (19:00 +0900)]
sw_engine: remove unnecessary assert() call

Change-Id: I7c665bab4ef867f912ea738480e6d9b2b63e014e

3 years agocommon_shape: fixed arc api to draw rectangles lower than 0. 79/240779/2
Michal Szczecinski [Tue, 11 Aug 2020 10:11:06 +0000 (12:11 +0200)]
common_shape: fixed arc api to draw rectangles lower than 0.

Absolute value is used to calculate number of bezier curves used
to approximate arc.

Change-Id: Idedd7fd73590d569417fc646fc7febdaaab65857

3 years agoreplace license from Apache 2.0 to MIT 65/240965/2
Hermet Park [Thu, 13 Aug 2020 07:50:32 +0000 (16:50 +0900)]
replace license from Apache 2.0 to MIT

Change-Id: I61f7cb2b0e407bc035f3b2ec7da9b7f230057e24

3 years agosw_engine: fix one last compile warning. 65/240465/1 accepted/tizen/unified/20200810.123122 submit/tizen/20200809.214919
Hermet Park [Thu, 6 Aug 2020 11:17:34 +0000 (20:17 +0900)]
sw_engine: fix one last compile warning.

casting to loss data in converting data type.

Change-Id: I4c9b45b1c015579807a2d44e0ff2734bd2f655f3

3 years agosvg_loader: fix compile warnings. 64/240464/1
Hermet Park [Thu, 6 Aug 2020 11:09:15 +0000 (20:09 +0900)]
svg_loader: fix compile warnings.

-- warning: moving a local object in a return statement prevents copy elision [-Wpessimizing-move]

Change-Id: I7dec55fe117d27217b7a29d5983b23cedadacb71

3 years agocommon: fix compiler warnings that loss data by mis-matched converision 63/240463/5
Hermet Park [Thu, 6 Aug 2020 10:50:44 +0000 (19:50 +0900)]
common: fix compiler warnings that loss data by mis-matched converision

these conversions are intented, we explicity use casting so that compiler doesn't
catch them anymore.

Change-Id: I9d905c7562c43929b040d034e5ee0d14c6750a80

3 years agocapi: Added C wrapper for setting spread type 04/240204/5
Mateusz Palkowski [Tue, 4 Aug 2020 10:11:24 +0000 (12:11 +0200)]
capi: Added C wrapper for setting spread type
and test

Change-Id: I3b4cd3740a82446fea60ed050814b03f32632f6d

3 years agofix compile warnings 37/240437/1
Hermet Park [Thu, 6 Aug 2020 08:06:36 +0000 (17:06 +0900)]
fix compile warnings

comparison of unsigned expression < 0 is always false [-Werror=type-limits]

Change-Id: I8cee625056bcde1f2a3cb2b9ce704b33be5bd725

3 years agogl_engine: fix compile warnings 31/240431/1
Hermet Park [Thu, 6 Aug 2020 07:57:38 +0000 (16:57 +0900)]
gl_engine: fix compile warnings

this statement may fall through [-Werror=implicit-fallthrough=]

Change-Id: I3cfc9b51697e229a524f6f75e10b83715b06ce13

3 years agosvg_loader: fix compile warnings. 25/240425/2
Hermet Park [Thu, 6 Aug 2020 07:50:59 +0000 (16:50 +0900)]
svg_loader: fix compile warnings.

--warning: extra Ã¢^`^x;â^`^y [-Wpedantic]

Change-Id: Ib40079628cac3fff6d991fd05d7d8073dd350361

3 years agocommon: fix compile warnings. 23/240423/3
Hermet Park [Thu, 6 Aug 2020 07:38:12 +0000 (16:38 +0900)]
common: fix compile warnings.

--Werror=unused-parameter

Change-Id: If4c04e3e20b67be62b50c3b1e2e909dbd848eccc

3 years agocommon: fix compile warnings. 20/240420/1
Hermet Park [Thu, 6 Aug 2020 07:24:24 +0000 (16:24 +0900)]
common: fix compile warnings.

--Werror=unused-parameter

Change-Id: I180464d770b1aa04afd39c30a3223a7cd48c78a4

3 years agosvg_loader: code refactoring.
Hermet Park [Thu, 6 Aug 2020 05:35:56 +0000 (14:35 +0900)]
svg_loader: code refactoring.

++neat

Change-Id: I3b5552a2bbf09571ba01f0e31569b553913f400d

3 years agosvg_loader: fix build error 02/240402/2
Shinwoo Kim [Thu, 6 Aug 2020 05:31:08 +0000 (14:31 +0900)]
svg_loader: fix build error

This patch is solving following build error.

   error: â€˜offsetof’ was not declared in this scope

Depending on build environment, this error could happen.

Change-Id: I3512bb205f79a4d893cf33266db0a9109c0df886

3 years agosvg_loader: code refactoring 99/240399/3
Hermet Park [Thu, 6 Aug 2020 05:19:50 +0000 (14:19 +0900)]
svg_loader: code refactoring

remove macro code that does not helpful.

This just decrease readibility and increase LOC.

Change-Id: I9f1b11318447b45a9f96e7b00c18141fd9e71f9a

3 years agocommon: changed premultiplied color policy. 95/240395/2
Hermet Park [Thu, 6 Aug 2020 04:53:00 +0000 (13:53 +0900)]
common: changed premultiplied color policy.

Some user have no idea of premultiplied alpha concept,
We suggest more user-friendly interfaces so that they don't confuse it.

Now, this pre-multipying is acommplished by backend engines.

Change-Id: Ifd84d56361cb56a8b98240bbd16690accf370bad

3 years agoupdated README 33/240333/1 accepted/tizen/unified/20200806.062539 submit/tizen/20200806.023659
Hermet Park [Wed, 5 Aug 2020 11:08:27 +0000 (20:08 +0900)]
updated README

prepare for github system.

Change-Id: I0ee45e3ccb56f25f0252aad91a48151d62f9ed02

3 years agotest arc: revise sample code.
Hermet Park [Tue, 4 Aug 2020 00:57:37 +0000 (09:57 +0900)]
test arc: revise sample code.

Change-Id: I3629befdf5ce74ae7822929a059b4c95f2a9e88e

3 years agoMerge "spec: Add spec for rpm packaging" into tizen
Hermet Park [Tue, 4 Aug 2020 00:42:47 +0000 (00:42 +0000)]
Merge "spec: Add spec for rpm packaging" into tizen

3 years agocapi: revise some common paint interfaces and added picture stuff. 29/240129/1
Hermet Park [Tue, 4 Aug 2020 00:37:08 +0000 (09:37 +0900)]
capi: revise some common paint interfaces and added picture stuff.

Change-Id: I9850cbead5ce1ab172f284738fe8456cd19dc3f9

3 years agocommon: code refactoring.
Hermet Park [Mon, 3 Aug 2020 11:06:02 +0000 (20:06 +0900)]
common: code refactoring.

return as soon as possible.

Change-Id: If48e13e8976bc1692dadd9054b484bf7cd811917

3 years agocommon shape: support pie filling from arc. 07/240107/1
Hermet Park [Mon, 3 Aug 2020 10:58:12 +0000 (19:58 +0900)]
common shape: support pie filling from arc.

last argument pie=true makes arc to pie shape.

Change-Id: I6f22d00fed77bf728a4ff6e5f1ca42f476ac1664

3 years agoMerge "common shape: added arc implementation" into tizen
Hermet Park [Mon, 3 Aug 2020 09:50:52 +0000 (09:50 +0000)]
Merge "common shape: added arc implementation" into tizen

3 years agocommon shape: added arc implementation 89/239989/4
Michal Szczecinski [Fri, 31 Jul 2020 09:07:53 +0000 (11:07 +0200)]
common shape: added arc implementation

Change-Id: Ib483e24d8e358b2860ca8d46e8b88d58d12bdb62

3 years agospec: Add spec for rpm packaging 43/238643/8
JunsuChoi [Thu, 16 Jul 2020 04:15:58 +0000 (13:15 +0900)]
spec: Add spec for rpm packaging

Change-Id: I33a7d7e03549860c122eb56534f492a48784533e

3 years agocapi: Added C wrappers for gradient func 93/239993/1
Mateusz Palkowski [Fri, 31 Jul 2020 09:34:49 +0000 (11:34 +0200)]
capi: Added C wrappers for gradient func

Change-Id: If41dab9b06f6cec2831ea1361f30b50a193e99c4

3 years agotest: updated svg sample 10/239910/2
Hermet Park [Thu, 30 Jul 2020 11:40:12 +0000 (20:40 +0900)]
test: updated svg sample

also revise size() method of Picture for proper aligning.

Change-Id: I58a0886968f6058e65a062477e2a873224d8ea8f

3 years agocommon: code refactoring 95/239895/4
Hermet Park [Thu, 30 Jul 2020 10:17:55 +0000 (19:17 +0900)]
common: code refactoring

remove duplicated code among the Paint types.

Change-Id: Ia7c09f29531e6aef73d2ba1f951f8dfdf488deb8

3 years agocommon picture: introduce picture feature which is for vector file extensions. 69/239869/5
Hermet Park [Thu, 30 Jul 2020 07:50:29 +0000 (16:50 +0900)]
common picture: introduce picture feature which is for vector file extensions.

Now Scene is only specialized for composition of Paint objects.

Change-Id: I16426913f029c89e9f9ac4d5e0afed11d1a228d0

3 years agocommon: code refactoring. 39/239839/2
Hermet Park [Thu, 30 Jul 2020 06:10:59 +0000 (15:10 +0900)]
common: code refactoring.

changed just internal variable & method names.

no logical changes.

Change-Id: I01782ec59dec3ff2232e03de7b3863100d9cc27f

3 years agocommon: code refactoring for simplicity. 33/239833/3
Hermet Park [Thu, 30 Jul 2020 05:47:04 +0000 (14:47 +0900)]
common: code refactoring for simplicity.

Introduce internal PaintMethod since there more derived paint classes are coming.

This PaintMethod is a sort of Strategy Pattern method.

Change-Id: I29c49f5d4ddbfb9e429d4976636b20b39914ee20

3 years agoMerge "capi: Added wrapper for tvg::Shape::transform (fixed)" into tizen
Hermet Park [Thu, 30 Jul 2020 04:47:31 +0000 (04:47 +0000)]
Merge "capi: Added wrapper for tvg::Shape::transform (fixed)" into tizen

3 years agocommon: revise canvas interfaces. 04/239804/2
Hermet Park [Thu, 30 Jul 2020 04:40:18 +0000 (13:40 +0900)]
common: revise canvas interfaces.

1. removed async option which doesn't work currently,
rather than it, we can add async option in initiailizer class.

2. removed update() method.
Instead, we can call update(paint = nullptr); which has exactly same behavior.

Change-Id: I7909a50d804b97baf413a2ff6365a3cf79a3689e

3 years agocommon: code refactoring 60/239760/3
Hermet Park [Wed, 29 Jul 2020 11:41:34 +0000 (20:41 +0900)]
common: code refactoring

keep consistency of internal functions among the paint type methods.

Change-Id: I98a42ac398ddc5aaf49ac59e5cbb1790266bd612

3 years agocommon: code refactoring 46/239746/2
Hermet Park [Wed, 29 Jul 2020 10:47:28 +0000 (19:47 +0900)]
common: code refactoring

remove exceptional handling which is inevitable scenario.

Change-Id: I761a59a38f4578291ee8bc044c5ca989feedbe79

3 years agocapi: Added wrapper 42/239742/1
Mateusz Palkowski [Wed, 29 Jul 2020 10:23:18 +0000 (12:23 +0200)]
capi: Added wrapper
for tvg::Shape::transform (fixed)

Change-Id: Ibbb867e828a07af90f38ed506894d026004fa53d

3 years agocommon: revise transform interfaces. 99/239699/4
Hermet Park [Wed, 29 Jul 2020 05:25:18 +0000 (14:25 +0900)]
common: revise transform interfaces.

transform interfaces are getting duplicated in derived classes.

we moved to the super for smaller apis count.

Applied strategy pattern to hide the inheritance.

Change-Id: I7b0c3ff9317e9bf3c97bb0c849bf55e79ee9a591

3 years agosw_engine: fix out of cell memory. 93/239693/1
Hermet Park [Wed, 29 Jul 2020 04:40:11 +0000 (13:40 +0900)]
sw_engine: fix out of cell memory.

we can adjust cell size if the cell memory is out.
the main rle logic missed the exception handling.

Change-Id: I4419eefefccafd788729111eafeb65aa4e6a20e9

3 years agogl_engine: updated file permission.
Hermet Park [Tue, 28 Jul 2020 11:57:18 +0000 (20:57 +0900)]
gl_engine: updated file permission.

please keep 664 for files.

Change-Id: Iaddd87b0d35a74bc8c6cbf330fecbd28e14ad57a

3 years agoupdated AUTHORS
Hermet Park [Tue, 28 Jul 2020 11:46:11 +0000 (20:46 +0900)]
updated AUTHORS

Change-Id: Ia3b91f2dff139b80c5e968be2a0ecb725e6b62bd

3 years agocapi: Added wrapper for tvg::Shape::translate 53/239553/1
Mateusz Palkowski [Mon, 27 Jul 2020 12:08:51 +0000 (14:08 +0200)]
capi: Added wrapper for tvg::Shape::translate

Change-Id: Idcf672926c489148f15c654f85b4d6c3ff8cde80

3 years agocapi: Added wrapper for tvg::Shape::rotate 52/239552/1
Mateusz Palkowski [Mon, 27 Jul 2020 12:08:01 +0000 (14:08 +0200)]
capi: Added wrapper for tvg::Shape::rotate

Change-Id: I2cef6600586c037caaf8d2f45fc6d78e93dce925

3 years agocapi: Added wrapper for tvg::Shape::scale 51/239551/1
Mateusz Palkowski [Mon, 27 Jul 2020 12:07:03 +0000 (14:07 +0200)]
capi: Added wrapper for tvg::Shape::scale

Change-Id: Ie8380478d9e5bf99c924f3b93cfbb3d80ff55611

3 years agosw_engine gradient: support x/y scale for linear gradient 24/239424/1
Hermet Park [Fri, 24 Jul 2020 12:09:24 +0000 (21:09 +0900)]
sw_engine gradient: support x/y scale for linear gradient

Change-Id: Ic58e7cc61a3c90307b6cfb629eb8af69b75fb903

3 years agosw_engine gradient: support x/y scale for radial gradient 98/239298/5
Hermet Park [Thu, 23 Jul 2020 11:56:05 +0000 (20:56 +0900)]
sw_engine gradient: support x/y scale for radial gradient

Change-Id: Id725637e261642d0e92d100c73841278b7f44c1c

3 years agosw_engine: revise stroke scaling logic. 20/239320/1
Hermet Park [Fri, 24 Jul 2020 02:03:20 +0000 (11:03 +0900)]
sw_engine: revise stroke scaling logic.

previous fast track logic is useless,
it actually doesn't helpful for performance, just increase the code complexity.

Change-Id: Ib6ad204edfb241d74c41413dfec7ab42fb02af81

3 years agosw_engine: support bidirectional stroke scaling. 07/239207/10
Hermet Park [Wed, 22 Jul 2020 11:31:57 +0000 (20:31 +0900)]
sw_engine: support bidirectional stroke scaling.

if the transform scale factor for x/y is not identical,
it keeps its both xy scale factor then apply them
for stroking calculation.

Change-Id: I519dfce3ce7b4a12c13da1801d6a00e139e7400f

3 years agoSvgLoader: Fix opacity propagation 26/239226/2
JunsuChoi [Thu, 23 Jul 2020 01:14:46 +0000 (10:14 +0900)]
SvgLoader: Fix opacity propagation

Remove duplicate opacity calculation of the scene.

Change-Id: I1253ea290e78fdbf946a492ebfcaaa082fbfc121

3 years agosw_engine: revise scale transform logic. 74/239074/5
Hermet Park [Tue, 21 Jul 2020 11:24:25 +0000 (20:24 +0900)]
sw_engine: revise scale transform logic.

Basically, stroke width size is linear,

engine couldn't apply scale factor from the matrix which contains 2 dimensional values.

Thus, we can apply it if the scale factor of x/y is identical.

Otherwise, we should transform every stroke points in the stroking process.
That scenario can be improved with another patch.

Change-Id: I070dcf29d2e42f21e182bdf4239781464158ef73

3 years agocomon: code refactoring 82/239182/1
Hermet Park [Wed, 22 Jul 2020 09:45:11 +0000 (18:45 +0900)]
comon: code refactoring

renamed internal variable for better readibility.

Change-Id: I07dc66c4bd63f2aec8036aab14ec3ed608820fbc

3 years agosw_engine: revise outline transform 37/239037/3
Hermet Park [Tue, 21 Jul 2020 08:18:48 +0000 (17:18 +0900)]
sw_engine: revise outline transform

sw_engine simulates floating point by integer bit shifting,
it loses the accuracy while converting the number data.

This occurs the inacculated curve points result if it scales up very large size.

So we transform points before converting data in order to avoid losing the numbers less decimal point.

Change-Id: I0172e83f06b1a19143a2f65f667dc193e9a4396a

3 years agoSvgLoader: Support display=none feature 71/238971/3
JunsuChoi [Tue, 21 Jul 2020 01:42:22 +0000 (10:42 +0900)]
SvgLoader: Support display=none feature

If display is none, scene does not create a child shape,
and shape does not draw fills and strokes.

Change-Id: I8af72c904be00107dff115429e27df7ba4cb83b6

3 years agotest: replaced svg resources.
Hermet Park [Mon, 20 Jul 2020 02:44:32 +0000 (11:44 +0900)]
test: replaced svg resources.

Change-Id: I30ab48ecc0bbae158baecce1f6173fc36ecfbbb6

3 years agocommon transformation: fix transformation multiply 16/238716/7
Hermet Park [Thu, 16 Jul 2020 11:42:42 +0000 (20:42 +0900)]
common transformation: fix transformation multiply

Change-Id: Ibc95fab0abfc07aa7f0c4ff6c74785d4f73d02c7

3 years agotest: ++code safety 80/238780/1
Hermet Park [Fri, 17 Jul 2020 08:15:16 +0000 (17:15 +0900)]
test: ++code safety

added null check for exceptional case.

Change-Id: I12a5e9724149f607188b67a84e46a033a16270f7

3 years agotest: changed file permission.
Hermet Park [Fri, 17 Jul 2020 07:57:02 +0000 (16:57 +0900)]
test: changed file permission.

Change-Id: I8172152f700d10fa1d8c84473d45ff484c0b36d8

3 years agoupdated AUTHORS
Hermet Park [Fri, 17 Jul 2020 07:56:05 +0000 (16:56 +0900)]
updated AUTHORS

Change-Id: If9412e0598bdfa59dc142aacaec1cb5ae3f5401d

3 years agogl_engine: Fix crash in animation callback. Refactor test samples draw function.... 20/238620/5
Pranay Kumar Samanta [Wed, 15 Jul 2020 13:32:27 +0000 (19:02 +0530)]
gl_engine: Fix crash in animation callback. Refactor test samples draw function. Fix open shape drawing.

Change-Id: I9ca2cb3951f2229f36292b69221451e0eaf5b6a1

3 years agosvg_loader: code refactoring. 91/238691/1
Hermet Park [Thu, 16 Jul 2020 08:17:16 +0000 (17:17 +0900)]
svg_loader: code refactoring.

leave to shape to handle non-effective values.

Change-Id: I4193653710498e0ea31b0ff88fd8f0f8f0238e0e

3 years agosvg_loader: code refactoring 89/238689/2
Hermet Park [Thu, 16 Jul 2020 08:09:48 +0000 (17:09 +0900)]
svg_loader: code refactoring

keep clean & neat code.

Change-Id: Ia17139a291fc9934fe2f8d5e51417c44ec50f2ed

3 years agosvg_loader: optimize data delivery. 88/238688/1
Hermet Park [Thu, 16 Jul 2020 08:03:44 +0000 (17:03 +0900)]
svg_loader: optimize data delivery.

We know how this shape is passed,
so don't use unique_ptr to save data size.

Change-Id: I02410692199b9cee701c206246ceea5988d06726

3 years agotest: Fix typo in makefile 59/238659/1
JunsuChoi [Thu, 16 Jul 2020 05:58:35 +0000 (14:58 +0900)]
test: Fix typo in makefile

' -> `

Change-Id: Iafacfb78d8f788ef302e5ad7f1a1d9cfbd380ffb

3 years agosw_engine: fix wrong gradient fill transform. 49/238649/1
Hermet Park [Thu, 16 Jul 2020 04:45:27 +0000 (13:45 +0900)]
sw_engine: fix wrong gradient fill transform.

it missed the offset when transformed gradient positions.

now it's fixed.

Change-Id: I916bd88b40bc29ca57d31411b92e10fe357d720e