thorvg/src/lib
Hermet Park 100d98d82e common: Introduced Accessor for traversing the scene-tree.
Basically, this Accessor is a utility to debug the Scene structure,
by traversing the scene-tree by users.

You can search specific nodes to read the property information,
figure out the structure of the scene tree and its size.

We actually don't recommend you to touch the property unless you really
know the each paint's position and role because it's not visible, difficult to
understand its anatomy.

Also, You must underatnd that modifying the nodes of the scene will be going
well with both the art-design structure and the prorgram logic.

In this first version, Accessor only supports for the Picture class.

@example:

auto picture = tvg::Picture::gen();
picture->load("test.svg");

//The callback function from lambda expression.
//This function will be called for every paint nodes of the tree.
auto f = [](const tvg::Paint* paint) -> bool
{
    if (paint->identifier() == Shape::identifier()) {
        //override properties?
        uint8_t r, g, b, a;
        paint->fillColor(&r, &g, &b, &a);
        paint->fill(r / 2, g / 2, b / 2, a);
    }

    //You can return false, to stop traversing immediately.
    return true;
};

auto accessor = tvg::Accessor::gen();

picture = accessor->access(move(picture), f);

...

@Issue: https://github.com/Samsung/thorvg/issues/693
2021-12-23 11:54:44 +09:00
..
gl_engine sw_engine image: support non-premultiplied alpha images. 2021-12-02 17:10:12 +09:00
sw_engine sw_engine texmap: fix trivial compiler warnings. 2021-12-23 10:40:09 +09:00
meson.build common: Introduced Accessor for traversing the scene-tree. 2021-12-23 11:54:44 +09:00
tvgAccessor.cpp common: Introduced Accessor for traversing the scene-tree. 2021-12-23 11:54:44 +09:00
tvgArray.h common array: + exception handling. 2021-11-08 12:28:17 +09:00
tvgBezier.cpp common: preventing msvc compiler warnings (#817) 2021-09-20 13:54:06 +02:00
tvgBezier.h updated copyright 2021-03-23 14:31:58 +09:00
tvgBinaryDesc.h tvg_saver/tvg_loader: gradient fill in the tvg format 2021-11-02 19:37:02 +09:00
tvgCanvas.cpp common canvas: supplement corner cases. 2021-06-09 20:11:57 +09:00
tvgCanvasImpl.h common: code refactoring. 2021-10-01 14:53:56 +09:00
tvgCommon.h all: fix compilation errors on non-windows clang 2021-11-17 20:55:26 +09:00
tvgFill.cpp common: revise the identifier() implementation 2021-12-13 19:10:31 +09:00
tvgFill.h common: revise the identifier() implementation 2021-12-13 19:10:31 +09:00
tvgGlCanvas.cpp canvas: fix for SwCanvas Unit Test 2021-06-07 18:01:26 +09:00
tvgInitializer.cpp Revert "common: introduce iterator" 2021-12-23 11:29:58 +09:00
tvgIteratorAccessor.h common: code refactoring 2021-10-22 23:20:29 +09:00
tvgLinearGradient.cpp common: revise the identifier() implementation 2021-12-13 19:10:31 +09:00
tvgLoader.cpp common: code refactoring 2021-11-01 12:09:32 +09:00
tvgLoader.h loaders: Pass mimetype to picture::load 2021-08-05 11:02:26 +09:00
tvgLoadModule.h sw_engine image: support non-premultiplied alpha images. 2021-12-02 17:10:12 +09:00
tvgLzw.cpp Hide the thorvg LZW implementation. 2021-12-19 10:43:24 +09:00
tvgLzw.h tvg_format: newly introduced for tvg data compression. 2021-08-24 14:24:17 +09:00
tvgMath.h common math: code refactoring 2021-11-15 17:10:54 +09:00
tvgPaint.cpp sw_engine raster: fix a crash at the texmap clipping. 2021-12-17 19:15:27 +09:00
tvgPaint.h sw_engine raster: improve the transformed rle image rasterizer. 2021-12-14 19:04:16 +09:00
tvgPicture.cpp common picture: remove unused variable. 2021-12-13 19:46:09 +09:00
tvgPictureImpl.h common paint: code refactoring 2021-12-13 20:44:07 +09:00
tvgRadialGradient.cpp common: revise the identifier() implementation 2021-12-13 19:10:31 +09:00
tvgRender.cpp common math: code refactoring 2021-11-15 17:10:54 +09:00
tvgRender.h sw_engine raster: fix a crash at the texmap clipping. 2021-12-17 19:15:27 +09:00
tvgSaveModule.h common: code refactoring 2021-10-22 23:20:29 +09:00
tvgSaver.cpp tvg_saver: fix memory leaks 2021-11-09 20:15:06 +09:00
tvgScene.cpp common: revise the identifier() implementation 2021-12-13 19:10:31 +09:00
tvgSceneImpl.h common paint: code refactoring 2021-12-13 20:44:07 +09:00
tvgShape.cpp common: revise the identifier() implementation 2021-12-13 19:10:31 +09:00
tvgShapeImpl.h common paint: code refactoring 2021-12-13 20:44:07 +09:00
tvgSwCanvas.cpp canvas: fix for SwCanvas Unit Test 2021-06-07 18:01:26 +09:00
tvgTaskScheduler.cpp common taskScheduler: fix wrong thread indexing due to duplicated variable names. 2021-06-07 12:57:35 +09:00
tvgTaskScheduler.h updated copyright 2021-03-23 14:31:58 +09:00