Vertex animation textures is a workflow that enable animating vertices of a mesh, based on data baked into texture objects. These textures contain generally per-pixel data that correspond to the position, normal or other attributes of a particular vertex. The positions can be baked either as absolute, or relative to a reference mesh (for ex: a T-Pose character). VFXToolbox enables the worfklow by providing a Houdini Exporter and some sample assets that you can import in your unity project to handle these textures
## Houdini VAT Exporter (ROP)
### Baking Modes
#### Baking Modes
* *Non-uniform topology* : This mode assumes that the geometry is re-written every frame and will bake the absolute positions of vertices by groups of 3. You have to determine a maximum point count so it will drive the width of the texture. In non-uniform topology mode, degenerate input geometry must be used. There are some bundled in the VertexAnimationTextures Sample of VFX Toolbox.
* *Uniform topology* : This mode
* *Non-uniform topology* : This mode assumes that the geometry is re-written every frame and will bake the absolute positions of vertices by groups of 3. You have to determine a maximum point count so it will drive the width of the texture. In non-uniform topology mode, degenerate input geometry must be used. There are some assets exported with way, already bundled in the VertexAnimationTextures Sample of VFX Toolbox. In a Non-Uniform Topology, only the Positions and the Normals are exported.
* *Uniform topology* : This mode uses a reference mesh as initial pose, so all the positions are not baked as their absolute value, but instead as position differences from the T-Pose. This enables sampling multiple frames and performing blending. Normals are still baked as absolute value in object space.
### Export File Formats:
#### Export Options
Some options enable you to perform some changes before export such as:
* Reverse Frame Order
* Reverse Triangle Winding (Triangles will appear back-face, this can solve some of the inverted faces issues in unity)
#### Export File Formats
### Limitations:
#### Limitations:
* If a Point Normal attribute is not found, the log will output a warning, and the Normal VAT texture will be filled with Up vector constant values)
By deploying the VertexAnimationTextures sample from the VFXToolbox package manager page, you install in the project some assets that you can start with, or use as example to use vertex animation textures. The sample also contains an `AssetPostprocessor` that will configure any texture of extension `tga` or `exr` with the following suffixes `-VATPOS` (Position) or `-VATNRM` (Normals).
By deploying the VertexAnimationTextures sample from the VFXToolbox package manager page, you will install in the project some assets that you can start with, or use as example to use vertex animation textures. The sample also contains an `AssetPostprocessor` that will configure any texture of extension `tga` or `exr` with the following suffixes `-VATPOS` (Position) or `-VATNRM` (Normals).
* __In Uniform topology, the geometry can become garbled__: as if the triangles were in correct place, but somehow rotated. This is related to the winding order of the mesh. Please check the `Optimize Mesh` in the import options and ensure `Vertex Order` is enabled.
* __In Uniform topology, the geometry can become garbled__: as if the triangles were in correct place, but somehow rotated. This is related to the winding order of the mesh. Please check the `Optimize Mesh` in the import options and ensure `Vertex Order` is enabled. Also, the problem can also come from the inverted winding
* __The animation is played backwards__ : This can happen when your texture is baked top to bottom. You can use the Reverse Frame order option in the exporter, or play it backwards (see the ReverseAnimation property in the `VAT-SingleParticle` example)