Skip to content

extract_alembic

Export alembic file.

Note

Parameters on AlembicExport (AlembicExport.Parameter):

ParticleAsMesh (bool): Sets whether particle shapes are exported as meshes. AnimTimeRange (enum): How animation is saved: #CurrentFrame: saves current frame #TimeSlider: saves the active time segments on time slider (default) #StartEnd: saves a range specified by the Step StartFrame (int) EnFrame (int) ShapeSuffix (bool): When set to true, appends the string "Shape" to the name of each exported mesh. This property is set to false by default. SamplesPerFrame (int): Sets the number of animation samples per frame. Hidden (bool): When true, export hidden geometry. UVs (bool): When true, export the mesh UV map channel. Normals (bool): When true, export the mesh normals. VertexColors (bool): When true, export the mesh vertex color map 0 and the current vertex color display data when it differs ExtraChannels (bool): When true, export the mesh extra map channels (map channels greater than channel 1) Velocity (bool): When true, export the meh vertex and particle velocity data. MaterialIDs (bool): When true, export the mesh material ID as Alembic face sets. Visibility (bool): When true, export the node visibility data. LayerName (bool): When true, export the node layer name as an Alembic object property. MaterialName (bool): When true, export the geometry node material name as an Alembic object property ObjectID (bool): When true, export the geometry node g-buffer object ID as an Alembic object property. CustomAttributes (bool): When true, export the node and its modifiers custom attributes into an Alembic object compound property.

ExtractCameraAlembic

Bases: ExtractAlembic

Extract Camera with AlembicExport.

Source code in client/ayon_max/plugins/publish/extract_alembic.py
115
116
117
118
119
class ExtractCameraAlembic(ExtractAlembic):
    """Extract Camera with AlembicExport."""
    label = "Extract Alembic Camera"
    families = ["camera"]
    optional = True

ExtractModelAlembic

Bases: ExtractAlembic

Extract Geometry in Alembic Format

Source code in client/ayon_max/plugins/publish/extract_alembic.py
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
class ExtractModelAlembic(ExtractAlembic):
    """Extract Geometry in Alembic Format"""
    label = "Extract Geometry (Alembic)"
    families = ["model"]
    optional = True

    def _set_abc_attributes(self, instance):
        attr_values = self.get_attr_values_from_data(instance.data)
        custom_attrs = attr_values.get("custom_attrs", False)
        if not custom_attrs:
            self.log.debug(
                "No Custom Attributes included in this abc export...")
        rt.AlembicExport.ArchiveType = rt.name("ogawa")
        rt.AlembicExport.CoordinateSystem = rt.name("maya")
        rt.AlembicExport.CustomAttributes = custom_attrs
        rt.AlembicExport.UVs = True
        rt.AlembicExport.VertexColors = True
        rt.AlembicExport.PreserveInstances = True