Version bataille navale

This commit is contained in:
rep 2015-11-27 17:50:09 +01:00
commit a4472685b3
2 changed files with 46 additions and 1 deletions

5
.gitignore vendored
View File

@ -5,6 +5,9 @@ pylone3/
screen/
test/
tth/
drone.mp4
*.mp4
*.png
*.mkv
*.jpg
drone.2.mp4
test.jpg2015-09-29-21h22m05s.jpg

View File

@ -1,6 +1,7 @@
#!/usr/bin/python
# coding: utf-8
<<<<<<< HEAD
'''
ffmpeg -i drone.mp4 -vf fps=30 ./drone/img%03d.jpg
'''
@ -8,18 +9,33 @@ ffmpeg -i drone.mp4 -vf fps=30 ./drone/img%03d.jpg
import sys # sys.argv[]
import Image # Image.open()
import os # os.getcwd
=======
import sys
import Image
>>>>>>> adc56b0f751a338bfe5c843061889df049d4390b
'''
im1 = Image.open(str(sys.argv[1]))
width, height = im1.size
<<<<<<< HEAD
print "width =% 5.2i" % width
print "height =% 5.2i" % height
allongement = 8
im4 = Image.new("RGBA",(im1.size[0]*allongement, im1.size[1]))
=======
print
print "width =% 5.2i" % width
print "height =% 5.2i" % height
print
allongement = 8
im4 = Image.new("RGBA",(im1.size[0]*allongement, im1.size[1]))
>>>>>>> adc56b0f751a338bfe5c843061889df049d4390b
for x in range(1,allongement+1):
print('%03.1i' % x)
'''
<<<<<<< HEAD
script = os.getcwd()
print script
@ -109,3 +125,29 @@ im2.save(script+"/"+str(x)+".2.png",'PNG', quality=100)
2009 history | grep ffmpeg
'''
=======
index = 1
allongement = 300 #4818
im1 = Image.open("./drone/img001.jpg")
im2 = Image.new("RGBA",(im1.size[0]*allongement, im1.size[1]))
largeur = im1.size[0]
for x in range(0,allongement/10):
position = 0
for y in range(1,11):
im1 = Image.open("./drone/img%03.1i.jpg" % y)
im2.paste(im1, (position,0))
#print position
#print("./drone/img%03.1i.jpg" % x)
position = position + largeur
scriptpy = str(sys.argv[1])
script = scriptpy[:-3]
im2.save(script+"_"+str(x)+".png",'PNG', quality=100)
>>>>>>> adc56b0f751a338bfe5c843061889df049d4390b