© oxigenio-dapalavra I tumblr -->

17 notas · #importanciaimporta #haga #siempre #alguien #herido #frases #gif #pelicula #actriz #diga
  1. carolinacarranza ha reblogueado esto desde paolalugob
  2. paolalugob ha reblogueado esto desde thetrueparadiseisthelife
  3. gerardojauregui ha reblogueado esto desde thetrueparadiseisthelife
  4. anaaaaaelizabeth ha reblogueado esto desde thetrueparadiseisthelife
  5. nataliiabelenn ha reblogueado esto desde emiivaldez
  6. emiivaldez ha reblogueado esto desde vanelopez1
  7. anely-skins-ldr ha reblogueado esto desde thetrueparadiseisthelife
  8. alohaeiou ha reblogueado esto desde thetrueparadiseisthelife
  9. tuyyoriendojuntos ha reblogueado esto desde thetrueparadiseisthelife
  10. thesideofphobia ha reblogueado esto desde fucking-paranoid-world
  11. fucking-paranoid-world ha reblogueado esto desde rock-is-my-life-man
  12. vanelopez1 ha reblogueado esto desde rock-is-my-life-man
  13. rock-is-my-life-man ha reblogueado esto desde fuuckinginnocence
  14. fuuckinginnocence ha reblogueado esto desde thetrueparadiseisthelife
  15. thetrueparadiseisthelife ha publicado esto

. contador de visitas para blogger
[code] #!/usr/bin/env python # encoding: utf-8 """ protect_image.py Created by Jacob Sunol (www.jasuca.com) Licenced under MIT Licence (http://opensource.org/licenses/mit-license.php) Test image from wWikimedia.org - http://commons.wikimedia.org/wiki/File:Turbinella_pyrum_01.jpg """ import sys import os import Image import random def split_y(size_y, divisions): """ Split into x divisions a y size """ inc = size_y / divisions return [inc*(x+1) for x in range(divisions)] def generate_boxes(size_x, size_y, divisions=4): """ Generate n boxes full x size """ y_splited = split_y(size_y, divisions) boxes = [] y_top = 0 for y_bottom in y_splited: boxes.append((0,y_top, size_x, y_bottom)) y_top = y_bottom return boxes def main(): """ Constants """ divisions = 5 infile = 'test_in.png' outfile = 'test_out.png' htmloutfile = outfile + '.html' format_file = 'PNG' #Open the image im = Image.open(infile) size_x, size_y = im.size #Generate the boxes for the image boxes = generate_boxes(size_x, size_y, divisions) #Crop the image regions = [] for box in boxes: region = im.crop(box) regions.append(region) #Shuffle the boxes croped random.shuffle(boxes) #Create a new image im_new = Image.new(im.mode, im.size) #Paste the croped parts for x in range(len(boxes)): box = boxes[x] region = regions[x] #print box, region im_new.paste(region, box) #Save the new image im_new.save(outfile, format_file, quality=100) #Generate the new HTML file f = open(htmloutfile,'w') f.write('') for box in boxes: f.write("
"%(outfile, box[0], box[1], size_x, size_y/divisions )) f.write(' ') f.close() pass if __name__ == '__main__': main()