Repository navigation
Commit a89db99
committed
Build patches from several shapes and lighting conditions
A patch is now a grid rather than two fixed tiles: the shapes ticked
in the Patch panel run across it, the lighting conditions ticked
there run down it, and the whole thing is one image per material in
materials/ as before.
Shapes
- Flat swatch, sphere, cube and cylinder, ticked individually; the
default pair reproduces the patch earlier versions rendered
- The solids are built to sit inside one bounding sphere and share
one three-quarter camera, so each fills as much of its tile as its
own form allows and the texture reads at one scale across a row.
Framing solves asin(r/d) against the sphere, not the tangent
against a bounding box, which left the subject at a fifth of its
tile
- The cylinder lies on its side. Upright, every wall normal is
horizontal while a preset's lights are all above, so the lower
half turned away from all of them at once and the base went black
- Only the flat swatch takes the straight-on orthographic camera, so
one repeat fills its tile exactly
Lighting conditions
- Taken from the lighting presets the Stage panel uses, built-in and
saved, ticked in a list of their own and refreshed on demand.
Switching to the Patches part fills the list, so it is never stale
from another file or machine
- No Lights is left out: a patch scene has no HDRI and the swatch
would come out black. With nothing ticked, one row under a
built-in studio rig
- Presets are stored relative to the subject's size, so they rebuild
around a patch shape unchanged: a swatch under Studio Soft is lit
the way a product at a Target Size of 1.0 is
- Pre-flight warns when a ticked preset can no longer be read, which
would otherwise drop a row without saying so
Grid
- Column headings, row labels and the material's name, drawn with
the same blf path the contact sheets use, and switchable off
- Tiles render on transparent film and composite onto the grid's
white background
- Tile Size is now the size of one tile rather than of one half
Variants
- The Patch panel is gone from the Variants part, which is about
textures on products. A job file can still set pool_patches for a
run that wants both
Tests
- test_parts.py covers the shape meshes, which camera each asks for,
the lighting list and its ticks surviving a refresh, grid growth
in both axes, and how much of its tile each shape fills
- test_materials.py reads tiles at computed offsets with labels off,
rather than splitting the image in half1 parent da88e1e commit a89db99
4 files changed
Lines changed: 644 additions & 120 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
29 | | - | |
| 29 | + | |
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
| |||
484 | 484 | | |
485 | 485 | | |
486 | 486 | | |
487 | | - | |
488 | | - | |
| 487 | + | |
| 488 | + | |
| 489 | + | |
| 490 | + | |
| 491 | + | |
| 492 | + | |
| 493 | + | |
| 494 | + | |
| 495 | + | |
| 496 | + | |
| 497 | + | |
| 498 | + | |
| 499 | + | |
| 500 | + | |
| 501 | + | |
| 502 | + | |
| 503 | + | |
| 504 | + | |
| 505 | + | |
| 506 | + | |
| 507 | + | |
| 508 | + | |
| 509 | + | |
| 510 | + | |
| 511 | + | |
| 512 | + | |
| 513 | + | |
| 514 | + | |
| 515 | + | |
| 516 | + | |
| 517 | + | |
| 518 | + | |
| 519 | + | |
| 520 | + | |
| 521 | + | |
489 | 522 | | |
490 | 523 | | |
491 | 524 | | |
492 | 525 | | |
493 | | - | |
494 | | - | |
495 | | - | |
| 526 | + | |
| 527 | + | |
| 528 | + | |
| 529 | + | |
| 530 | + | |
| 531 | + | |
| 532 | + | |
| 533 | + | |
| 534 | + | |
496 | 535 | | |
497 | | - | |
498 | | - | |
499 | | - | |
500 | | - | |
501 | | - | |
| 536 | + | |
| 537 | + | |
| 538 | + | |
502 | 539 | | |
503 | 540 | | |
504 | 541 | | |
| |||
559 | 596 | | |
560 | 597 | | |
561 | 598 | | |
| 599 | + | |
562 | 600 | | |
563 | 601 | | |
564 | 602 | | |
| |||
0 commit comments