feat(tabletop): add tilt and zStart/zEnd stacking options
Replace the per-part lift with a local Y-axis tilt that fans the stack, and add zStart/zEnd to ramp the stack's height across the curve so it arches in 3D. Update the poker deck and docs accordingly.
This commit is contained in:
@@ -359,6 +359,9 @@ layout:
|
||||
limit: 5
|
||||
align: center
|
||||
steps: 4
|
||||
tilt: 0.1
|
||||
zStart: 0
|
||||
zEnd: 30
|
||||
```
|
||||
|
||||
- `curve` — an SVG path string to spread the content along, relative to the
|
||||
@@ -368,6 +371,13 @@ layout:
|
||||
- `align` — `start`, `end`, or `center` of the curve.
|
||||
- `steps` — the maximum number of parts per curve length unit. Defaults to
|
||||
`1`. See the positioning process below.
|
||||
- `tilt` — rotation in radians per shown part about the card's local Y (long)
|
||||
axis. Each part tilts `tilt` more than the previous, fanning the stack so
|
||||
its edges stay visible. It applies even without a `curve`, so a bare `tilt`
|
||||
fans a straight pile.
|
||||
- `zStart` / `zEnd` — the height (surface-normal) in mm at the start and end
|
||||
of the `curve`. The stack ramps linearly between them across its span,
|
||||
lifting it in 3D. Requires a `curve`.
|
||||
|
||||
#### positioning process
|
||||
|
||||
@@ -377,6 +387,10 @@ layout:
|
||||
`step length × (# of parts − 1)` on the curve.
|
||||
3. **Place each part.** Part `#0` is at the start, the last part at the end,
|
||||
each `step length` apart.
|
||||
4. **Lift each part.** The part's height is `zStart + (zEnd − zStart) × u`,
|
||||
where `u` is its normalized position along the `curve`.
|
||||
5. **Tilt each part.** Each part is rotated `tilt × # of parts before it`
|
||||
about its local Y (long) axis.
|
||||
|
||||
### Edge cases
|
||||
|
||||
|
||||
Reference in New Issue
Block a user