docs.unity3d.com
    Show / Hide Table of Contents

    Class SanitizedMeshSample

    A sanitizable version of a MeshSample. Enable automatic triangulation/handedness change/attribute interpolation conversion. IRestorable allows static data to be stored once for multiple samples in the case of animated meshes.

    Inheritance
    Object
    SampleBase
    ImageableSample
    XformableSample
    BoundableSample
    GprimSample
    PointBasedSample
    MeshSampleBase
    MeshSample
    SanitizedMeshSample
    Inherited Members
    MeshSample.visibility
    MeshSample.purpose
    MeshSample.doubleSided
    MeshSample.orientation
    MeshSample.faceVertexCounts
    MeshSample.SetTriangles(Int32[])
    MeshSampleBase.faceVertexIndices
    MeshSampleBase.points
    MeshSampleBase.normals
    MeshSampleBase.tangents
    MeshSampleBase.ArbitraryPrimvars
    MeshSampleBase.GetArbitraryPrimvars()
    MeshSampleBase.AddPrimvars(List<String>)
    GprimSample.colors
    BoundableSample.extent
    XformableSample.FromTransform(Transform)
    XformableSample.transform
    XformableSample.xformOpOrder
    XformableSample.ConvertTransform()
    SampleBase.Free()
    Object.ToString()
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: Unity.Formats.USD
    Syntax
    public class SanitizedMeshSample : MeshSample, IArbitraryPrimvars, ISanitizable, IRestorable

    Methods

    BackupTopology()

    Declaration
    public void BackupTopology()

    FromCachedData(IRestorableData)

    Restore internal data from a copy of the data held in Deserialization Context for animated meshes.

    Declaration
    public void FromCachedData(IRestorableData restorableData)
    Parameters
    Type Name Description
    IRestorableData restorableData
    Implements
    IRestorable.FromCachedData(IRestorableData)

    IsRestoredFromCachedData()

    Declaration
    public bool IsRestoredFromCachedData()
    Returns
    Type Description
    Boolean
    Implements
    IRestorable.IsRestoredFromCachedData()

    IsTopologyBackedUp()

    Declaration
    public bool IsTopologyBackedUp()
    Returns
    Type Description
    Boolean

    Sanitize(Scene, SceneImportOptions)

    Sanitize Mesh data for Unity:

    • change basis
    • triangulate
    • convert vertices and attributes/primvar to facevarying if necessary
    Declaration
    public void Sanitize(Scene scene, SceneImportOptions importOptions)
    Parameters
    Type Name Description
    Scene scene
    SceneImportOptions importOptions
    Implements
    ISanitizable.Sanitize(Scene, SceneImportOptions)

    ToCachedData()

    Create a copy of static data in a format that can be stored in a DeserializationContext.

    Declaration
    public IRestorableData ToCachedData()
    Returns
    Type Description
    IRestorableData
    Implements
    IRestorable.ToCachedData()
    Back to top
    Copyright © 2023 Unity Technologies
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on Thursday, October 19, 2023