- Hue: Creates a result color with the luminance and saturation
of the base color and the hue of the blend color.
- Color: Creates a result color with the luminance of the base color
and the hue and saturation of the blend color. This preserves the gray
levels in the image and is useful for coloring monochrome images and
for tinting color images.
- Luminosity: reates a result color with the hue and saturation of the base color
and the luminance of the blend color. This mode creates the inverse effect of
Color mode.
- Saturation: Creates a result color with the luminance and hue of
the base color and the saturation of the blend color. Painting with this mode
in an area with no (0) saturation (gray) causes no change.
- HardMix: Adds the bottom & top. If the resulting sum for a channel is 255 or
greater, it receives a value of 255; if less than 255, a value of 0.
issue: https://github.com/thorvg/thorvg/issues/2701
Clarify the FillRule usage by associating it
explicitly with color/gradient fills.
C++ API
* Result Shape::fill(FillRule r)
-> Result Shape::fillRule(FillRule r)
issue: https://github.com/thorvg/thorvg/issues/3116
- introduced a blending factor to control the mix between the original color and the tritone effect.
- improved Lottie compliance with this enhancement.
- implemented the spec by all engines
CAPI:
* Tvg_Result tvg_scene_push_effect_tritone(Tvg_Paint* scene, int shadow_r, int shadow_g, int shadow_b, int midtone_r, int midtone_g, int midtone_b, int highlight_r, int highlight_g, int highlight_b);
-> TVG_API Tvg_Result tvg_scene_push_effect_tritone(Tvg_Paint* scene, int shadow_r, int shadow_g, int shadow_b, int midtone_r, int midtone_g, int midtone_b, int highlight_r, int highlight_g, int highlight_b, int blend);
Removed the paint parameter previously used to forcibly
update a single paint.
This behavior was unsafe in ThorVG, as a single paint
object may be connected to others through the scene graph.
Now, the canvas engine is responsible for properly updating
all damaged paints as needed, allowing the user to simply
call update() in any case.
API Modifications:
C++ API:
* Result Canvas::update(Paint* paint) -> Result Canvas::update()
CAPI:
- tvg_canvas_update_paint()
Issue: https://github.com/thorvg/thorvg/issues/3116
no any 3rd-party libs, such as glfw or glad did not used
support windows, linux, macos and emsdk
only the actually used set of functions are loaded
Co-Authored-By: Sergii Liebodkin <sergii@lottiefiles.com>
Co-Authored-BY: Hermet Park <hermet@lottiefiles.com>
issue: https://github.com/thorvg/thorvg/issues/2453
SDL + software engine doesn't need the vsync?
Observed the rendering performance is noticeably unstable on Intel Arc chipsets
with certain window sizes (ie 800x800) when VSync is enabled on software-rendered windows.
This might be a workaround, or it could be an issue with the driver or SDL.
Either way, the SDL + software engine doesn't need VSync.
Simplified parameters and ensured proper backend engine
initialization by using reference checking through canvas
instances.
C++ API Modification:
- Result Initializer::init(uint32_t threads, CanvasEngine engine)
-> Result Initializer::init(uint32_t threads)
- Result Initializer::term(CanvasEngine engine)
-> Result Initializer::term()
C API Modification:
- Tvg_Result tvg_engine_init(Tvg_Engine engine_method, unsigned threads)
-> Tvg_Result tvg_engine_init(unsigned threads);
- Tvg_Result tvg_engine_term(Tvg_Engine engine_method)
-> Tvg_Result tvg_engine_term()
issue: https://github.com/thorvg/thorvg/issues/3116
effect(name) / effect(index)
effects finds the effect by its name in the Effect Controls panel.
The name can be the default name or a user-defined name.
If multiple effects have the same name,
the effect closest to the top of the Effect Controls panel is used.
example:
- effect("Fast Blur")("Blurriness")
issue: https://github.com/thorvg/thorvg/issues/3115
If the svg contained an unsupported element with <stop> elements,
they were incorrectly assigned to the last loaded gradient. Now fixed.
@Issue: https://github.com/thorvg/thorvg/issues/3321