#!/usr/bin/env python3 """Create non-production illustration review evidence for BP-016 candidate 02.""" from pathlib import Path from PIL import Image ROOT = Path(__file__).resolve().parents[1] REPO = next(p for p in ROOT.parents if (p / "docs/card-art-brief.md").is_file()) SOURCE = ROOT / "source" OUT = ROOT / "review/candidate-02" OUT.mkdir(parents=True, exist_ok=True) image = Image.open(SOURCE / "art-native-candidate-02.png").convert("RGBA") for width in (1000, 500, 250): image.resize((width, width * 7 // 5), Image.Resampling.LANCZOS).save( OUT / f"art-{width}.png" ) master = image.resize((2000, 2800), Image.Resampling.LANCZOS) overlay = Image.open( REPO / "artifacts/layers/rare/v3/exports/overlay-normal-2000.png" ).convert("RGBA") Image.alpha_composite(master, overlay).resize( (1000, 1400), Image.Resampling.LANCZOS ).save(OUT / "layout-guide-normal.png") crops = { "figure-100.png": (285, 115, 1060, 1484, 1), "face-hair-beard-200.png": (465, 115, 800, 535, 2), "chest-hand-300.png": (635, 555, 940, 845, 3), "extended-hand-300.png": (20, 785, 395, 1090, 3), "upper-background-100.png": (0, 0, 1060, 465, 1), "left-environment-200.png": (0, 230, 465, 1190, 2), "right-architecture-100.png": (790, 0, 1060, 1000, 1), "lower-background-100.png": (0, 990, 1060, 1484, 1), } for name, (left, top, right, bottom, scale) in crops.items(): crop = image.crop((left, top, right, bottom)) if scale != 1: crop = crop.resize( (crop.width * scale, crop.height * scale), Image.Resampling.NEAREST ) crop.save(OUT / name) print("Wrote BP-016 candidate-02 art-review evidence")