๐ Pillow ใไฝฟใฃใฆ็ปๅใซ็ธฆๆธใใใญในใใๅใ่พผใ
ใฏใใใซ ็ธฆๆธใใใญในใใ็ปๅใซๅใ่พผใฟใใใจ้ ผใพใใใฎใงใ Python ่ฃฝใฎ็ปๅๅฆ็ใฉใคใใฉใช Pillow ใไฝฟใฃใฆใตใฏใใจๅฎ่ฃ ใใฆใฟใพใใใ ไธๅฟใฝใผในใณใผใใฏ Gist ใซใใขใใๆธใฟใงใ โ๏ธ https://gist.github.com/nikaera/c1049708ff548b06cab0ae377adc4ac7 ๅไฝ็ฐๅข Python 3.9.5 Pillow 8.2.0 ็ปๅใซ็ธฆๆธใใใญในใใๅใ่พผใ ใพใใฏไปๅๅฉ็จใใ Pillow ใไบใใคใณในใใผใซใใฆใใใพใใ pip install Pillow ใใฎๅพ main.py ใไฝๆใใฆไธ่จใๅ ฅๅใใพใใ ใใญในใใๅใ่พผใฟใใ็ปๅใ main.py ใจๅใใใฉใซใใซ sample.jpeg ใจใใๅๅใง้ ็ฝฎใใฆใใใพใใ # Pillow ใฎๅฉ็จใใใขใธใฅใผใซใฎใฟใใคใณใใผใใใ from PIL import Image, ImageDraw, ImageFont # ่ชญใฟ่พผใฟใใใใฉใณใๆ ๅ ฑใๅ ฅๅใใ font_name = "/System/Library/Fonts/ใใฉใญใใ่งใณใใทใใฏ W0.ttc" font_size = 48 font = ImageFont.truetype(font_name, font_size) # ใใญในใใๅใ่พผใฟใใ็ปๅ sample.jpeg ใ่ชญใฟ่พผใ im = Image.open('sample.jpeg') d = ImageDraw.Draw(im) # ็ปๅใซๅใ่พผใฟใใใใญในใๆ ๅ ฑใๅ ฅๅใใ # (ๅพ่ฟฐใใใใๆน่กใณใผใใซใฏๆชๅฏพๅฟ) text = "bifdLcFCKXtFJZmPZhzdefjhhYTtuJPAYsR" # ๆ็ซ ใๆน่กใใใพใงใฎๆๅญๆฐใๅ ฅๅใใ split_number = 11 # split_number ใงๆๅฎใใๆๅญๆฐใใจใซๅๅฒใใ้ ๅใซๆ ผ็ดใใใ # ref: https://qiita....