Disabling smoothing / anti-aliasing / filtering / interpolation / Using nearest filtering?

Hello everyone,

when you use the to_image or the write_image function, is there a way to disable the smoothing of the graphics?
What I mean is to disable any filtering / smoothing of the resulting graphics. The goal would be jagged, but pixel perfect lines here.
Is there an option to set this, like interpolation='nearest' or something?

For further explaination, I wanted a resulting graph that looks like the one on the left:

grafik

Best regards! :slight_smile: