benfry / processing4

Processing 4.x releases for Java 17
https://processing.org
Other
1.34k stars 239 forks source link

Add the ability to choose the interpolation mode used when resizing an image #804

Open jSdCool opened 10 months ago

jSdCool commented 10 months ago

added the ability to choose witch interpolation mode to use when resizing an image.

to do this there is a new overload for PImage.resize() that takes 3 ints (width, height, interpolation mode) there are also 3 new PConstants for the mode they are: NEAREST_NEIGHBOR, BILINEAR, and BICUBIC. They have a value of 0 1 and 2 respectively.