Skip to content
Snippets Groups Projects
Commit f60dfaa8 authored by Antonio MATTAR's avatar Antonio MATTAR
Browse files

-Improved createImage function.

parent 844ad77c
No related branches found
No related tags found
No related merge requests found
......@@ -40,8 +40,8 @@ def createAbsImage(terme):
im1 =createAlligator(input)
im2 = createImage(output)
abstraction = Image.new('RGB', (max(im1.width, im2.width), im1.height + im2.height), (255, 255, 255))
abstraction.paste(im1, (0, 0))
abstraction.paste(im2, ((im1.width - im2.width) // 2, im1.height))
abstraction.paste(im1, ((max(im1.width, im2.width)-im1.width) // 2, 0))
abstraction.paste(im2, ( 0 , im1.height))
abstraction.save('abs.png')
return abstraction
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment