Houdini Engine for Maya
 All Files Pages
Mesh

The plug-in supports both inputting and outputting Maya mesh.

Input

Maya mesh is input into a Houdini asset as polygons. When inputting a Maya mesh, the plug-in also includes various other information of the mesh as additional Houdini geometry attributes.

Normals

  • N - vertex float3

Stores the normals of all the vertices.

  • maya_locked_normal - vertex int

Stores whether the normal of the vertex is locked. If the value is non-zero, then the normal is locked. If the value is 0, then the normal is unlocked.

  • maya_hard_edge - vertex int

Stores whether the edge represented by the vertex is a hard edge. In Maya, this is a property on the edge. However, since Houdini doesn't have the concept of edge attribute, the property is stored on the first vertex of the edge. If the value is non-zero, then the edge is a hard edge. If the value is 0, then the edge is smooth.

When building an asset, the "Convert Maya Hard Edge to Group" shelf can be used to convert the maya_hard_edge vertex attribute into the maya_hard_edge edge group. This allows the rest of the asset to work with hard edges as an edge group representation, which is often simpler to work with.

UVs

  • uv, uv2, uv3, ... - vertex float3

Stores the UVs of the vertices. Each UV set is stored as a different attribute.

  • maya_uv_name - detail string tuple (size is the number of UV sets)
  • maya_uv_mapped_uv - detail string tuple (size is the number of UV sets)

This can be used by the asset to lookup the name of the original UV set from Maya. The maya_uv_name stores the original name of the UV sets in Maya, and the maya_uv_mapped_uv stores the name of corresponding vertex attribute in Houdini. The two strings should have the same number of elements.

For example, if the asset expects a Maya UV set named "dirt". First, the asset would search the maya_uv_name string for "dirt", which might be the second element. Then, the asset would access the second element of the maya_uv_mapped_uv string for the corresponding name of the Houdini attribute, which might be uv2.

  • maya_uv_current - detail string

Stores the name of the current UV set.

Color sets

  • Cd, Cd2, Cd3, ... - vertex float3
  • Alpha, Alpha2, Alpha3, ... - vertex float

Stores the vertex color and alpha of each color set. The colors and alphas of each color set are stored as separate attributes. The Alpha attribute is only present if the Maya color set contains alpha.

  • maya_colorset_name - detail string tuple (size is the number of color sets)
  • maya_colorset_mapped_Cd - detail string tuple (size is the number of color sets)
  • maya_colorset_mapped_Alpha - detail string tuple (size is the number of color sets)

This set of attributes can be used by the asset to lookup the name of the original color set from Maya. The maya_colorset_name stores the original name of the color sets in Maya, and the maya_colorset_mapped_Cd and maya_colorset_mapped_Alpha stores the name of corresponding vertex attribute in Houdini.

For example, if the asset expects a Maya color set named "diffuse". First, the asset would search maya_colorset_name for "diffuse", which might be the second element. Then, the asset would access the second element of maya_colorset_mapped_Cd for the corresponding name of the Houdini attribute, which might be Cd2.

  • maya_colorset_current - detail string

Stores the name of the current color set.

Shading Groups

  • maya_shading_group - primitive string

Stores the name of the shading group that is assigned to each polygon.

Sets

All Maya sets that the mesh belongs to are converted into Houdini primitive groups.

Output

Polygons output from a Houdini asset are output as a Maya mesh. When the polygons are output, the plug-in recognizes various Houdini geometry attributes. The recognized attributes are then converted into the Maya equivalent.

Normals

  • N - vertex float3

Used to set the normals of all the vertices.

  • maya_locked_normal - vertex int

Used to set whether the normal of the vertex is locked. If the value is non-zero, then the normal is locked. If the value is 0, then the normal is unlocked.

  • maya_hard_edge - vertex int

Used to set whether the edge represented by the vertex is a hard edge. In Maya, this is a property on the edge. However, since Houdini doesn't have the concept of edge attribute, the property is stored on the first vertex of the edge. If the value is non-zero, then the edge is a hard edge. If the value is 0, then the edge is smooth.

When building an asset, the "Convert Maya Hard Edge to Attribute" shelf can be used to convert the maya_hard_edge edge group into the maya_hard_edge vertex attribute. This allows the rest of the asset to work with hard edges as an edge group representation, which is often simpler to work with.

UVs

  • uv, uv2, uv3, ... - point|vertex float2|float3

Used to assign UVs of the vertices. Each UV attribute is used for assigning a different UV set.

  • maya_uv_name - detail string tuple (size is the number of UV sets)
  • maya_uv_mapped_uv - detail string tuple (size is the number of UV sets)

This set of attributes is used to map the names of the Houdini UV attributes into the names of the UV set in Maya. The maya_uv_name is used to set the name of the UV set in Maya, and the maya_uv_mapped_uv is the name of the corresponding UV attribute in Houdini. The two strings must have the same number of elements.

If you are adding mapping information to a mesh created in houdini, or adding new UVsets to output on a mesh created in maya, you can use a python sop to create or set the size of the string attributes.

  • maya_uv_current - detail string

Used to set the current UV set.

Color sets

  • Cd, Cd2, Cd3, ... - detail|primitive|point|vertex float3
  • Alpha, Alpha2, Alpha3, ... - detail|primitive|point|vertex float

Used to set the vertex color and alpha of each color set. The Alpha attribute is optional.

  • maya_colorset_name - detail string tuple (size is the number of color sets)
  • maya_colorset_mapped_Cd - detail string tuple (size is the number of color sets)
  • maya_colorset_mapped_Alpha - detail string tuple (size is the number of color sets)

This set of attributes is used to map the names of the Houdini Color and Alpha attributes into color sets in Maya. The maya_colorset_name sets the name of the color sets in Maya, and maya_colorset_mapped_Cd and maya_colorset_mapped_Alpha are used to map the color and alpha attributes in Houdini to the corresponding color set in Maya.

If you are adding mapping information to a mesh created in houdini, or adding new color sets to output on a mesh created in maya, you can use a python sop to create or set the size of the string attributes.

  • maya_colorset_current - detail string

Used to set the current color set.

Shading Groups

  • maya_shading_group - primitive string

Used to assign the named shading group in Maya to the polygon. The shading group must already exist in the scene.

Sets

All Houdini primitive groups are converted into Maya sets. If a Maya set doesn't already exist, it will be created.

Note that Houdini groups can easily change from one cook to the next. Since Maya sets are created and modified at the Dependency Graph level, it is more rigid than Houdini groups. So outputting Houdini groups this way suffers from the sync issue. If a Houdini group changes, this change will not be reflected in Maya until a sync happens.

Unsupported Polygons

Geometries that are output by an asset may occasionally contain polygons that are not supported in Maya. These polygons have multiple vertices referring to the same point, which are used in Houdini for bridges and holes. A common source of these polygons is fractured geometry.

Maya will internally convert these polygons. However, this leads to the topology being changed, and as a result other Houdini attributes (like UVs and colors) can no longer be applied to the converted polygons. When the plug-in detects such polygons, it will print out a warning message.

Multiple Pieces

Input

Multiple Maya meshes can be connected to each asset input. It is possible select a hierarchy, or multiple objects, and do 'Set to Selection'. Each mesh shape is input separately, and all the inputs are then joined together on the Houdini side using a Merge SOP. To add or remove inputs, select the desired inputs and 'Set To Selection' again.

Output

When outputting geometry from Houdini, you may want to want to split up the geometry so that they become Maya mesh objects. For example, when fracturing geometry. Unfortunately, there is no ideal solution at the moment, but there are some workarounds you could try.

One way is to make use of Houdini groups. The asset would put the separate pieces into separate Houdini groups, which would then be converted into Maya sets. Then inside Maya, the Maya sets can be used to identify and manipulate the individual pieces.

Another way is to use Maya's Edit Mesh -> Separate to separate the mesh into different objects. However, this is only possible if the pieces are already separate shells.