Nearest neighbour interpolation

master
LEdoian 3 years ago
parent d7552fe876
commit bf4ab225f2

@ -0,0 +1,9 @@
import lib
class Nearest(lib.Interpolator):
def get_pixel(self, pic, x, y, r, qx, qy):
rx = round(x)
ry = round(y)
pix = pic.pixels[y][x]
return pix
Loading…
Cancel
Save