first commit
This commit is contained in:
Binary file not shown.
|
After Width: | Height: | Size: 112 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 91 KiB |
@@ -0,0 +1,18 @@
|
|||||||
|
from PIL import Image
|
||||||
|
|
||||||
|
# Opening the primary image (used in background)
|
||||||
|
img1 = Image.open(r"images/portrait1.png")
|
||||||
|
|
||||||
|
# Opening the secondary image (overlay image)
|
||||||
|
img2 = Image.open(r"images/credit_agricole.png")
|
||||||
|
|
||||||
|
img1 = img1.resize((300, 300))
|
||||||
|
img2 = img2.resize((300, 300))
|
||||||
|
|
||||||
|
# Pasting img2 image on top of img1
|
||||||
|
# starting at coordinates (0, 0)
|
||||||
|
img1.paste(img2, (0,0), mask = img2)
|
||||||
|
|
||||||
|
# Displaying the image
|
||||||
|
img1.show()
|
||||||
|
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
pillow
|
||||||
Reference in New Issue
Block a user