Compact Next.js app that scans cruise deck-plan images, highlights cabin rectangles on top of the source image, extracts cabin numbers with OCR, and surfaces each detected cabin's fill colour.
flowchart LR
A[Upload or load sample deck] --> B[Palette scan for repeated cabin fills]
B --> C[Neutral cabin recovery for light cabins]
C --> D[OCR pass for cabin labels]
D --> E[OCR-seeded rectangle recovery]
E --> F[Compact review UI with overlay + table]
- Finds repeated cabin rectangles without needing OpenCV or browser GPU tricks.
- Recovers difficult white and light cabins with a second detector pass.
- Uses whole-image OCR plus OCR-seeded recovery instead of expensive OCR-per-cabin loops.
- Keeps the interface small, readable, and presentation-friendly.
- Load a bundled sample deck or upload your own deck-plan image.
- Run one scan.
- Inspect detected cabins directly on the image, then review the active cabin data in the side rail.
src/
app/
api/analyze-deck/route.js # server endpoint
page.js # app entry
components/deck-scanner/ # small reusable UI pieces
lib/
analyzeDeckImage.js # scan orchestrator
deck-analyzer/ # reusable detection + OCR helpers
public/
Royal-Deck.png
Arivia-Deck.png
npm install
npm run devOpen http://localhost:3000.
npm run build
npm run audit:samplesCurrent scanner logic has been verified against the bundled sample deck images in public/.