18 lines
445 B
Bash
18 lines
445 B
Bash
#!/bin/bash
|
|
python3 - <<'EOF'
|
|
from PIL import Image, ImageDraw
|
|
|
|
pairs = [
|
|
('x86-1', '/mnt/f/efi/Boot/1x86.bmp', (40, 474, 470, 508)),
|
|
('x86-2', '/mnt/f/efi/Boot/2x86.bmp', (28, 460, 520, 521)),
|
|
]
|
|
BG = (233, 233, 233)
|
|
for name, src, box in pairs:
|
|
im = Image.open(src).convert('RGB')
|
|
d = ImageDraw.Draw(im)
|
|
d.rectangle(box, fill=BG)
|
|
out = f'/path/to/pf/KRD/images/{name}-nokrd.png'
|
|
im.save(out)
|
|
print(out, box)
|
|
EOF
|