# Table Die 2.0 for Houdini Build a die in Solaris, inspect the ideal numbered faces and extract a rounded collision hull from the same shape. Change the finish without redrawing a single numeral. The example rig is a metre-scale tabletop with a macro camera, a notebook and six area lights. **Distribution 2.0.2.** This corrects the documentation checksums in 2.0.1. The tested 2.0 generator and licence terms are unchanged. To verify the extracted files, run `sha256sum -c SHA256SUMS` inside the Table-Die-2.0 folder on Linux. Read [rights and compatibility](RIGHTS.md) before sharing or using this in a production pipeline. ![Raised brass example](Examples/Cloisonne.jpg) ## Quick start · native Indie asset 1. Extract the folder. In a fresh Houdini Indie session use **Assets → Install Asset Library** and select **Dice.hdalc**. Keep it available when reopening scenes. 2. Open **Examples.hiplc**. Switch to Solaris and go to **/stage**. Select **TableDie** and keep the display flag on **Studio**. Choose **/Studio/Camera** and **Karma CPU** in the viewport. Allow time for the first geometry cook and shader compilation. 3. In **Shape**, choose D6 to see pips. In **Markings**, clear **Use pips on D6** to get numerals. Return to D20, enable **Raised marks in a panel**, select **Liberation Serif Bold**, then click **Cloisonne** under **Recipes** as your starting point. For the illustration set Handling wear to 0.14, Fill transmission to 0.68 and Foil diameter to 0.088 mm. Structural density stays unchanged. 4. Save your own scene under a new name. In another scene install the library and use Tab → **Table Die** in a LOP network. For a still, append your usual Karma render settings and render node after Studio, select its camera, set a writable output path and use 1920 × 1080 at 64 pixel samples as a starting point. ## Source route · one Python file Use a fresh licensed Houdini session. Inspect **standalone.py** before execution. In **Windows → Python Shell** run the following after replacing the path. ~~~python import runpy runpy.run_path(r"/path/to/standalone.py", run_name="__main__") ~~~ This creates an ordinary editable subnet and the example Studio LOP under /stage. It reads no HDA or scene. The file contains the algorithms, guide coordinates, studio source, two base64-encoded fonts and their notices. The network retains these resources when saved. The script respects the running application's license. Commercial use and compatibility are unconfirmed. For easier study, **rebuild.py** implements the same route in separate files. Keep it beside **kernel.py**, **envelope.py**, **outlines.py**, **frames.json**, **studio.py**, **foil.py** and **Fonts/**. Run it the same way. To build just the die, use `runpy.run_path(path)["build"]()`. In the subnet, open Shape_and_markings → sopnet → create to inspect the three branches. Recipes holds shared source, guide records and fonts in node user data. The finished geometry exits OUT. Body_and_fill contains the MaterialX network. ## Independent reconstruction Give the entire **PROMPT.md**, including its coordinate appendix, to a coding assistant with permission to work in a clean local Houdini scene. Ask it to report failed tests. Expect implementation differences. The prompt contains no executable asset definition. ## Shape and reading | Choice | Nominal dimension in mm | Reading | |---|---|---| | D4 | Edge 21 | Read the tip shared by three faces. The supporting face stores that opposite result. | | D6 | Across flats 16 | Opposites total 7. Pips or digits. | | D8 | Pole span 25.2 | Opposites total 9. | | D10 units | Pole span 24.4 | 0 means 10 alone, or 0 units with Tens. | | D10 percentile | Pole span 24.4 | 00–90 by tens. Together 00 and 0 mean 100. | | D12 | Across flats 18.8 | Opposites total 13. | | D20 | Across flats 20 | Opposites total 21. | Dimensions describe the sharp mathematical reference. Rounding shortens pointed spans. **Override nominal size** scales geometry and details uniformly from that reference. The default Studio rests the die on a support face and presents the highest stored face value. For a D4 the chosen face goes underneath. Camera framing follows overall scale and shifts the subject slightly off centre. A close crop is possible on large or pointed shapes. ## Controls and practical limits | Section | What changes | |---|---| | Shape | Overall reference size 6–50 mm. Edge and corner rounding share one nominal radius of 0.1–1.2 mm. Round divisions 2–10. Proxy divisions 1–4. Give every chained node a unique USD name and place instances with downstream transforms. Studio is intended for one centered die. | | Output | Finished has separate Body and Fill meshes. Ideal carries face_id, value, face_normal and face_up, plus apex_value on D4 points. Proxy is a convex hull of rounded samples. Export whichever branch you need with a downstream USD ROP. | | Markings | Cut depth .22–.65 mm, fill height .05–.48 from floor, lip bevel .008–.04, draft 0–3°. Keep more than .07 mm above the fill at nominal scale. Raised mode keeps crowns .045 below contact and offsets the panel .2–.9 inward from the tangent boundary. Mark scale .75–1.17. D6 pip pitch 2.5–4.3 and diameter 1.2–3.4. | | Fonts | Two bundled bold faces and a custom TrueType path. Keep custom files available and check redistribution rights. Orientation dots disambiguate inverted labels. | | Mass estimate | At the finished OUT SOP inspect detail attribute estimated_mass_kg. Signed shell volumes are weighted by independently assumed densities in g/cm³. Defaults 1.16 body and 1.3 fill approximate resin. Change the body to about 8.5 only if modelling solid brass. The visual Bronze recipe never changes density. | A slider's limits apply to that field alone. For intersecting or crowded contours, reduce mark scale, bevel, draft or border. For overlapping pips, widen spacing or reduce diameter. Use simple outlines with all decimal digits. Check custom glyphs and extreme combinations in wireframe. The tessellator may reject complex outlines. No guarantee of printability, balance, watertightness for arbitrary edits or physically calibrated dynamics is made. Proxies are approximations. Validate collision margins in your solver. If the view looks flat, select Karma and allow the MaterialX graph to compile. Generic USD preview shading may omit procedural color or transmission. If geometry disappears, inspect node errors, verify the selected output and use unique simple USD names. If imports or GLU fail, compare your runtime with the tested environment in RIGHTS.md. The optional camera script expects the generator directly upstream and default metre/Y-up Solaris settings. ### Try a controlled edit Compare [the original six](Examples/Six.jpg) and [its orange repaint](Examples/SixInk.jpg). Trace the small island inside the loop. Both use exactly the same geometry. In **Fill**, change **Pigment** to (.94, .13, .025) in linear RGB. Compare that with changing **Fill height** under **Markings** on a pip die. One changes the way the paint reflects light. The other changes the shadow on the wall of the recess. See [validation](VALIDATION.md) for camera settings and examples. ## Eight finishes to try Use **Recipes** as a starting point. Each button restores both materials, handling wear and foil settings. It keeps size, marks, densities and all three seeds. Use Houdini Undo if you want the previous edits. The same geometry works in two opposite ways. Engraving puts Fill inside the symbol. Raised mode puts Fill around it. | Recipe | What to inspect | |---|---| | Lagoon | Opaque teal with cream marks. Change the Fill color for an immediate contrast test. | | Porcelain | Warm white plastic and dark paint. Raise wear under Pattern and wear to see the softer reflections. | | Bronze | Warm metal and plain green inlay. Enable raised marks for a shallow enamel field. | | Amber | A tint that deepens through longer optical paths. Reduce Tint distance for stronger absorption. | | Tide | Warped green and blue pigment. Try pattern seed 11. Increase Blend softness to diffuse the boundaries. | | Pearl | Warm satin with anisotropic highlights, sheen and clear polish. This is a stylized surface finish. | | Amethyst | Purple transmitting resin with separate metallic discs inside it. Turn Foil off to compare. | | Cloisonne | Choose raised marks, Liberation Serif Bold, then this recipe. Brass surrounds blue enamel with fine gold foil. | ### Reproduce the macro photograph Open the example, leave the D20 at its original size and use the Cloisonne instructions above. Use the camera at **/Studio/Camera**. The supplied scene builds the oak surface, notebook, soft lights and macro lens from primitives and MaterialX. Save a linear RGB beauty EXR in your own render location. Start at 1920 × 1080. Increase samples if the tiny highlights or defocused areas break up. For the optional Linux display conversion run `hython preview.py my.exr my.png` with a new output path. The script uses Open Image Denoise from Houdini on CPU, retains ten percent of raw RGB by default, rolls off bright channels and applies the sRGB display transfer. Set `--strength 0` for raw detail or `--neutral` to omit exposure and highlight compression. Inspect raw frames at full size when tuning speckles. The example images use this same accessible workflow or direct sRGB conversion. For the plain comparison view, duplicate Studio and replace its Python code with **neutral.py**. Choose Lagoon and set Handling wear to zero. The diagnostic camera frames nominal sizes. The portrait rig follows overall scale and seats the die using the lowest transformed mesh point. Keep the die directly upstream of either studio script. ### Follow the graph In the editable source subnet open **Shape_and_markings → sopnet → create**. Cut_and_fill makes the shell and pigment. Include_foil bypasses the particle cook until enabled. Representation selects finished, ideal or proxy. Follow **Body_and_fill** in Solaris for shader nodes. The finish graph gets object position, scales and offsets it with the casting seed, then adds a vector fractal to bend the coordinates. A second fractal evaluated there feeds smoothstep. Its two thresholds are minus and plus Blend softness. Two independent mixes use this field for the body and pigment. Their colors also drive thickness-dependent transmission. This produces continuous surface variation and tinted paths. The private heterogeneous volume setup is outside the teaching package. For a manual rebuild, place an object-space MaterialX Position, Vector3 Multiply, Vector3 Add, Vector3 Fractal3D, Vector3 Add, Float Fractal3D, Float Smoothstep and Color3 Mix in a Material Library. For Tide use a frequency of 110 per metre on each axis. Add seed times (.113, .179, .233). Feed that coordinate to a four-octave vector fractal with amplitude (2.5, 1.35, .8). Add the displacement back to the coordinate. Feed the result to a five-octave scalar fractal. Smooth from −.33 to +.33 and connect to Mix. Set background (.005, .052, .135) and foreground (.045, .74, .59). Drive base and transmission colors of Standard Surface with the result. Use transmission .69, specular roughness .16, coat .18, tint distance .012 metres and neutral transmission scatter (9,9,9). Connect to MaterialX Surface Material, mark it as a material and assign it to Body. **rebuild.py** provides all exact controls, expressions and names. Handling wear combines fine isotropic noise, directional streaks isolated by a threshold and broader patches of roughness. A separate translation keeps wear independent of pigment. Changing a color or roughness leaves mesh data intact. Keep a copy of the scene to retain the chosen parameter values, including seeds. ### Foil Choose the host under **Foil → Inside**. Increase its transmission to make buried particles visible. Body placement uses a conservative inset core behind all recesses. If an unusual construction yields no cap triangles, turn foil off and check the Fill mesh before continuing. Fill placement samples upper cap triangles in proportion to area. It contracts each triangle toward its incenter and constrains vertical depth by the flake's bounding radius. Small triangles lose candidates, particularly around tight glyphs. Reduce diameter if too few fit. The actual count appears as **foil_count** on OUT. For an engraved die, Fill means the lettering or pips themselves. These are thin, double-sided reflective hexagons. They add no mass to the shell estimate. They can intersect one another at high densities. Very small flakes require extra samples. Keep the same particle seed while adjusting foil color and roughness to compare glints at fixed positions. For an independent casting change the pattern, wear and particle seeds separately. ### Control ranges | Folder | Inputs | |---|---| | Body and Fill | Linear RGB swatches. Roughness .03–.8, metalness and transmission 0–1. Body IOR 1–2, tint distance 1–50 mm, neutral scatter 0–60 per metre, clear polish and satin 0–1. Fill tint distance .02–3 mm. Both blend weights 0–1. | | Pattern and wear | Frequency 30–1600 per metre, curl 0–4, softness .02–.8, handling wear 0–1. Pattern and wear seeds 0–9999. | | Foil | 50–25000 candidate discs. Nominal diameter .02–.24 mm before seeded variation from .5 to 1.35 times and uniform overall scaling. Seed 0–9999, roughness .05–.65. | ## Scope and release notes Version 2.0 retains the seven original face maps and adds the portrait scene, adjustable pigment, surface wear and reflective inclusions. The download covers static assets. Simulation, targeted results and production character resources belong to the separate production pipeline. See [validation](VALIDATION.md) for test coverage and [rights](RIGHTS.md) for license boundaries.