Documentation
Recipes and the graph
A recipe in Graphite4D is a reusable piece of construction with its own controls, much like a smart component. A structural bay, a stair or a curtain wall panel can each be a recipe. Every copy you insert is an instance. Instances share one definition, and each keeps its own control values. Groups you make with G work the same way, so copies of a group change together until you make one unique.
You can model a whole building without recipes. Use them when you want to reuse a design or drive it with parameters.
Insert a recipe
- Open All tools (⌘ K on a Mac, Ctrl K on Windows).
- Type part of the recipe's name. Recipes are listed under Project recipes.
- Choose it. Graphite inserts an instance, selects it and shows its controls in Properties.
You can also open the Recipe library from the project menu, or press Shift K. On This project, pick a Project definition and choose Insert recipe instance. Shift B inserts a building mass recipe.
Change an instance's controls
Select an instance and open Properties (N). Its published controls are on the Inputs tab. Type lengths in feet and inches, such as 12' 6", then press Enter to apply or Esc to cancel.
- Each field has an options menu. Choose Reset to recipe default to return to the recipe's value.
- Move and Rotate change only the selected instance.
- To change the default for every instance, open the Recipe library, choose the definition and edit its Inherited defaults.
Built-in recipes are locked. To edit one, choose Copy definition in the Recipe library, or make an instance unique.
Open a recipe in place
Double-click an instance in the 3D view, or double-click a recipe's title in the graph. Graphite opens its construction where it sits, in the recipe's own axes. The view menu shows RECIPE and the recipe's name. The rest of the model stays visible for reference; press Shift I to hide or show it.
Changes you make inside a recipe update every instance. To leave, press Esc to go up one level, press Shift U, or choose Close recipe in the graph.
Publish a control
Inside a recipe, select a step, open a field's options menu and choose Publish as recipe input. Enter a Control name and a Display label, then choose Publish control. The field now appears on every instance. To pass geometry into or out of a recipe, use Recipe inputs and outputs in Properties.
To turn existing construction into a recipe, select its last step and choose Group branch as recipe under Node actions in Properties.
Make one copy different
Select the instance, open Node actions in Properties and choose Make unique. Graphite copies the definition, adds "unique" to its name, and points only this instance at the copy. Recipes nested inside it stay shared.
Reuse recipes in other projects
- In the Recipe library, on This project, choose a definition and select Save definition to my library.
- In another project, open My library, choose the recipe and review the listed changes.
- Choose Adopt this version.
A project keeps the version it adopted until you choose an update. After you edit a saved definition, choose Publish a new library version, or Save as a new library item to keep both.
Read the graph
The graph is an optional view of how your model is built. Each step is a node. Connections carry geometry or values from one step's outputs to another step's inputs, and dependencies run left to right. Select a step to see its Inputs and Outputs tabs in Properties. With an element selected, Reveal producing step under Node actions shows the step that made it.
| To | Do this |
|---|---|
| Show or hide the graph | Shift G |
| Resize it | Drag its top edge |
| Use a full-height graph, with the 3D view in a corner | Shift F |
| Add a step | Choose Add step, or double-click empty space |
| Frame or tidy the layout | Fit or Arrange |
| Highlight a step's whole upstream and downstream chain | Trace chain |
A node marked Needs attention has a problem. A node marked Blocked depends on one. Select it to read why.
Some steps have several named outputs. Query / filter has Matched and Unmatched, and Slice has Positive and Negative. Connect whichever you need.
Work with collections
These steps take a collection of elements and produce another. Find them in All tools, or with Add step in the graph.
| Step | What it does |
|---|---|
| Array | Repeats a collection with an X, Y and Z step. Count includes the original. |
| Repeat floors | Stacks a collection vertically by floor height (Shift A). |
| Distribute | Places an assembly at regular stations around a circle or along a path. |
| Query / filter | Keeps a live subset, such as elements with @area > 100sqft. |
| Merge collections | Joins several outputs in a set order without fusing solids. |
| Subdivide | Partitions a profile or curved surface into regions (D). |
A recipe normally runs once with its whole input. If it has a geometry input, you can run it once per item: select the instance and set Repeat to Once for each item of that input. Each run sees one item and shares the instance's controls. Repeat handles up to 500 items, and Array up to 2,000 elements in total.
Use expressions
Any numeric field accepts an expression that starts with =:
=10ft + 6in
Expressions understand ft, in, sqft (or sf), cuft (or cf) and deg. Choose Edit expression beside a field for a larger editor, where Enter applies and Shift Enter adds a line. A Calculated value step holds a named expression that can drive other steps.
Query / filter conditions read attributes with @:
@material == "timber"
hasAttr("facade") && @facade == "curtain wall"
Tag faces and edges, then build on them
Inside a group or other editable geometry, the Paint bucket can tag faces and edges with any attribute, not just a material.
- Press B. Choose Paint options in the toolbar, set Tag to New tag…, type a name such as
facade, and choose Use tag. - Type a Value, such as
curtain wall, and click faces or edges. Option-click on a Mac or Alt-click on Windows samples a value; ⌘-click on a Mac or Ctrl-click on Windows covers connected faces; Shift-click covers every face with the same value. - The legend lists each value with its count and area. Choose Query faces or Query edges to add a Query for that value.
- With the Query selected, open All tools and insert a recipe that has one geometry input. Graphite connects the Query and repeats the recipe for each tagged face or edge.
Split faces keep their tags, and anything you tag later with the same value joins the Query. Union and Subtract keep the tags and paint of the faces they keep, so a combined massing still shows them in Tags and colours by them; faces a cut creates are untagged.