Posted on

Storage tour

You can make a bet what kind of app this word list was for;)

I am quite interested in subtle manipulations like these, and you can see i am in a perfect gray area, bc the person using it, wants it to work

I got like hundrets of shirt designs, and i made a error, i got 100000 designs in storage to edit~

The scrypt itself is a thing for itself:Dd

I am basically just looping the entirety of the scrypt wanted amount of times~:p

I will have to edit that a bit^~^

.

#|ACIDental - txt to trans img |#                            { # < [<>] < | } ; {meta = #||FE||#} 

#Imports||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
from PIL import Image, ImageFont, ImageDraw                    #||
import random                                                  #||
import tempfile
from PIL import PngImagePlugin
#dep: word.txt / wordlist                                      #||
#|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
# takes word list and makes it randomly to transparent image.
### new task: takes text doc, makes it to img. split after certain lenght into different images?. with bg image
################################-MAIN-#################################
COUNT = 0
def increment():
    global COUNT
    COUNT = COUNT+3

COUNTc = 0
def incrementc():
    global COUNTc
    COUNTc = COUNTc+1






def fun():
       

  
    #Get Rand Word From TXT############################################
        # Open the file in read mode
        with open("slurs.txt", "r") as file:
            allText = file.read()
            words = list(map(str, allText.split()))
    ###change for new project
    #Conversion Axis###################################################
        #make string to var pnames
        ### change random to itterative but not array, just go word for word.
        pnames = random.choice(words)

        # print pnames # -PROOF'-
        print(pnames + " <= " + "-PROOF'-")
        increment()
        incrementc()
       
       
        print("+" + str(COUNTc) + " of 1000 Design printed")
        print("+ " +str(COUNTc/1000*100) + "% Done")
        print("+ " + str(COUNT) + "€ theoretical")
        print("+ " + str(COUNT/100*20) + "€ predicted")
       
       
    #
   

   
    #Canvas Making#####################################################
        #birth canvas
        img=Image.new('RGBA',(4000,4000),'white')

        #make transparent
        img = img.convert("RGBA")
        datas = img.getdata()

        newData = []
        for item in datas:
            if item[0] == 255 and item[1] == 255 and item[2] == 255:
                newData.append((255, 255, 255, 0))
            else:
                newData.append(item)

        img.putdata(newData)

        # trans img saved # -PROOF''-
        #img.save("./trans.png", "PNG", dpi=(600, 600))
        #print("-PROOF''- >saved<")

      
      
        after = ""
    
        comb = after + "" + pnames


   
    #Text Making#######################################################
        #text dependencies
        font=ImageFont.truetype("drip.otf",500)
        w,h=font.getsize(comb)

        #draw text
        draw=ImageDraw.Draw(img)
        draw.text(((4000-w)/2,(4000-h)/2),comb,font=font,fill='#FFAECB' )
    #



    #Export############################################################
        #save
       # for x in range(0, 1):
        #    x
        #a= str (x)
        img.save("image.png", "PNG", dpi=(600, 600))
       

    #

    #DPI Bridge checker##############




#132
for x in range(0, 700):
    fun()
   
i = input('Done?(y)')
if i == "y":
    print('Understood')




#|||||||||||||||Format_Exept||||||||||||||||#
#/#_ToDo_#/#

#size to 3000xx
#is dpi?(N?)xxN
#N= idk duck or smth (bridge DPI Bug)xxPILxxERROR

#/#
#|||||||||||||||Format_Exept||||||||||||||||#


It basically just prints the text on a transparent bg, from there i will take its output and merge it with a bg

Oh and theres a counter in there to predict profits, which was nevee adjusted

Great this file exists now but is not debugged

Only payments, connecting and debug left^~^