Houdini 12 Copying and instancing

When you copy or instance geometry onto points, Houdini looks for specific attributes on the destination points to customize each copy/instance.

Attributes

Attribute nameData typeDescription
orientfloat4 (quaternion)Orientation of the copy
pscalefloatUniform scale
scalefloat3Non-uniform scale
NvectorNormal (+Z axis of the copy, if no orient)
upvectorUp vector of the copy (+Y axis of the copy, if no orient)
vvector

Velocity of the copy (motion blur, and used as +Z axis of the copy if no orient or N)

rotfloat4 (quaternion)Additional rotation (applied after the orientation attributes above)
transvectorTranslation of the copy
shop_materialstring

Path to a material. You can add this attribute to points using the Material surface node. When you instance an object onto a point with this attribute, the instanced object uses the given material.

material_overridestring

A serialized Python dictionary mapping parameter names to values. You can add this attribute to points using the “override” controls on the Material surface node. When you instance an object onto a point with this attribute, the instanced object applies the given overrides to its material.

Priorities

  • If the orient attribute exists

    • Use it to orient the copy/instance.

  • If the orient attribute does not exist

    • Orient the copy/instance using N as the +Z axis and up as +Y axis.

    • If N does not exist, use v (velocity) if it exists.

  • If the rot attribute exists, apply it after the above.

  • If pscale exists, use it to scale the to scale the copy/instance (multiplied by scale if it exists).

  • If scale exists, use it to scale the copy/instance (multiplied by pscale if it exists).

  • If trans exists, use it to move the copy/instance.

Or, put another way:

Key: 
O = orient matrix 
S = scale matrix (scale * pscale) 
L = alignment matrix (*) 
R = rot matrix 
T = trans matrix (trans + P) 

(*) The alignment matrix (L) is defined by N or v and up. 

IF N exists AND up exists and isn't {0,0,0}: 
   L = mlookatup(N,0,up) 
ELSE IF N exists: 
   L = dihedral({0,0,1},N) 
ELSE IF v exists AND up exists and isn't {0,0,0}: 
   L = mlookatup(v,0,up) 
ELSE IF v exists: 
   L = dihedral({0,0,1},v) 

IF orient exists: 
   Transform = O*R*S*T 
ELSE: 
   Transform = S*L*R*T 

Instancing and motion blur

Velocity Blur

The shutter open transform is based off the Axis Alignment and Positioning stated above. For the shutter close transform the shutter open transform is used plus the vector v/$FPS * shutter_speed. In the cases where that you have N and a v attribute, N is used to align but v is still used to blur.

Note

v is independent of the transform constructed for the Axis Alignment and Positioning. You can rotate, scale and skew all you want but v = (0,0,1) then your object will be blurred in the z direction.

Transform Blur

Same as Velocity Blur but the Object level transform is also taken into account.

Deformation Blur

The Axis Alignment and Positioning transform is constructed for both shutter open and close, the object level transform is also taken into account. This method is the most accurate.

Examples

(The image in the lower right corner of each frame is the geometry if it were instanced without any of the attributes.)