Ce projet essai, en partant d'une IMAGESOURCE de : - appliquer des effets à l'image - la redimmensionner - changer son mode de couleur - la HAACHEER...
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

31 lines
815 B

#!/usr/bin/python
# coding: utf-8
import Image
import sys
import ImageDraw
from PIL.Image import composite,LINEAR
# MILLISECONDES
from datetime import datetime
dt = datetime.now()
dt.microsecond
im1 = Image.open(str(sys.argv[1])).convert('RGBA')
im2 = Image.open(str(sys.argv[2])).convert('RGBA')
im3 = Image.new("1", (512,512), "white")
draw = ImageDraw.Draw(im3)
draw.ellipse(((100,100),(200,200)), fill="black")
draw.ellipse(((180,180),(300,300)), fill="black")
scriptpy = str(sys.argv[1])
script = scriptpy[:-4]
heure = str(dt.hour)+"h"+str(dt.minute)+"m"+str(dt.second)+"s"+str(dt.microsecond)+"ms"
im1.paste(im2, im3)
im1.save(script+".1.alpha."+heure+".png",'PNG', quality=100)
im2.save(script+".2.alpha."+heure+".png",'PNG', quality=100)
im3.save(script+".3.alpha."+heure+".png",'PNG', quality=100)