Birthday Slideshow
Throwing yourself a birthday party is an excellent way to reconnect with your friends and family. Guests have a great time together, but the joy doesn’t stop there: it goes on for days after because they’re still talking about your slideshow.
What slideshow? Let me explain…
They didn’t believe me
Guests kept asking, “So how do you know so and so?” though I was prepared for that. Every time that question was asked I’d throw my arm over their shoulders and say “It will all be explained in the slideshow” to which they chuckled because it sounded unusual.
But when I fired up the TV with a comically long HDMI cable running to my computer they realized I wasn’t joking. As soon as the first slide filled the screen, everyone was glued to it asking “Is that you?!”
The vision
I wanted to tell the story of how my guests entered my life and how they all connected to each other. From the start, I knew this meant a chronologically arranged album. Because I’ve never maintained a presence on Facebook, Instagram, or any other social media, many of these photos were never before seen by my friends either, making it extra special.
If I had the year written in the corner of the slide I could preemptively answer the obvious question “When was this?” I would have to include that too.
Piecing it together
I leafed through my photo album and tagged those photos to include. I then exported the collection to a folder on my desktop.
As you can imagine, these filenames were chaotic. Not only do cameras and phones automatically assign names to images, but I also made a few failed attempts in the past to bring order to my collection through renaming files myself.
To get oriented in this project, I wanted a sense of what the stories would be while simply browsing this folder on the filesystem. For that, I needed these renamed to a format like YYYY-MM-DD-time-random-string.jpg. Looking at over 100 photos, I wasn’t about to figure out the date of the photo and rename the file manually.
So I vibe-coded a script for that. Here are some things it handles:
- 20+ image formats (jpg, png, etc.)
- Dual detection: file extension + MIME type via
exiftool - EXIF hierarchy:
ContentCreateDate→DateTimeOriginal→CreateDate→ModifyDate→ filesystem birth time - MPO (3D photo) files (extracts the first frame)
Now with the photos sorted by date, it was time to create the slideshow. Click new slide, drag the photo in, resize it to fill the slide, add the year in a text box in the bottom right corner, and do that 100 more times? No way. So I vibe-coded a script for that too.
The script generates a PowerPoint file with a slide for each photo. It scales the image to fit the slide (with dark gray letterbox bars in the empty space), and adds a year mark in the bottom right corner. Here are some complexities the script handles:
- EXIF orientation tags—photos display upright regardless of camera rotation
- MPO to JPEG conversion
- Aspect ratio detection: landscape vs. portrait images get different scaling logic
- Year extraction from the
YYYY-MM-DDfilename pattern - Drop shadow text effect (white text with offset black text beneath for readability)
After several attempts, it worked. Pretty cool.
The unknowns
At first, some photos were rotated 90° or 180°. I learned cameras store orientation in EXIF tags rather than actually rotating pixels.
Another challenge was that some cameras save photos as Multi-Picture Object (MPO) files containing two JPEG frames. The MPO file won’t render in the slide, so you have to extract the first frame to insert it.
When it comes to discovering the date of the photo, cameras embed this information in multiple EXIF fields with inconsistent naming. iPhones use this one DSLRs use that one—it’s a mess. The solution was to determine an algorithm to take the best guess of when the photo was taken.
Finally, the year mark would need to work like subtitles do in movies: white text with a black shadow so that it’s legible even on light backgrounds. PowerPoint doesn’t support drop shadows natively in python-pptx, so the trick is to add two text boxes slightly offset to create the desired shadow effect.
Pick a date and make your own
Send invites to your birthday party and then give my slideshow scripts a whirl. I vibe-coded it and debugged it so you don’t have to. Everyone will love the trip down memory lane.
Those guests who couldn’t make the party will be asking you later for the link.