How to load a SVG image and render it scaled at high quality? #2911
-
|
Edit - I now realise that I'm seeing this problem on Mac and Linux but not Windows. I compared the results of loading an SVG file using the following two methods and there is a difference in quality on Windows and Mac/Linux when scaled. On Windows the SVG is crisp, but is blurry on Mac/Linux. It seems the only way to get a high quality SVG scaled image is to load it from file using a Image image1 = new Image(display, getClass().getResourceAsStream(imgPath));
Image image2 = new Image(display, imgPath);
GC gc = // GC passed from caller
gc.drawImage(image1, 0, 0, 300, 300); // scale the image larger
gc.drawImage(image2, 0, 400, 300, 300); // scale the image largerI'll open an issue soon. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
|
If I am not mistaken, this was turned into an actual issue and should be further discussed there? |
Beta Was this translation helpful? Give feedback.
-
Yes, that's right. This question was the beginning of my journey where I finally realised the problems were coming from differing implementations in So I'll close this one. |
Beta Was this translation helpful? Give feedback.
If I am not mistaken, this was turned into an actual issue and should be further discussed there?