You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit ca60d32
Browse filesBrowse the repository at this point in the historyBrowse files
fix: color-attribute-wheel presentation, a board on a plinth
Render path only: the zero-thickness disc gets a Solidify body and rests
on a plinth with a strut, instead of hovering above the floor. Contract
and exit codes unchanged on 4.5.11, 5.1.2 and 5.2.1. Also regenerates the
gallery index for all four items.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Signed-off-by: TMHSDigital <154358121+TMHSDigital@users.noreply.github.com>
Copy file name to clipboardExpand all lines: README.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -257,7 +257,7 @@ the compositor on and is exactly zero with it off — and that EEVEE has no `use
257
257
</tr>
258
258
<tr>
259
259
<tdwidth="46%"valign="middle">
260
-
<ahref="examples/color-attribute-wheel/"><imgsrc="examples/color-attribute-wheel/preview.webp"alt="Color attribute wheel: an HSV color wheel disc with a white center fading into a vivid rainbow rim, leaning upright toward the camera on a dark studio floor with a warm light pool behind it" /></a>
260
+
<ahref="examples/color-attribute-wheel/"><imgsrc="examples/color-attribute-wheel/preview.webp"alt="Color attribute wheel: an HSV color wheel board with a white center fading into a vivid rainbow rim, leaning back on a dark plinth on a dark studio floor with a warm light pool behind it" /></a>
<metaname="twitter:description" content="The modern color-attributes API — mesh.color_attributes.new() on the CORNER domain, filled by expanding per-vertex HSV across face corners with foreach_get/foreach_set, then wired into a shader Attribute node." />
<p>The modern color-attributes API — mesh.color_attributes.new() on the CORNER domain, filled by expanding per-vertex HSV across face corners with foreach_get/foreach_set, then wired into a shader Attribute node.</p>
269
269
</header>
270
270
<mainid="main">
271
-
<buttonclass="detail-hero" id="heroZoom" type="button" aria-label="View full size: A disc painted with a full hue wheel that fades to white at the centre.">
272
-
<imgsrc="../assets/color-attribute-wheel-hero.webp" alt="A disc painted with a full hue wheel that fades to white at the centre." width="1280" height="720" />
271
+
<buttonclass="detail-hero" id="heroZoom" type="button" aria-label="View full size: A board painted with a full hue wheel that fades to white at the centre, leaning on a dark plinth.">
272
+
<imgsrc="../assets/color-attribute-wheel-hero.webp" alt="A board painted with a full hue wheel that fades to white at the centre, leaning on a dark plinth." width="1280" height="720" />
273
273
</button>
274
274
<pclass="zoom-hint">Rendered headless by the example itself — click to zoom.</p>
275
275
<divclass="callout"><spanclass="tag">witnesses</span> CORNER-domain attributes are sized to loop count, not vertex count; the check asserts the sizing, that active_color points at it, and that the Attribute node is actually linked to Base Color, not just present.</div>
<p>A runnable example that builds an HSV color wheel disc entirely with <code>bmesh</code> and colors it with <code>Mesh.color_attributes.new()</code> — the modern attributes API, not the deprecated <code>Mesh.vertex_colors</code> alias AI code keeps reaching for. It witnesses the domain trap that comes with it: a <code>CORNER</code>-domain attribute is sized to <code>len(mesh.loops)</code>, not <code>len(mesh.vertices)</code>, so per-vertex data has to be expanded across face corners before it is written. The material wires the same attribute into a Shader <code>Attribute</code> node (<code>attribute_type='GEOMETRY'</code>) feeding Base Color — the step AI code most often skips, leaving the mesh gray even when the attribute data is correct.</p>
282
282
<p><strong>What it witnesses:</strong> a <code>FLOAT_COLOR</code> attribute on the <code>CORNER</code> domain, filled with one <code>foreach_get</code> (loop → vertex index) and one <code>foreach_set</code> (loop color), never a per-loop Python assignment. The check asserts the attribute is sized to the loop count and <em>not</em> the vertex count, that it is <code>color_attributes.active_color</code> (so a renderer or exporter actually picks it up), and that several probe loops match the closed-form HSV value for the vertex they reference. A separate check in the render path confirms the <code>Attribute</code> node is actually linked to Base Color, not just present in the node tree.</p>
283
+
<h2>Staging</h2>
284
+
<p>The disc is zero-thickness, and the still used to show it as a paper-thin oval hovering 8 cm above the floor. The render path now gives it a render-only Solidify body (5 cm) and stands it at the same 52° lean on a dark plinth, with a strut behind it, easel-style. The height is computed so the lowest point of the rim rests on the plinth. The mesh <code>check()</code> asserts is unchanged: the modifier is added after the check and only in the render path. Measured framing on 5.2.1: fill 0.794 y, every margin ≥ 0.094.</p>
283
285
<h2>Run</h2>
284
286
<pre><code># Cheap correctness check (no render) — the CI check:
<imgsrc="../assets/color-attribute-wheel-hero.webp" alt="A disc painted with a full hue wheel that fades to white at the centre." />
670
+
<imgsrc="../assets/color-attribute-wheel-hero.webp" alt="A board painted with a full hue wheel that fades to white at the centre, leaning on a dark plinth." />
<imgsrc="assets/wave-displace-hero.webp" alt="A blue grid surface displaced into rolling sine-wave hills." loading="lazy" decoding="async" />
390
+
<imgsrc="assets/wave-displace-hero.webp" alt="A blue tile whose top is a grid displaced into rolling sine-wave hills, standing on a dark studio floor." loading="lazy" decoding="async" />
<imgsrc="assets/color-attribute-wheel-hero.webp" alt="A disc painted with a full hue wheel that fades to white at the centre." loading="lazy" decoding="async" />
511
+
<imgsrc="assets/color-attribute-wheel-hero.webp" alt="A board painted with a full hue wheel that fades to white at the centre, leaning on a dark plinth." loading="lazy" decoding="async" />
<imgsrc="assets/wooden-barrel-hero.webp" alt="A wooden stave barrel bound by three metal hoops." loading="lazy" decoding="async" />
929
+
<imgsrc="assets/wooden-barrel-hero.webp" alt="A wooden stave barrel bound by four iron hoops, its head made of boards." loading="lazy" decoding="async" />
<pclass="teaches">A procedural wine-cask with croze-seated heads and chord-lofted hoops through UVs, bake, LOD, collider, and Unity glTF, asserting recomputed budgets rather than an API contract.</p>
934
-
<pclass="witnesses"><spanclass="tag">witnesses</span> Recomputed: 7216 tris, two materials with 2512 wood and 1440 metal faces, UVs in 0..1 with zero AABB overlap, outer AABB 0.722×0.714×0.880 m, 20 grounded staves, hoop bite 0.003 m, head-croze gap 0.007 m, LOD ratios in band, convex collider 238 tris, non-empty glTF. --skip-decimate exits 9; --round-band exits 18 on the hoop-seat budget.</p>
933
+
<pclass="teaches">A procedural wine-cask with boarded, croze-seated heads and chord-lofted hoops through UVs, bake, LOD, collider, and Unity glTF, asserting recomputed budgets rather than an API contract.</p>
934
+
<pclass="witnesses"><spanclass="tag">witnesses</span> Recomputed: 7312 tris, two materials with 2584 wood and 1440 metal faces, UVs in 0..1 with zero AABB overlap, outer AABB 0.722×0.714×0.880 m, 20 grounded staves, hoop bite 0.003 m, head-croze gap 0.007 m, four boards per head with 1.5 mm seams, LOD ratios in band, convex collider 238 tris, non-empty glTF. --skip-decimate exits 9; --round-band exits 18 on the hoop-seat budget; --one-piece-head exits 17 on the head-board budget.</p>
<imgsrc="assets/wooden-bucket-hero.webp" alt="A wooden stave bucket with metal hoops and a curved wooden bail handle." loading="lazy" decoding="async" />
1127
+
<imgsrc="assets/wooden-bucket-hero.webp" alt="A wooden stave bucket with three iron hoops and a twisted rope handle through iron ear rings." loading="lazy" decoding="async" />
<pclass="teaches">A procedural coopered pail with a croze-seated floor, chord-lofted hoops, and a round bail through the ear rings through UVs, bake, LOD, collider, and Unity glTF, asserting recomputed budgets rather than an API contract.</p>
1132
-
<pclass="witnesses"><spanclass="tag">witnesses</span> Recomputed: 4872 tris, three materials with 1424 wood, 1020 metal, and 208 rope faces, UVs in 0..1 with zero AABB overlap, outer AABB 0.383×0.346×0.527 m, 16 grounded staves, hoop bite 0.0025 m, bail-ear gap 0.0013 m, LOD ratios in band, convex collider 302 tris, non-empty glTF. --skip-decimate exits 9; --float-handle exits 17 on the bail-ear budget.</p>
1131
+
<pclass="teaches">A procedural coopered pail with a boarded, croze-seated floor, chord-lofted hoops, and a three-strand rope bail through the ear rings through UVs, bake, LOD, collider, and Unity glTF, asserting recomputed budgets rather than an API contract.</p>
1132
+
<pclass="witnesses"><spanclass="tag">witnesses</span> Recomputed: 5458 tris, three materials with 1448 wood, 1020 metal, and 486 rope faces, UVs in 0..1 with zero AABB overlap, outer AABB 0.396×0.346×0.534 m, 16 grounded staves, hoop bite 0.0025 m, bail-ear gap 0.0011 m, three bottom boards, no rope vertex inside an ear plate, LOD ratios in band, convex collider 276 tris, non-empty glTF. --skip-decimate exits 9; --float-handle exits 17 on the bail-ear budget; --sunk-rope exits 17 on the rope-clearance budget.</p>
0 commit comments