Home > Net >  How to slice and complie an image into a window effect using Python
How to slice and complie an image into a window effect using Python

Time:11-27

I would like to slice up an image in python and paste it back together again as a window.

The tiles measure as 8pixels by 9pixels and each row needs to skip 1 pixel

I would then need to merge the tiles back together again with a 1 pixel padding around each tile to give a windowed effect.

The image is black and white but for the example I have used color to show that the windowed effect would need to have a white background

enter image description here res.jpg enter image description here remove_tiles.jpg enter image description here

print(image.shape, new_img.shape) gives (952, 1429, 3) (1332, 1899, 3)

  • Related