Automate slide generation with Python
Budget: $30 – $250 USD
I am a teacher in Tokyo working on developing visual language learning materials for young children.
This project is to create a program to work on a Windows platform using Python. The program will take a folder of images and combine them into a single .png file based on the below instructions.
Standards:
- (X, Y) coordinates in an image are pixels from the left (X) and top (Y)
- for example X = 100 is the vertical line of pixels 100 pixels from the left side of the image; Y = 50 is the horizontal line of pixels 50 pixels from the top
- (500, 300) is the single pixel 500 pixels from the left and 300 pixels from the top
Inputs:
- folder path
- any number of images in a single folder in either .png or .jpg format, any size/resolution
- "slide pictures.txt" file contained in folder
- "slide subtitles.txt" file contained in folder
Processing:
- create a transparent .png "canvas" image, pixel dimensions 3508 (width) x 2481 (height)
- place "component" images in the order (left to right) indicated in "slide pictures.txt" file in the canvas based on below Component Guidelines
- Note: Do not change the original component files. Perform any necessary resizing in the canvas only.
- place subtitle text in the order (left to right) indicated in "slide subtitles.txt" based on below Subtitle Guidelines
- save result as Output
Component Guidelines:
- heights are equal except for "-000.png" files
- if the component name ends with "-000.png", use a fixed height of 250 pixels (there may be more than one of these)
- space between left and right edges of canvas and first component: 40 pixels
- space between components: 40 pixels
- minimum space between top of canvas and top of components: 40 pixels
- minimum space between top of subtitle text area and bottom of components: 40 pixels
- if total usable width (X = 40 to 3468) is not used by components, distribute them evenly across usable width
- vertically centered at Y = 1145
Subtitle Guidelines:
- subtitle text area: Y = 2251 to 2481 (bottom 231 pixels)
- horizontally centered under corresponding image
- vertically centered at Y = 2366
- 40pt Futura black
Output:
- single .png file, filename = folder name + " slide"
- size in pixels: 3508 x 2481
- transparent background
- resolution: 300dpi
Project Files:
- see attached "freelancer slide automation project folder.zip"
- "slide areas.png" indicates the regions where components and subtitles will go
- "picture folder 1" and "picture folder 2": folders with images, .txt files and desired outputs
- "picture folder 3" and "picture folder 4": folders with images and .txt files only to test your program
This project is to create a program to work on a Windows platform using Python. The program will take a folder of images and combine them into a single .png file based on the below instructions.
Standards:
- (X, Y) coordinates in an image are pixels from the left (X) and top (Y)
- for example X = 100 is the vertical line of pixels 100 pixels from the left side of the image; Y = 50 is the horizontal line of pixels 50 pixels from the top
- (500, 300) is the single pixel 500 pixels from the left and 300 pixels from the top
Inputs:
- folder path
- any number of images in a single folder in either .png or .jpg format, any size/resolution
- "slide pictures.txt" file contained in folder
- "slide subtitles.txt" file contained in folder
Processing:
- create a transparent .png "canvas" image, pixel dimensions 3508 (width) x 2481 (height)
- place "component" images in the order (left to right) indicated in "slide pictures.txt" file in the canvas based on below Component Guidelines
- Note: Do not change the original component files. Perform any necessary resizing in the canvas only.
- place subtitle text in the order (left to right) indicated in "slide subtitles.txt" based on below Subtitle Guidelines
- save result as Output
Component Guidelines:
- heights are equal except for "-000.png" files
- if the component name ends with "-000.png", use a fixed height of 250 pixels (there may be more than one of these)
- space between left and right edges of canvas and first component: 40 pixels
- space between components: 40 pixels
- minimum space between top of canvas and top of components: 40 pixels
- minimum space between top of subtitle text area and bottom of components: 40 pixels
- if total usable width (X = 40 to 3468) is not used by components, distribute them evenly across usable width
- vertically centered at Y = 1145
Subtitle Guidelines:
- subtitle text area: Y = 2251 to 2481 (bottom 231 pixels)
- horizontally centered under corresponding image
- vertically centered at Y = 2366
- 40pt Futura black
Output:
- single .png file, filename = folder name + " slide"
- size in pixels: 3508 x 2481
- transparent background
- resolution: 300dpi
Project Files:
- see attached "freelancer slide automation project folder.zip"
- "slide areas.png" indicates the regions where components and subtitles will go
- "picture folder 1" and "picture folder 2": folders with images, .txt files and desired outputs
- "picture folder 3" and "picture folder 4": folders with images and .txt files only to test your program