1 sentence description of the problem: I was trying to upload an image for my game via the Files App, but for some odd reason, it turned out blurry (more blurry than usual, like it was uploaded at half the size and sized back up to 100% again). This is an issue because a lot of projects need their images to be a crisp as possible. At first I thought it was an odd width and height thing, but I soon realized it was much worse…
Steps to reproduce the problem every time, starting in a blank draft:
(If it is an existing project, include the link. And remove all code that is not related to the bug)
Place a set image block
Upload any (sharp) image from files (50 seeds / sub required)
Play the project
I expected this to happen: A sharp, crisp image
But instead this happened: A blurry image
Your username: Crosbyman64
Device type, player version & Hopscotch version: iPad13,8 (iPadOS 16.1), 2.1.3 (1.5.23 in screenshot example), Affected Versions: 3.57.0, 3.58.0, 3.59.0, 3.60.0, 3.62.0, 3.63.0, 3.64.0
(Or you can include a screenshot of your About page, in > About)
Image size: 86 x 118 pixels (43 x 59 units on Hopscotch)
The player version of the project I uploaded my image to was 1.5.23, but I can confirm this also happens on the latest player version as well. I can also confirm this happens with full screen images (2372 x 2048 pixels) as well.
I’m sure images are sized using the bilinear method, but to me, it seems that Hopscotch uploaded the image at 50% the intended size (and I don’t mean pixel to unit size), then resizes it back up to 100% size (which might (and I could be wrong) be how the large images showing smaller than intended got fixed… all it really needs is about 99% it’s original size, since images upload at their correct sizes up until the stage size).
Dealing with various image bugs there were some changes. Now uploading an image is done at a 1x scale consistently. Where previously it would depend on the device (the device’s screen scale, which could be 2x or 3x).
We also didn’t see any issue in Testflight which is interesting…
A temporary fix for this is to upload images at 2x or 3x, though I definitely think this method is inconvenient and not ideal.
(This was what the app was doing for images, just resizing them at 2x or 3x, before uploading to the server. But this method means that much larger upload files are going to the server every time, bigger than the user uploaded.
It should be the webplayer that handles resizing after getting images from the server, and we’re hoping to work on a fix for this but it might take a bit longer.)