An example blog post about copy-image-on-another-image
An example blog post about copy-image-on-another-image
Table of Contents
titleimg = Image.new(
"RGB", (size_object.width, size_object.height), size_object.bg_color
)
imagefilename = "bbposter3.webp"
img = Image.open(imagefilename)
titleimg.paste(img, (0, 0))
I2 = ImageDraw.Draw(titleimg)
myFont = ImageFont.truetype(size_object.font_name, size_object.font_size + 10)
y = 50
I2.text((50, y), title, font=myFont, fill=(255, 0, 0))
titleimg.save(f"./vids/{text_filename}/title.jpg")