Skip to content

Repository files navigation

Raystones - Free Rhinestone Pattern Generator

GitHub Pages License Python

Convert any image into a rhinestone pattern. Generate SVG, PNG, and PDF files for crafting, custom jewelry design, rhinestone transfers, and DIY projects.

Try it online - No install needed, runs in your browser.

Features

  • 56 professional rhinestone colors - Full SS color library with accurate matching
  • Standard SS stone sizes - SS3 to SS48 (1.3mm to 11mm)
  • Multiple output formats - SVG (vector), PNG (raster), PDF (print-ready)
  • Max colors limiter - Reduce complexity for practical crafting
  • Live preview - See stone placement before generating
  • Unique order codes - Track designs with RH-XXXXXX codes
  • Browser & CLI modes - Use online or offline

Quick Start

Online (No Install)

Visit relharrati.github.io/raystones - upload an image and generate instantly.

Local Server

pip install -r requirements.txt
python server.py

Open http://localhost:8001

CLI Mode

python start.py

Use Cases

  • Rhinestone transfers - Create heat-transfer patterns for t-shirts, hats, and accessories
  • Custom jewelry - Design pendant, earring, and bracelet layouts
  • Nail art - Generate precise stone placement for nail designs
  • Phone cases - Create custom rhinestone patterns for phone accessories
  • Wedding decor - Design table numbers, place cards, and centerpieces
  • Corporate branding - Convert logos into rhinestone designs
  • Photo gifts - Turn portraits into rhinestone art for mugs, frames, and more

Settings Guide

Setting What It Does Best For
Width Image resize width (px) 200-350 for most designs
Spacing Distance between stones 4-6 dense, 8-12 sparse
Threshold Background removal sensitivity 180-220; lower = more removal
Stone Size Physical rhinestone diameter SS10 (2.8mm) most common
Max Colors Limit color count 10-20 for practical use

Examples

Project Settings
Simple logo Width 250, Spacing 5, SS10, Threshold 200
Photo portrait Width 350, Spacing 4, SS6, Threshold 180
Text / typography Width 300, Spacing 6, SS16, Threshold 200
Nail art Width 150, Spacing 3, SS3, Threshold 200
T-shirt transfer Width 300, Spacing 5, SS10, Max Colors 15

Stone Size Reference

Size Diameter Best Use
SS3 1.3mm Nail art, fine detail
SS6 2.0mm Small accents, jewelry
SS10 2.8mm Standard - most versatile
SS16 4.0mm Medium designs, logos
SS20 4.8mm Bold accents, phone cases
SS30 6.5mm Large statement pieces
SS40 8.5mm Centerpieces, decor

Project Structure

raystones/
├── server.py              # FastAPI web server
├── start.py               # CLI mode
├── rhinestone_colors.py   # 56-color SS library
├── rhinestone_sizes.py    # SS size definitions
├── templates/
│   └── index.html         # Server web UI
├── docs/
│   ├── index.html         # Browser-only (GitHub Pages)
│   └── README.md          # Deploy guide
├── requirements.txt       # Python dependencies
└── README.md              # This file

Troubleshooting

  • Too many stones → Increase spacing or reduce width
  • Background not removed → Lower threshold (more aggressive)
  • Too many colors → Use Max Colors slider (10-20 recommended)
  • Color mismatch → Algorithm picks closest available SS color
  • Invalid image → Use JPG or PNG format

Contributing

Pull requests welcome! Feel free to open an issue for bugs, feature requests, or color library updates.

License

MIT License - see LICENSE for details.

About

Convert any image into a rhinestone pattern. Generate SVG, PNG, and PDF files for crafting, printing, and custom jewelry design. Browser-based and CLI tool.

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages