Duplicated text document properties (fill color, stroke color, and stroke width) to the text range.
If these properties are not defined in the range selector, ThorVG incorrectly overrides them with default values.
The correct behavior is to preserve the original values. The added flags address this issue.
Co-Authored-By: Hermet Park<hermet@lottiefiles.com>
ThorVG cap/join enums and lottie specs were not aligned.
Problem was observed for StrokeCap::Square and StrokeJoin::Bevel.
Note: this change breaks backward comatibility.
usage) temporalWiggle(freq, amp, octaves=1, amp_mult=.5, t=time)
Samples the property at a wiggled time. The freq value is the frequency
in wiggles per second, amp is the amplitude in units of the property
to which it is applied, octaves is the number of octaves of noise
to add together, amp_mult is the amount that amp is multiplied by
for each octave, and t is the base start time. For this function
to be meaningful, the property it samples must be animated,
because the function alters only the time of sampling, not the value.
Note: need to verify this with a practical samples.
issue: https://github.com/thorvg/thorvg/issues/1640
Fixed a build error that occurred when the WebGPU feature was disabled due to a missing feature check condition. The issue affected building with the software and OpenGL only backends.
issue: #3356
This function sets the value of a specified expression variable within a particular layer.
It is useful for dynamically changing the properties of a layer at runtime.
Experimental API
- Result LottieAnimation::assign(const char* layer, uint32_t ix, const char* variable, float value)
- Tvg_Result tvg_lottie_animation_assign(Tvg_Animation* animation, const char* layer, uint32_t ix, const char* var, float val)
- modify the concept of AABB to apply only to transformed shapes.
- transform points before computing the bounding box min/max
to obtain a more compact shape region.
- trimmming memory by removing the cached matrix, about 36kb
of memory has been reduced per paint instance.
The Emscripten header was previously used because the WebGPU initialization logic was in WgContext::initialize.
Now, initialization occurs at the binding/application level.
added 2 more APIs for user convenience to allow backtracking tree traversal.
API Additions:
- const Paint* Paint::scene() const
- const Tvg_Paint* tvg_paint_get_scene(const Tvg_Paint* paint)