bead-grid-studio README

README проекта с github.com/zwhy149/bead-grid-studio. Одним файлом markdown: README.md.

Bead Grid Studio — Local-first Fuse-bead Pattern Generator

Turn images into editable, printable fuse-bead patterns.
Color matching, per-cell color codes, board guides, and material counts run locally in your browser.

English · 日本語 · 한국어 · Français · 简体中文

🚀 Live Demo · ⬇ Offline / Release · 30s Quick Start · 💻 Core API (@bead-grid/core) · 📐 Schemas · ⚡ Benchmarks · 📊 Project Health · ⭐ Star on GitHub

CI License: Apache-2.0 Release Offline Downloads Core

Bead Grid Studio is a local-first fuse-bead pattern generator. It has no account, image-upload API, analytics SDK, or cloud conversion service.

Examples

Simple Graphic: original → fuse-bead pattern

Both sides use the repository's original rocket fixture. The right side is a screenshot of the real running app, not an AI-generated product mockup.

Original image Generated pattern, ready to edit
Original rocket fixture owned by the repository English desktop app generating the rocket fuse-bead pattern

Run npm run capture:docs to regenerate the screenshot from the same fixture. See Screenshots for complete desktop and mobile views.

What it helps you do

30-second Quick Start

  1. Open the live demo.
  2. Select Try a Sample. You do not need an image to see a real rocket pattern in seconds.
  3. Choose a long-side cell count or physical board; keep the recommendation if unsure.
  4. Adjust colors or touch up a few cells when needed.
  5. Select Start Making to place one color at a time, or use Export Pattern for a coded build sheet.
  6. Export the material CSV and save the JSON project when you need purchasing or progress records.

You can instead select Choose Image and use PNG, JPEG, WebP, or GIF. The image is decoded and converted only in the current browser.

Choose your path

Goal Fastest route Installation
Convert an image now Open the live demo None
Work offline or carry the app on a USB drive Download the portable HTML None
Batch conversion / Headless script automation CLI Tool (bead-grid) Node.js
Embed conversion engine in Node.js or web app @bead-grid/core package Node.js
Run inside Anna AI OS (AI Coach + Executa) Anna AI OS Edition Anna OS / npm run build:anna
Publish your own copy Fork and deployment guide GitHub account; Cloudflare optional
Modify or contribute code Developer Guide Node.js

Download the offline app

Regular users do not need the source code or Node.js. The offline app is one self-contained HTML file for modern browsers on Windows, macOS, and Linux:

  1. Open the latest Release.
  2. Expand Assets near the bottom of the Release page.
  3. Download the file named like bead-grid-studio-vX.Y.Z.html, where X.Y.Z is the version.
  4. Do not use GitHub's automatically generated Source code ZIP as the offline app.
  5. Double-click the HTML and open it with Chrome, Edge, Firefox, or Safari.

The portable HTML embeds the application, styles, Apache-2.0 license, and third-party notices with no CDN dependency. The Release also includes a ZIP and SHA256SUMS.txt; compare files only with checksums from the same Release:

# Windows PowerShell: run from the download directory
Get-FileHash .\bead-grid-studio-vX.Y.Z.html -Algorithm SHA256
Get-Content .\SHA256SUMS.txt
# Linux
sha256sum --check SHA256SUMS.txt

# macOS
shasum -a 256 bead-grid-studio-vX.Y.Z.html

On phones, prefer the hosted PWA and use the browser's “Add to Home Screen” action. The PWA must load once from HTTPS before its cached pages can open offline. Drafts live in the current browser's site data; export a JSON project before switching browsers or clearing that data.

Fork & Make It Yours

A Fork gives a developer a practical starting point to:

The shortest route is:

Fork → Enable GitHub Actions → Settings → Pages → Deploy

The repository already includes its build, complete QA, and Pages workflow; do not commit dist manually. Follow the Fork and deployment guide to obtain a GitHub Pages URL in a few minutes. The same guide covers Cloudflare Pages when you need a custom domain and security response headers.

Screenshots

English desktop workbench English mobile workbench
English desktop workbench English mobile workbench

The rocket in these screenshots is an original fixture under tests/fixtures/ and may be reused under this repository's license.

When the first result needs work

The project does not promise lossless reproduction at 16 or 24 cells. It protects outlines, openings, and disconnected features when the target grid can represent them, then reports details that are physically smaller than one bead.

Command-line CLI & Automation

You can generate pattern specifications directly from your terminal or automated scripts:

# Generate 29x29 standard bead pattern with truecolor ANSI terminal preview
node bin/bead-grid.mjs tests/fixtures/rocket-badge.png -w 29 -h 29 --format ascii
node bin/bead-grid.mjs tests/fixtures/rocket-badge.png -w 29 --despeckle --format svg > rocket.svg

# Quantize using a custom 12-color starter palette and output JSON pattern
node bin/bead-grid.mjs image.png -w 29 -p examples/palettes/mini-starter-12.json -o pattern.json

See CLI Documentation and Node.js Integration Example.

Developer & Open-source Ecosystem

Bead Grid Studio is not only an end-user Web/PWA application. The repository also provides a complete, reusable open-source stack:

Architecture Overview

Web / PWA (Browser UI) ──────> Browser Adapter ──┐
Headless CLI (Node.js) ──────────────────────────┼──> @bead-grid/core
Node.js Pipeline / Script ───────────────────────┤     ├── Pattern Model & BOM
Automated Tests / Benchmarks ────────────────────┘     ├── OKLab / CIEDE2000 Matching
                                                       └── Open Schemas (2020-12)

For full system architecture diagrams and ASCII data flows, see ARCHITECTURE.md.

5-minute Developer Quick Start

Call the core engine directly in Node.js with zero browser dependencies:

import { generateBeadPattern } from './packages/core/src/index.js';

// Pass raw pixel data (data: Uint8ClampedArray/Uint8Array, width, height)
const pattern = await generateBeadPattern(imagePixelData, {
  cols: 29,
  rows: 29,
  palette: 'mard-compatible-base-221',
  processMode: 'cartoon',
  maxColors: 32,
});

console.log(`Total beads: ${pattern.statistics.totalBeads}`);
console.log(`Unique colors: ${pattern.statistics.usedColors}`);
console.log(`Top color code: ${pattern.materials[0].code} (${pattern.materials[0].count} beads)`);

Run executable integration examples:

node examples/node/index.mjs
node bin/bead-grid.mjs tests/fixtures/rocket-badge.png -w 29 -h 29 --format ascii
node bin/bead-grid.mjs tests/fixtures/rocket-badge.png -w 29 --despeckle --format svg > rocket.svg
npm run build:anna
npm run schema:validate

Run locally for development

Node.js 22.12 or newer is required:

git clone https://github.com/zwhy149/bead-grid-studio.git
cd bead-grid-studio
npm ci
npm run dev

Run test and benchmark suites:

npm run setup
npm run qa          # Runs source integrity, unit tests, and Playwright E2E
npm run benchmark   # Runs quantization performance benchmarks
npm run health      # Verifies local code health and public metrics

See the complete Developer Guide.

Current Focus & Roadmap

See ROADMAP.md for the full evidence-driven roadmap.

Community Showcase & Contributing

Verifiable project health data and adoption indicators are documented in docs/project-health.md and docs/USAGE_METRICS.md.

Maintainers can run npm run metrics to read Stars, Forks, Open Issues, and real Release asset download counts from GitHub's public API. The script is not included in the web app and never tracks app visitors.

For reproducible project-activity signals, community review records, release safeguards, and explicit evidence boundaries, see Project health and public impact evidence.

Main capabilities and engineering boundaries

Why a small grid cannot be “identical”

A grid is an information budget: 16×16 provides only 256 physical positions. A mark, thin letter, or highlight smaller than one cell cannot always remain an independent bead. The converter preserves representable structure and reports missing detail. See Algorithm and Known limitations.

Palette and physical color accuracy

The default palette is the base 221-code subset (A/B/C/D/E/F/G/H/M) from a pinned MIT-licensed source. Screen HEX values are approximations: displays, room light, printers, manufacturers, and production batches introduce differences. Verify expensive builds against the physical color card for the exact bead brand and batch. See Palette provenance.

MARD, Artkal, Hama, and Perler are third-party marks. This independent project is not affiliated with or endorsed by those brands. See TRADEMARKS.md.

Privacy and security

Report security issues privately through SECURITY.md. Do not attach private, customer, or unlicensed images to a public Issue. GitHub Pages does not apply the optional _headers file; see Deployment for the exact hosting boundary.

Repository Structure & Architecture

For full system architecture diagrams and ASCII data flows, see ARCHITECTURE.md.

anna-app/                 Anna AI OS schema-4 app package (manifest, bead-studio Executa, Craft Coach skill)
packages/core/            Decoupled DOM-free core quantization engine & TypeScript definitions
schemas/                  Open data specifications (Pattern & Palette JSON Schema 2020-12)
bin/                      Headless Node.js CLI tool (bead-grid)
examples/                 Browser, Node.js, and CLI integration examples
src/                      Browser app, core modules, i18n, and palette data
public/                   PWA, offline cache, SEO, privacy, and legal pages
tests/unit/               Pure invariant tests & deterministic golden tests
tests/e2e/                Desktop, mobile, and browser tests
tests/fixtures/           Original or explicitly licensed fixtures
scripts/                  Source checks, metrics, and portable build
docs/                     Architecture, algorithm, deployment, provenance, and ADRs

License

Code is licensed under Apache-2.0. Third-party data and build-tool notices are in NOTICE. The license permits commercial reuse; it does not grant rights to the Bead Grid Studio name, logo, or third-party marks.

If the project genuinely saves you a manual redraw, consider starring it, sharing it with another maker, or filing a reproducible improvement. Stars never unlock features.

Support & Buy Me a Coffee ☕

If this local-first open-source tool helped your fuse-bead projects, saved you time with color matching, or made your crafting workflow more delightful:

Buying the author a coffee ☕ is warmly appreciated! Your kindness and encouragement keep this project actively maintained and continuously evolving.

WeChat Pay / Sponsor QR Code
WeChat Pay · Feel free to include your GitHub handle in the note so we can acknowledge you!

bead-grid-studio (zwhy149/bead-grid-studio)

Ищем в базе…

Что это?Bead Grid Studio — инструмент с локальной работой в приоритете, превращающий изображение в редактируемый, печатаемый узор из фьюз-бисера (пиньдоу), с автоподбором цветов, координатами сетки и статистикой расхода материалов.
Это десктопное приложение, сайт или то, что я устанавливаю?Это веб-приложение и PWA, полностью работающее в вашем браузере; есть также однофайловая офлайн HTML-сборка для использования без доступа в интернет.
Как начать превращать картинку в узор из бисера?Откройте онлайн-версию, кликните образец изображения или загрузите свой PNG/JPG/WebP/GIF, выберите размер сетки или реальную платформу, подправьте цвета или доработайте кистью, затем экспортируйте узор как PNG или сохраните проект как JSON.
Нужно ли что-то устанавливать для использования?Обычным пользователям ничего устанавливать не нужно; просто откройте веб-приложение или скачайте офлайн HTML-файл. Только разработчикам, желающим собрать из исходников, нужен Node.js 22.12 или выше.
Маленькие размеры сетки точно воспроизведут моё изображение?Нет — в сетке 16x16 всего 256 ячеек, поэтому детали меньше одной бусины (тонкие линии, мелкий текст, блики) не все можно передать; инструмент защищает ту структуру, которую может, и сообщает о том, что не вмещается, вместо имитации идеала.
Можно пользоваться полностью офлайн?Да, можно скачать с Releases единый самодостаточный HTML-файл, работающий офлайн в любом современном браузере, или установить PWA на домашний экран после одной онлайн-загрузки.
Какая палитра используется для подбора бусин?Используется фиксированный источник данных под лицензией MIT с базовым подмножеством из 221 цвета (категории A-H, M), совместимый с MARD: 220 непрозрачных цветов идут в квантование, а прозрачный цвет H1 зарезервирован для ручной расстановки.
Можно сделать форк и свою версию с собственным брендом?Да, форки явно поддерживаются для развёртывания своего сайта, смены брендинга, добавления проверенных палитр, улучшения алгоритма конвертации или добавления новых языков, с управляемым процессом деплоя на GitHub Pages или Cloudflare Pages.
Какая помощь в сборке из бисера есть помимо генерации узора?Есть помощник «цвет за цветом», подсвечивающий по одному цвету бусин за раз, отслеживающий прогресс выполнения по цветам с локальным сохранением и экспортирующий список материалов в UTF-8 CSV с кодами цветов, количествами и статусом выполнения.
Какие форматы изображений и раскладки платформ поддерживаются?Принимаются изображения PNG, JPG, WebP и GIF, поддерживаются распространённые размеры реальных платформ вроде 2.6mm и 5mm, с центрированным узором без растяжения пропорций.
Какие есть похожие проекты?VibeOffice, beadrelief, squoosh, slimdeer, piskel, workbox, Free-GST-Billing-Software, reelmimic
Автор
zwhy149
Размер
2.8 MB
Звёзды
215
Возраст
3 мес
Коммиты · 90 дней