On this page |
Houdini’s geometry attributes have a bit of metadata specifying whether the data in the attribute represents some kind of transformation (for example, a position or rotation), and if so, whether/how it should be modified when the geometry itself is transformed.
Houdini understands the following type info values:
|
Don’t transform. |
|
Apply scales, rotations, and transformations. |
|
Apply scales, rotations, and transformations to this vector4. |
|
Apply scales and rotations, but not transformations. |
|
Apply rotations, apply scales with inverse-transpose. |
|
Don’t transform. |
|
Apply scales, rotations, and transformations to this matrix. |
|
Apply rotations. |
|
Don’t transform. |
|
Do not blend this value when points are averaged. |
|
Integer values that blend when points are averaged. |
|
Don’t transform, and try to preserve seams when interpolating. Attributes with this type will show up in the UV viewport menu. |
Generic functions ¶
These versions let you specify the component level of the attribute as an argument. This can be useful to write generic code that can work with different types of attributes.
Sets the meaning of an attribute in geometry.
int setattribtypeinfo(int geohandle, string attribclass, string name, string typeinfo)
geohandle
A handle to the geometry to write to. Currently the only valid value is 0
or geoself(), which means the current geometry in a node. (This argument may be used in the future to allow writing to other geometries.)
attribclass
One of "detail"
(or "global"
), "point"
, "prim"
, or "vertex"
.
You can also use "primgroup"
, "pointgroup"
or "vertexgroup"
to read from groups.
name
The name of the attribute for which to change the transformation info.
typeinfo
The meaning of the attribute, which is used by transform nodes to determine how to modify the attribute. It is one of:
|
Don’t transform. |
|
Apply scales, rotations, and transformations. |
|
Apply scales, rotations, and transformations to this vector4. |
|
Apply scales and rotations, but not transformations. |
|
Apply rotations, apply scales with inverse-transpose. |
|
Don’t transform. |
|
Apply scales, rotations, and transformations to this matrix. |
|
Apply rotations. |
|
Don’t transform. |
|
Do not blend this value when points are averaged. |
|
Integer values that blend when points are averaged. |
|
Don’t transform, and try to preserve seams when interpolating. Attributes with this type will show up in the UV viewport menu. |
Returns the transformation metadata of a geometry attribute.
string attribtypeinfo(<geometry>geometry, string attribclass, string attribute_name)
This general form lets you specify the attribute “class” at run-time. This can be useful for writing general code that can work on different classes. If you know the attribute class ahead of time, using detailattribtypeinfo(), primattribtypeinfo(), pointattribtypeinfo(), or vertexattribtypeinfo() may be faster.
<geometry>
When running in the context of a node (such as a wrangle SOP), this argument can be an integer representing the input number (starting at 0) to read the geometry from.
Alternatively, the argument can be a string specifying a geometry file (for example, a .bgeo
) to read from. When running inside Houdini, this can be an op:/path/to/sop
reference.
attribclass
One of "detail"
(or "global"
), "point"
, "prim"
, or "vertex"
.
You can also use "primgroup"
, "pointgroup"
or "vertexgroup"
to read from groups.
attribute_name
The name of the attribute (or intrinsic) to read.
Returns
A string indicating the metadata for a given geometry attribute, or the empty string (""
) if the attribute does not exist.
|
Don’t transform. |
|
Apply scales, rotations, and transformations. |
|
Apply scales, rotations, and transformations to this vector4. |
|
Apply scales and rotations, but not transformations. |
|
Apply rotations, apply scales with inverse-transpose. |
|
Don’t transform. |
|
Apply scales, rotations, and transformations to this matrix. |
|
Apply rotations. |
|
Don’t transform. |
|
Do not blend this value when points are averaged. |
|
Integer values that blend when points are averaged. |
|
Don’t transform, and try to preserve seams when interpolating. Attributes with this type will show up in the UV viewport menu. |
Component specific functions ¶
These versions let you read the type info for attributes on different component types. These may be slightly more convenient to write than the generic version, and slightly faster, if you know ahead of time what component level the attribute is on – detail (whole geometry), primitive (for example, polygon faces), points, or vertices.
Returns the type info of a geometry attribute.
string detailattribtypeinfo(<geometry>geometry, string attribute_name)
Returns the type info of a geometry attribute.
string primattribtypeinfo(<geometry>geometry, string attribute_name)
<geometry>
When running in the context of a node (such as a wrangle SOP), this argument can be an integer representing the input number (starting at 0) to read the geometry from.
Alternatively, the argument can be a string specifying a geometry file (for example, a .bgeo
) to read from. When running inside Houdini, this can be an op:/path/to/sop
reference.
Returns the type info of a geometry attribute.
string pointattribtypeinfo(<geometry>geometry, string attribute_name)
<geometry>
When running in the context of a node (such as a wrangle SOP), this argument can be an integer representing the input number (starting at 0) to read the geometry from.
Alternatively, the argument can be a string specifying a geometry file (for example, a .bgeo
) to read from. When running inside Houdini, this can be an op:/path/to/sop
reference.
Returns the type info of a geometry attribute.
string vertexattribtypeinfo(<geometry>geometry, string attribute_name)
<geometry>
When running in the context of a node (such as a wrangle SOP), this argument can be an integer representing the input number (starting at 0) to read the geometry from.
Alternatively, the argument can be a string specifying a geometry file (for example, a .bgeo
) to read from. When running inside Houdini, this can be an op:/path/to/sop
reference.