Skip to content

Promote to production: pas foto guided camera + auto-align - #301

Merged
slaveofcode merged 2 commits into
mainfrom
develop
Aug 21, 2026
Merged

Promote to production: pas foto guided camera + auto-align#301
slaveofcode merged 2 commits into
mainfrom
develop

Conversation

@slaveofcode

Copy link
Copy Markdown
Owner

Promotes the Pas Foto Maker guided camera capture (live framing feedback, auto-capture) and automatic head alignment for both camera and uploaded photos. CI green on develop.

…-align

Users without a photo can now shoot one in the tool. The camera opens
front-facing with the existing passport guide drawn over the exact crop
the photo will use, and on-device face detection (the model Face Blur
already ships) gives live feedback — move closer / further back /
centre your head — plus an optional 3-2-1 auto-capture that only fires
while the framing stays good.

After capture *and* after an upload, the head is auto-aligned: a single
detection sets the existing zoom/offset controls so the crown and chin
land on the guide lines. Manual sliders and a re-align button remain.

New pure lib foto-align.lib (framingFeedback, alignTransform,
coverCropRect — 18 tests verifying the head lands on the guide to
sub-pixel accuracy across aspect ratios and source orientations).
useCamera.start() takes an optional facing mode (defaults unchanged).
Preview is mirrored for selfie comfort but the captured file is not.
Detector failure degrades to manual framing, never blocking capture.
EN + ID SEO updated.
feat(pas-foto): guided camera capture with live framing help + auto-align
@slaveofcode
slaveofcode merged commit 581fbfc into main Aug 21, 2026
2 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant