This page provides a tutorial for exporting Alembic files from Houdini and rendering them in 3ds Max using V-Ray.
This guide walks you through the process of exporting Alembic files from Houdini. We go over the general workflow for exporting Geometry, Particles and Crowd simulations, taking care to cover some common pitfalls you may stumble upon.
The process of transferring custom attributes and partitioning the alembic archive into custom shapes is explained in-depth.
For readability, this guide is separated into chapters covering the following topics:
You can download the project's files from here:
General Information and Considerations
Detailed information for supported Alembic features can be found at the Alembic Support page for V-Ray Next for 3ds Max.
All custom point attributes are preserved and can be accessed through the Vertex Color Texture 1. You need to feed it to a material, apply that material to a V-Ray Proxy and press the Update button on the texture to refresh the Channel Name drop-down menu on the Vertex Color texture.
A couple of remarks regarding custom attributes:
- If you use a Wrangle node to create a v@my_vector = rand(@ptnum); attribute, Houdini will generate a 3flt class attribute. This will work just fine inside Houdini but if you attempt to export the point cloud as is to the Alembic file, V-Ray won't be able to use this attribute at render time. As per the Alembic format specifications, V-Ray only supports float, vector2, vector3, color3 and color4 attributes. Therefore, when you middle-mouse-button click your Houdini node, my_vector should read as my_vector 3flt (Vec) or my_vector 3flt (Clr). Simply put, my_vector 3flt will not work. You can force Houdini to give you a Vec or Clr class attribute by creating your attribute using an Attribute Create node and then modifying it in the Wrangle node.
- Attempting to feed a custom float attribute to a vector input of the V-Ray material directly from the Vertex Color to the material will produce incorrect renders. Especially if you have many attributes stored in the file. Every 3 Float attributes are represented as a single vector/color attribute - @my_first_float , @my_second_float and @my_third_float will be loaded as the components of a single vector attribute. You need to make sure to specify the correct sub-channel on the Vertex Color texture.
Motion blur / Velocity
In the case of a Single Alembic File holding multiple Frames of data loaded through a V-Ray Proxy:
- Motion blur is calculated automatically by V-Ray based on the transformations and deformations of the geometry stored inside the Alembic file, provided that the point count of the geometry does not change!
- If the point count is changing, V-Ray is NOT able to determine the velocity vectors automatically. Thus, you get no motion blur by default.
- To get motion blur in this situation, you need the v attribute present in the Alembic file. V-Ray reads the v attribute and generates the motion blur effect based on that.
- The v attribute is NOT used if the point count does NOT change. In other words, v is ignored if the topology does not change.
In the case of Multiple Alembic Files holding One Frame of data each, loaded through a V-Ray Proxy: (i.e. $HIP/file_name.$F4.abc imported as file_name.####.abc inside a Proxy)
- Motion blur can NOT be calculated automatically by V-Ray regardless of the topology change. When loading an Alembic file for rendering, V-Ray does not look at (Frame - 1) or (Frame + 1) to determine the transformation/deformation of your mesh.
- Because of (1) , you have to provide a v attribute when exporting your files. The easiest way to do that is to use a Trail SOP in Houdini, set to Compute Velocity mode.
The motion blur information for single versus per-frame Alembic files holds true for all Chapters of this tutorial.
- Need a divide SOP for the inside faces of the fractured pieces - for some reason max is not handling the inside faces of concave fractured pieces - possibly because they're n-gons
- Need to unpack the geometry before export if you want to keep the inside / outside primitive groups. Need to use a name SOP as well in this case - this breaks instancing and likely produces much larger files – need to test.
- Same goes for the Displacement texture param of V-Ray Material - can't use Sub-Object with multiple displacement maps for multiple vray mats
Only 1 GeomDisplacedMesh is exported to vrscene per VRayProxy....can use Multisub tex
- Vertex Color texture is ignored entirely once a VRay Displacement modifier is applied to the geo
- VRScene export on frame > 0 always renders the alembic file at frame = 0
- Can't assign a random material based on the name/index pair in the V-Ray proxy - need to manually take care of this with the Sub-Object material
- Because of the above, it's probably best to unpack, name and partition the geometry based on the materials you want to assign in Max
Will do last ....