-
Notifications
You must be signed in to change notification settings - Fork 56
Description
Goal
Problem / Question
I’m trying to generate UV map templates programmatically for twisty puzzles, so that I know exactly where each pixel of a texture ends up on the 3D model.
Today, I generate these templates manually (by trial and error), which works for simple cuts but quickly becomes impractical for:
- Dodecahedrons
- Unusual cuts
- New puzzle types
What I’m looking for is essentially a way to reverse the UV mapping:
- Given a puzzle definition and its UVs
- Generate a 2D template (net / sprite layout)
- Where each face region corresponds exactly to how textures are read by the renderer
This would allow artists (and myself) to design textures without guessing or manual UV tweaking.
What I’ve Tried
- Looked through Twizzle / cubing.js source code
- Inspected how UVs are consumed by the renderer
- Manually generated texture templates by projection and adjustment
This approach does not scale and is error-prone, especially for non-cubic puzzles.
Texture templates I created manually:
Questions
- Is there an existing way to export or derive UV templates from puzzle definitions?
- Would it be feasible to expose a helper or debug mode that outputs a UV layout image?
- Is there a recommended approach for generating these templates for arbitrary puzzles (not just standard puzzles but custom cut puzzles)?
Goal
To be able to automatically generate texture templates that accurately reflect:
- Easy identification of each face
- Easy identification of each sticker
- Make this work to any puzzle, even for custom cut puzzles (those created with Twizzle Explorer)
This would greatly help developing and brainstorming new puzzle types. A sticker mod increases astronomically the possibilities for puzzle creation.
Possible solution
Implement a function that generate the proper uv template for the current puzzle, so we can edit in a graphic software of our choice and load as "experimental sprite texture" in the future.
Alternatives
No response