Hello again!
I'm faced with a problem that I have encountered previously in Renpy, regarding the scaling of images. I have attached four images to this message to demonstrate the issue.
For my demonstration, I am using a mock desktop consisting of a background image (the wallpaper) and placeholder icons (a white square with a 1 pixel black outline).
If I have the game set to 1280x720 (via config.screen_width and config.screen_height) and I have icons (or other images) appropriately scaled in their files (IE, the placeholder icon being 65x65 with a 1 pixel outline OR having an 1280x720 image containing the five icons in the right places over a transparent layer), then the game looks great when windowed (attachment 1). However, if I swap to fullscreen, then the icons are inconsistently blurry; some of the icon outlines are 1 pixel across, others are two or three pixels across with varying opacity (attachment 2).
If I have the game set to 1920x1080p and the icons appropriately scaled (as before, but each placeholder icon is now 100x100 with a 1 pixel outline), then the game looks great in 1080p fullscreen (attachment 3). However, in the default windowed mode of 1280x720, the icons have the exact same problem as before: the outlines are inconsistent widths, some sharp, some blurry (attachment 4).
I've done some digging around on the forums and gone through the online documentation, but I can't seem to find a solution for this problem or much of a reference to it. As it stands, I want all the images in the game (which are PNG for quality reasons) to look great whether the game is windowed or full-screen; to have one of those modes have poor-quality icons would look really amateur. The only solution I can think of myself is to disable fullscreen OR windowed mode, thus forcing players to play the game at a resolution where the graphics WOULD look good, but this seems like it wouldn't be very considerate for players (particularly those who may need to have fullscreen as an option due to eyesight problems).
I really want to use Ren'py, but this image-scaling issue (whether either fullscreen or windowed mode looks dodgy due to inconsistent image scaling) has long been a problem for me and a massive discouragement when it comes to developing games in Ren'py.
If anyone can think of a solution, I would be MASSIVELY grateful. <3
Many thanks!
Maj x
Image Scaling Issues
Forum rules
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
Re: Image Scaling Issues
Update: After doing some more hunting, I have enabled config.nearest_neighbor (True).
While this has solved SOME of the incorrect resizing, it hasn't fixed it all. In the attached images, squares 1, 2, and 4 have uniform borders (every side is the same width), but squares 3 and 5 do not (square 3 is narrower on the left and right, square 5 has a thicker top).
Enabling and disabling anti-aliasing doesn't seem to have any impact; the same squares have the same problems, and the same squares appear properly.
While this has solved SOME of the incorrect resizing, it hasn't fixed it all. In the attached images, squares 1, 2, and 4 have uniform borders (every side is the same width), but squares 3 and 5 do not (square 3 is narrower on the left and right, square 5 has a thicker top).
Enabling and disabling anti-aliasing doesn't seem to have any impact; the same squares have the same problems, and the same squares appear properly.
-
- Newbie
- Posts: 2
- Joined: Sat Jul 29, 2023 2:06 pm
- Contact:
Re: Image Scaling Issues
I'm having the same problem. Did you ever find a solution?
Who is online
Users browsing this forum: RVNSN