Files
2026-07-09 02:59:53 +03:00

42 lines
1.5 KiB
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# Photopea / Photoshop ExtendScript Dataset Generator
This folder contains JSX scripts to generate systematic layer-effect ground-truth images in Photopea or Photoshop.
## Files
- `generate_inner_shadow_dataset.jsx` — Short starter script for Inner Shadow.
## Usage
1. Open Photopea (https://www.photopea.com) in a browser.
2. Press `Alt+Ctrl+I` (or use `File > Automate > Script`) to open the script runner.
3. Paste the contents of the desired `.jsx` file and run it.
4. Select an output folder when prompted.
Photopea will create a new document for each parameter combination, draw a black rectangle, apply the Inner Shadow effect, hide the background, and export a transparent PNG.
## Current parameter grid (short version)
| Parameter | Values |
|---|---|
| angle | 0, 90, 180, 270 |
| distance | 5, 15, 30 |
| size | 10, 30 |
| choke | 0, 20 |
| fx opacity | 75, 100 |
| fx blend mode | Normal, Multiply |
Total images: `4 × 3 × 2 × 2 × 2 × 2 = 192`.
## Notes
- Blend mode keys use Photoshop's 4-character codes (`Nrml`, `Mltp`).
- The output PNGs have transparent backgrounds, so MAE comparisons can ignore white reference pixels if needed.
- ExtendScript error handling is basic; if a parameter combination fails, the script logs it and continues.
## Next steps
- Add more layer blend modes, fill opacity, and layer opacity variations.
- Extend to Drop Shadow, Outer Glow, Inner Glow, Stroke, Bevel & Emboss.
- Add a companion Rust generator that creates matching PSD files so the same dataset can be imported back into HCIE for MAE tuning.