mirror of
https://github.com/thorvg/thorvg.git
synced 2025-06-15 04:24:28 +00:00
sw_engine raster: fix a regression bug.
Picture example were broken by 90fa26b7bb
the correct condition must be like this change.
This commit is contained in:
parent
90fa26b7bb
commit
440cc81b4d
1 changed files with 6 additions and 4 deletions
|
@ -500,8 +500,9 @@ static bool _scaledRleRGBAImage(SwSurface* surface, const SwImage* image, const
|
||||||
{
|
{
|
||||||
Matrix itransform;
|
Matrix itransform;
|
||||||
|
|
||||||
if (transform && !mathInverse(transform, &itransform)) return false;
|
if (transform) {
|
||||||
else mathIdentity(&itransform);
|
if (!mathInverse(transform, &itransform)) return false;
|
||||||
|
} else mathIdentity(&itransform);
|
||||||
|
|
||||||
auto halfScale = _halfScale(image->scale);
|
auto halfScale = _halfScale(image->scale);
|
||||||
|
|
||||||
|
@ -847,8 +848,9 @@ static bool _scaledRGBAImage(SwSurface* surface, const SwImage* image, const Mat
|
||||||
{
|
{
|
||||||
Matrix itransform;
|
Matrix itransform;
|
||||||
|
|
||||||
if (transform && !mathInverse(transform, &itransform)) return false;
|
if (transform) {
|
||||||
else mathIdentity(&itransform);
|
if (!mathInverse(transform, &itransform)) return false;
|
||||||
|
} else mathIdentity(&itransform);
|
||||||
|
|
||||||
auto halfScale = _halfScale(image->scale);
|
auto halfScale = _halfScale(image->scale);
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue