Creates multiple copies of the input geometry, or copies the geometry onto the points of the second input.
The Copy node has two main functions, with the second function being the most useful:
Create multiple copies of the input geometry. You can apply transformations progressively to each copy. So, for example, you could copy a box model into a line-up of identical boxes descending in size.
Copy the first input (source) geometry onto the points of the second input (template) geometry. This is very useful for populating scenes with geometry with full control over the placement of the copies.
For example, you can arrange copies in a spherical shape by copying them onto the points of polygonal sphere. Or you could copy a tree model onto the points of a Grid, then add turbulence to the grid’s points to add randomness to the placement of the trees.
This operator is especially useful for copying geometry onto the points output from a particle system (that is, a POP network SOP). Whereas particle instancing displays the instanced geometry at render time (and is more efficient), using the Copy SOP gives you “real” geometry in the network that you can further manipulate.
See copying and instancing for more information.
Using Copy To Points
Click the
Copy to Points tool on the Modify tab.
Select the source geometry you want to copy and press Enter.
Select the target geometry on whose points to instantiate the source and press Enter.
Instancing point attributes
When you copy or instance geometry onto points, Houdini looks for specific attributes on the destination points to customize each copy/instance. See instancing point attributes.
Tips
When making multiple copies (not copying onto points), use the NCY (number of copies) local variable in an expression to make values independent of the number of copies.
For example, to have the each copy rotated so they go from 0 to 360 degrees, set the rotation to
360/$NCY.You can create multiple copies around an axis, then skin them to create complex lathe-like effects, similar to the results of the Revolve SOP.
To alleviate issues when copying to normals, you can add up vectors to template points or do it in POPs with an Up Vector POP.
Parameters
| Source Group | A subset of the source (first input) primitives to copy from. You can create groups with the Group SOP. |
| Template Group | A subset of the template (second input) points to copy onto. Please note, that only point group specifications are valid for this parameter. |
Copy
| Number of copies | The number of copies of the original geometry. |
| Transform Using Template Point Attributes | Rotates copies to face the template point normals. Also applies translations, rotations and scales according to the trans, rot, and scale point attributes on the template points (if these attributes exist). |
| Transform Cumulative | Each copy is transformed relative to the previous. |
| Transform Order | Order transformations occur. |
| Rotate Order | Order rotations occur. |
| Translate | Translation along xyz axes. |
| Rotate | Rotation about xyz axes. |
| Scale | Non-uniform scaling along xyz axes. |
| Shear | Amount of shearing. The three values represent X on XY plane, X on XZ plane, and Y on YZ plane respectively. |
| Pivot | The local pivot point of the copy. |
| Uniform Scale | Uniform scaling. |
| Preserve Normal Length | Normals to maintain length after transformations. |
| Create Output Groups | Places each copy into a primitive group. |
| Preserve Groups | Don’t delete the contents of the copy group if it already exists before adding the copied primitives. |
| Copy Groups | The name of the group to create for each copy. |
Stamp
Stamping lets you set up values that vary per-copy on the Copy node, and then refer to those variables in the source network using the stamp function. See copy stamping for more information.
| Stamp Inputs | Stamp proceeding variables for each input copied. |
| Variable/Value n | Token and value of each stamp variable. Changes values of parameters which include param function. |
Attribute
The parameters on this tab control how attributes on the template points affect the copies.
| Use Template Point Attributes | Copy attributes from the template points onto the copies, according to the values in the attribute fields below. | ||||||||||
| Attribute fields | (Available when Copy template point attributes is on above.) The columns represent possible ways of combining the attributes from template geometry with the attributes from the source geometry.
The rows represent the different entities you can copy attributes onto: points, primitives, and vertices. At the intersection of each column and row, you can enter a list/pattern of attributes. For example:
|
Inputs
| Source | The geometry to copy. |
| Template | (Optional) Copy the source geometry onto the points of this geometry. |
Local variables
Copy-specific variables.
| CY | The number of the copy currently being generated. Starts at 0. |
| NCY | The total number of copies that will be created (the value of the Number of copies parameter). |
| PT | The point number of the Template being copied onto. If there is
a template group, this will be the index into the group, not
the actual point number. Use |
| NPT | The total number of points in the template geometry. |
| TPT | The actual point number of the currently processed template
point, independent of any template groups. See |
Variables for point attributes on the template.
| AGE | The seconds a particle in the template has been alive. |
| LIFE | The ratio of the age of a particle to its expected life This number is between 0 (when born) and 1 (when about to die). |
| ID | The ID of the particle in the input. |
Variables for the input geometry/template geometry (if there is a template input).
| CEX, CEY, CEZ | The centroid of the geometry. |
| XMIN, XMAX | The X extents of the bounding box of the geometry. |
| YMIN, YMAX | The Y extents of the bounding box of the geometry. |
| ZMIN, ZMAX | The Z extents of the bounding box of the geometry. |
| SIZEX, SIZEY, SIZEZ | The size of the bounding box. |
| BBX, BBY, BBZ | The point’s relative position in the bounding box. |
Standard variables
Note
Variable names ending with 2 refer to the geometry from the second input, if applicable. For example, PT2 is the current point number from the second input.
| AGE | The seconds a particle in the template has been alive. |
| ARC | Arc length distance from root in the L-systems. |
| AREA | The surface area of the primitive (created by the Measure SOP). |
| BBX, BBY, BBZ | The point’s relative position in the bounding box. |
| CA | Point or vertex alpha value. |
| CEX, CEY, CEZ | The centroid of the geometry. |
| COMX, COMY, COMZ | Center of mass. |
| CR, CG, CB | Diffuse point or vertex color. |
| CREASE | Point or vertex crease weight value. |
| CURLAYER | Stores the currently processed layer for texture/materials (set by the Layer SOP). |
| DIST | Distance from particle to last collision. |
| DIV | Number of divisions to build the circle swept with Polywire (created by L-systems). |
| DRAG | Point drag. |
| GEN | Generation in the L-systems. |
| ID | The ID of the particle in the input. |
| LAGE | The age of the point in the L-system computation. |
| LIFE | Percent of total life used (from 0 to 1). |
| LOD | Level of detail. |
| MAPU, MAPV, MAPW | Point or vertex texture coordinates. |
| MASS | Point mass. |
| MAT | The string name of the current material (the value of the
|
| MAXLAYER | The number of layers that are considered active for display. |
| NPT | The total number of points in the template geometry. |
| NX, NY, NZ | Normal vector. |
| PERIMETER | The perimeter of the primitive (created by the Measure SOP). |
| PR, NPR | Primitive number & total number of primitives. |
| PSCALE | Particle Scale. |
| PT | The point number of the currently processed point. |
| RESTX, RESTY, RESTZ | The rest position. |
| SEGS | Number of segments to divide a curve up into in Polywire (created by L-systems). |
| SIZEX, SIZEY, SIZEZ | The size of the bounding box. |
| SPRINGK | Elasticity of a point. |
| TENSION | Spring tension of an edge. |
| TX, TY, TZ | Point position. |
| TW | See WEIGHT. |
| UPX, UPY, UPZ | The vector pointed in the up direction. |
| VTX, NVTX | Vertex number & total number of vertices. |
| VX, VY, VZ | Velocity direction. |
| WEIGHT | Point spline weight. |
| WIDTH | The width of the curve. Used by mantra for rendering curves & polywire for generating trees. |
| XMIN, XMAX | The X extents of the bounding box of the geometry. |
| YMIN, YMAX | The Y extents of the bounding box of the geometry. |
| ZMIN, ZMAX | The Z extents of the bounding box of the geometry. |
Examples
| CopyAttributes | Load | Launch |
The Copy SOP can be used for more than copying geometry. In this example, the Copy SOP is used to transfer color attributes from the template geometry (or point) to the copied geometry. A polygonal sphere with color infomation is used as the source geometry. A point with a color attribute (Cd) is extracted from the sphere and used as a template by the Copy SOP. Then the Copy SOP transfers the color infomation to a copied polygonal circle. | |
| CopyCubes | Load | Launch |
This network shows the most basic example of how to use a particle system to copy geometry. A Copy SOP is used to reference a POP network (which included a Source and Drag POP) while copying a box object to every birthed particle. Play the animation to see the result. | |
| CopyTemplateAttribs | Load | Launch |
The Copy SOP is used to transfer specific attributes from a template to copied primitives. In this example, a sphere is use as a template with color attributes added to the sphere points. A Particle SOP is then used to birth particles from the sphere points. Next, a Copy SOP does two things: It copies geometry to the particles. It transfers the color attribute from the source sphere points to the geometry whose position is based on the particles. Play the animation to see the effects. | |
| ParticleCopyScale | Load | Launch |
The Copy SOP is used to copy geometry to particles using the Particle SOP as a template. In the example, the Scale parameter of the Copy SOP is used to create the specific effect. The Copy SOP may also be used to control different attributes of the copied geometry beyond mere scale. Play the animation to see the effects. | |
| StampRandom | Load | Launch |
In this example, the Copy SOP is used to randomly copy various objects onto points of a given template geometry. We use the stamp capability of the Copy SOP for our purpose. Furthermore, the entire process is kept procedural so that we have the option of determining the type and the number of geometries to be copied and the kind of template to be used. Inside the Stamp tab of the Copy SOP we create a variable named “switch” which will drive the input value of the Select Input parameter in the Switch SOP. In turn, the Copy SOP is able to copy at random any number of input geometry to template points. | |
| StampStars | Load | Launch |
This example demonstrates the power of the Copy SOP’s Stamp operation. Here, a Copy SOP is used to copy a circle onto the points of a sphere. The Stamp operation then applies various modifications to those copies based on division, scale, color, and extrusion. This results in the generation of a randomized variety of “stars”. Starting with a simple circle, a large number of variations are created using in the copies through the use of Stamping with expressions. | |
| VelocityStamp | Load | Launch |
This example demonstrates the use of the Stamping function within the Copy SOP. The Copy SOP creates multiple copies of its source geometry. The Stamping function allows for individual variations in each of these copies. Press play to see the animation. | |