Turn off anti aliasing for images

Discuss how to use the Ren'Py engine to create visual novels and story-based games. New releases are announced in this section.
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.
Post Reply
Message
Author
SilverSea
Newbie
Posts: 10
Joined: Wed Jul 11, 2018 10:27 am

Turn off anti aliasing for images

#1 Post by SilverSea » Wed Jul 11, 2018 10:58 am

So my art is very very small and needs to have sharp clean lines, I can resize every single image file that I use in the game x_x but I would really really rather not do unless there really is no other way(changing my mind about how big the characters should be would be a nightmare...) I could write a python program to do it for me except for the fact that I don't have the Python Imaging Library and therefore cannot save .png files.

I tried writing a function to resize the images inside a .rpy script but I don't understand the Renpy syntax or where I should put the python code. The .rpy files seem to have their own syntax and don't like things like imports and functions. The zoom and size commands both anti alias the art in question.

If I can't turn off the anti aliasing I'll probably go back to writing my own engine which has a long way to go before it's good enough to make professional quality games with. Or I'll have to download the source code for Ren'py and hope that it's written in python 2 since it's impossible for me to install python 3+pygame for python 3.

User avatar
PyTom
Ren'Py Creator
Posts: 15200
Joined: Mon Feb 02, 2004 10:58 am
Completed: Moonlight Walks
Projects: Ren'Py
IRC Nick: renpytom
Github: renpytom
itch: renpytom
Location: Kings Park, NY
Contact:

Re: Turn off anti aliasing for images

#2 Post by PyTom » Wed Jul 11, 2018 1:35 pm

It's hard to understand what you want. If you're looking for something like pixel art, consider using config.nearest_neighbor:

Code: Select all

define config.nearest_neighbor = True
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom
"Silly and fun things are important." - Elon Musk
Software > Drama • https://www.patreon.com/renpytom

SilverSea
Newbie
Posts: 10
Joined: Wed Jul 11, 2018 10:27 am

Re: Turn off anti aliasing for images

#3 Post by SilverSea » Thu Jul 12, 2018 10:28 am

That worked perfectly, thanks! That was exactly what I wanted.

Post Reply

Who is online

Users browsing this forum: DragoonHP