From e2fb03dbf3e3b1de8189362a0778acfc94350629 Mon Sep 17 00:00:00 2001 From: Leon Styhre Date: Sun, 21 Aug 2022 19:06:51 +0200 Subject: [PATCH] Fixed an issue where the tile property for the image element did not work correctly with SVG images. --- es-core/src/resources/TextureData.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/es-core/src/resources/TextureData.cpp b/es-core/src/resources/TextureData.cpp index 707e6911a..fbe240c44 100644 --- a/es-core/src/resources/TextureData.cpp +++ b/es-core/src/resources/TextureData.cpp @@ -71,6 +71,11 @@ bool TextureData::initSVGFromMemory(const std::string& fileData) bool rasterize {true}; + if (mTile) { + mSourceWidth = svgImage->width; + mSourceHeight = svgImage->height; + } + // If there is no image size defined yet, then don't rasterize unless mForceRasterization has // been set. if (mSourceWidth == 0.0f && mSourceHeight == 0.0f) {