diff --git a/sstv.py b/sstv.py index 7069226..04da59c 100644 --- a/sstv.py +++ b/sstv.py @@ -17,8 +17,12 @@ def mark_photo(): raw_img = Image.open("working/working.jpg") # Open the current working image img = raw_img.resize((320, 240), Image.ANTIALIAS) # resize it for the radio - - TINT_COLOR = (255, 255, 255) # White text bg + if False: + TINT_COLOR = (255, 255, 255) # White text bg + TEXT_COLOR = (0,0,0) + else: + TINT_COLOR = (0, 0, 0) # Black text bg + TEXT_COLOR = (255,255,255) TRANSPARENCY = .25 # Degree of transparency, 0-100% OPACITY = int(255 * TRANSPARENCY) overlay = Image.new('RGBA', img.size, TINT_COLOR+(0,)) @@ -28,12 +32,12 @@ def mark_photo(): smallfont = ImageFont.truetype(r'C:\Users\System-Pc\Desktop\arial.ttf', 17) draw.rectangle(((0, 0), (90, 20)), fill=TINT_COLOR+(OPACITY,)) - draw.text((0, 0),"KW1FOX",(0,0,0),font=bigfont) # Draw KW1FOX in the top left + draw.text((0, 0),"KW1FOX",TEXT_COLOR,font=bigfont) # Draw KW1FOX in the top left - draw.rectangle(((0, 40), (83, 100)), fill=TINT_COLOR+(OPACITY,)) - draw.text((0, 40),"day: 25.2",(0,0,0),font=smallfont) - draw.text((0, 60),"Volt: 13.8",(0,0,0),font=smallfont) - draw.text((0, 80),"Miles: 1.02",(0,0,0),font=smallfont) + draw.rectangle(((0, 40), (83, 80)), fill=TINT_COLOR+(OPACITY,)) + draw.text((0, 40),"day: 25.2",TEXT_COLOR,font=smallfont) + draw.text((0, 60),"Volt: 13.8",TEXT_COLOR,font=smallfont) + #draw.text((0, 80),"Miles: 1.02",TEXT_COLOR,font=smallfont) img = img.convert("RGBA") img = Image.alpha_composite(img, overlay) diff --git a/working/working.jpg b/working/working.jpg index 3e6a73d..d3c7298 100644 Binary files a/working/working.jpg and b/working/working.jpg differ diff --git a/working/working.wav b/working/working.wav index 8fcbb77..3b5c4a0 100644 Binary files a/working/working.wav and b/working/working.wav differ