sw_engine: applied async rasterizing based on task scheduler.
authorHermet Park <chuneon.park@samsung.com>
Wed, 26 Aug 2020 07:39:10 +0000 (16:39 +0900)
committerHermet Park <chuneon.park@samsung.com>
Wed, 26 Aug 2020 07:39:10 +0000 (16:39 +0900)
commit858bb9b9f175c9acb64c92cfd6466e7dee61be8a
tree19a894c33f33c2622f1e3c8068efd44818c9050e
parentdd85eea19c6987389cee1b77302c6d491063eb8b
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
src/lib/sw_engine/tvgSwCommon.h
src/lib/sw_engine/tvgSwRenderer.cpp
src/lib/sw_engine/tvgSwRenderer.h
src/lib/tvgTaskScheduler.h