Contents
Overview and notes
The ClothSerializeData2 class holds private parameters that are referenced by the system.
Unlike ClothSerializeData, it is not recommended to change the contents.
However, it is documented as it may be required if users create their own extensions.
Access
ClothSerializeData2 is private and cannot be accessed directly.
Please use GetSerializeData2() of the MagicaCloth component to access it.
public ClothSerializeData2 GetSerializeData2()
Properties
selectionData
/// <summary>
/// vertex paint data.
/// </summary>
[SerializeField]
public SelectionData selectionData = new SelectionData();
/// <summary>
/// 頂点の属性情報(移動/固定/無効)データ
/// このデータはシリアライズされる
/// 座標はクロスコンポーネントのローカル空間で格納される
/// Vertex attribute information (move/fix/disable) data.
/// This data is serialized.
/// Coordinates are stored in the cloth component's local space.
/// </summary>
[System.Serializable]
public class SelectionData : IValid
{
/// <summary>
/// 属性のローカル座標
/// これはクロスコンポーネント空間
/// Attribute local coordinates.
/// This is the cloth component space.
/// </summary>
public float3[] positions;
/// <summary>
/// 上記の属性値
/// サイズはpositionsと同じでなくてはならない
/// Attribute value above.
/// size must be the same as positions.
/// </summary>
public VertexAttribute[] attributes;
/// <summary>
/// セレクションデータ構築時のVirtualMeshの最大頂点接続距離
/// Maximum vertex connection distance of VirtualMesh when constructing selection data.
/// </summary>
public float maxConnectionDistance;
/// <summary>
/// ユーザーが編集したデータかどうか
/// Is the data edited by the user?
/// </summary>
public bool userEdit = false;
boneAttributeDict
/// <summary>
/// Transformと頂点属性辞書データ
/// 実行時でのBoneCloth/BoneSpring作成時にはこの辞書にTransformと頂点属性のペアを格納することで頂点ペイントデータの代わりにすることができます。
/// Transform and vertex attribute dictionary data.
/// When creating BoneCloth/BoneSpring at runtime, you can store Transform and vertex attribute pairs in this dictionary and use it instead of vertex paint data.
/// </summary>
public Dictionary<Transform, VertexAttribute> boneAttributeDict = new Dictionary<Transform, VertexAttribute>();
vertexAttributeList
/// <summary>
/// Rendererに対応する頂点属性データ
/// 実行時にMeshClothを構築する場合に、このリストにレンダラーごとのメッシュ頂点数分の頂点属性を格納することでセレクションデータの代わりにすることができます
/// Vertex attribute data corresponding to the Renderer.
/// When constructing MeshCloth at runtime, you can substitute selection data by storing vertex attributes in this list for the number of mesh vertices per renderer.
/// </summary>
[System.NonSerialized]
public List<VertexAttribute[]> vertexAttributeList = new List<VertexAttribute[]>();