Method Reinit
Reinit(Vector3, Vector3, int, Mesh, int, float, float)
Reinitialize the baker with the new mesh and provided parameters.
Declaration
public void Reinit(Vector3 sizeBox, Vector3 center, int maxRes, Mesh mesh, int signPassesCount = 1, float threshold = 0.5, float sdfOffset = 0)
Parameters
Type | Name | Description |
---|---|---|
Vector3 | sizeBox | The desired size of the baking box. |
Vector3 | center | The center of the baking box. |
int | maxRes | The resolution along the largest dimension. |
Mesh | mesh | The Mesh to be baked into an SDF. |
int | signPassesCount | The number of refinement passes on the sign of the SDF. This should stay below 20. |
float | threshold | The threshold controlling which voxels will be considered inside or outside of the surface. |
float | sdfOffset | The Offset to add to the SDF. It can be used to make the SDF more bulky or skinny. |
Reinit(Vector3, Vector3, int, List<Mesh>, List<Matrix4x4>, int, float, float)
Reinitialize the baker with the new lists of meshes and transforms, and provided parameters.
Declaration
public void Reinit(Vector3 sizeBox, Vector3 center, int maxRes, List<Mesh> meshes, List<Matrix4x4> transforms, int signPassesCount = 1, float threshold = 0.5, float sdfOffset = 0)
Parameters
Type | Name | Description |
---|---|---|
Vector3 | sizeBox | The desired size of the baking box |
Vector3 | center | The center of the baking box. |
int | maxRes | The resolution along the largest dimension. |
List<Mesh> | meshes | The list of meshes to be baked into an SDF. |
List<Matrix4x4> | transforms | The list of transforms of the meshes. |
int | signPassesCount | The number of refinement passes on the sign of the SDF. This should stay below 20. |
float | threshold | The threshold controlling which voxels will be considered inside or outside of the surface. |
float | sdfOffset | The Offset to add to the SDF. It can be used to make the SDF more bulky or skinny. |