need to make room in the seat I guess
This commit is contained in:
24
carousel.py
24
carousel.py
@@ -312,7 +312,7 @@ while True:
|
||||
unique = str(unique)
|
||||
composite = imagesPath + unique + '.jpg'
|
||||
|
||||
# concatenate images and save concatenated image at composite (is filepath)
|
||||
# concatenate images and save concatenated image at composite (is filepath)
|
||||
headerIsAt = imagesPath + 'header.jpg'
|
||||
header = Image.open(headerIsAt)
|
||||
im1 = Image.open(jpgpath1)
|
||||
@@ -337,12 +337,12 @@ while True:
|
||||
addtoDB.addToDB(bmpath2,dbPath,composite)
|
||||
addtoDB.addToDB(bmpath3,dbPath,composite)
|
||||
|
||||
#add the photo strip to the ssb
|
||||
#add the photo strip to ssb
|
||||
key = addtoDB.addToSSB(composite,dbPath,0)
|
||||
|
||||
|
||||
# Create qr code
|
||||
#from https://ourcodeworld.com/articles/read/554/how-to-create-a-qr-code-image-or-svg-in-python
|
||||
#from https://ourcodeworld.com/articles/read/554/how-to-create-a-qr-code-image-or-svg-in-python
|
||||
qr = qrcode.QRCode(
|
||||
version = 1,
|
||||
error_correction = qrcode.constants.ERROR_CORRECT_H,
|
||||
@@ -358,21 +358,27 @@ while True:
|
||||
img.save(whereToSaveQR)
|
||||
|
||||
|
||||
# concatenate QR instructions with QR
|
||||
# generate full composite for printing
|
||||
color=(0, 0, 0)
|
||||
dst = Image.new('RGB', (600, 2890))
|
||||
dst.paste(concaz, (0, 0))
|
||||
whereQRinstructionsAre = imagesPath + 'ssbqrinstgurct.jpg'
|
||||
qrInstruct = Image.open(whereQRinstructionsAre)
|
||||
whereInstructionsPlusQRis = imagesPath + 'instructionsPlusQR.jpg'
|
||||
get_concat_h_blank(qrInstruct, img, (255, 255, 255)).save(whereInstructionsPlusQRis)
|
||||
instr = Image.open(whereInstructionsPlusQRis)
|
||||
|
||||
dst.paste(qrInstruct, (0,2675))
|
||||
dst.paste(img, (385,2657))
|
||||
# whereInstructionsPlusQRis = imagesPath + 'instructionsPlusQR.jpg'
|
||||
# get_concat_h_blank(qrInstruct, img, (255, 255, 255)).save(whereInstructionsPlusQRis)
|
||||
# instr = Image.open(whereInstructionsPlusQRis)
|
||||
|
||||
#generate unique file_name
|
||||
unique = uuid.uuid4()
|
||||
unique = str(unique)
|
||||
FULLcomposite = imagesPath + unique + '.jpg'
|
||||
# save the full composite image for printing
|
||||
dst.save(FULLcomposite)
|
||||
|
||||
# concatenate existing composite image with the instructions+QR composite for full composite image for print
|
||||
get_concat_v(concaz, instr).save(FULLcomposite)
|
||||
# get_concat_v(concaz, instr).save(FULLcomposite)
|
||||
|
||||
# print Fullcomposite
|
||||
try:
|
||||
|
||||
Reference in New Issue
Block a user