Why not a transparent image is superimposed on the image?

When I tried to put a transparent photo on another photo, it did not overlap transparent, here's a photo after applying:
59d248e742c65076354811.png

here is the code:
img = Image.open('screen.png') #screenshot
img2 = Image.open('Without name-1.png') #transparent photo
img.paste(img2, (0, 0)) #overlay
img.save('new.png') #save

what could be wrong?
thank you
June 14th 19 at 20:34
1 answer
June 14th 19 at 20:36
With PIL is not working.
But you can solve this problem using openCV. By multiplying the respective areas of the image on the coefficients. For example:
img = 0.7 * img 
img1 = 0.3 * img1
img2 = img + img1

Find more questions by tags PILPython