Use the correct scale.
This commit is contained in:
parent
bccac9ef00
commit
845a445fb4
|
@ -75,10 +75,9 @@ void ImageLoaderSVG::create_image_from_string(Ref<Image> p_image, String p_strin
|
|||
return;
|
||||
}
|
||||
picture->viewbox(nullptr, nullptr, &fw, &fh);
|
||||
const float upscale = p_upsample ? 2.0 : 1.0;
|
||||
|
||||
uint32_t width = MIN(fw * p_scale * upscale, 16 * 1024);
|
||||
uint32_t height = MIN(fh * p_scale * upscale, 16 * 1024);
|
||||
uint32_t width = MIN(fw * p_scale, 16 * 1024);
|
||||
uint32_t height = MIN(fh * p_scale, 16 * 1024);
|
||||
picture->size(width, height);
|
||||
|
||||
std::unique_ptr<tvg::SwCanvas> sw_canvas = tvg::SwCanvas::gen();
|
||||
|
|
Loading…
Reference in a new issue