(One intermediate revision by the same user not shown)
Line 10:
Line 10:
== Usage == <!--T:2-->
== Fields == <!--T:2-->
{{Table ComponentFields
{{Table ComponentFields
|Mesh|{{RootFieldType|AssetRef`1|[[Type:Mesh|Mesh]]}}|TypeAdv0=true| The mesh to be rendered. Can be a [[StaticMesh (Component)|StaticMesh]] or a [[:Category:Components:Assets:Procedural Meshes|Procedural Mesh]]
|Mesh|{{RootFieldType|AssetRef`1|[[Type:Mesh|Mesh]]}}|TypeAdv0=true| The mesh to be rendered. Can be a [[StaticMesh (Component)|StaticMesh]] or a [[:Category:Components:Assets:Procedural Meshes|Procedural Mesh]]
|Materials|{{RootFieldType|SyncAssetList`1|[[Type:Material|Material]]}}|TypeAdv1=true| A list of materials to be applied to the mesh
|Materials|{{RootFieldType|SyncAssetList`1|[[Type:Material|Material]]}}|TypeAdv1=true| A list of materials to be applied to the mesh
|MaterialPropertyBlocks|{{RootFieldType|SyncAssetList`1|[[Type:MaterialPropertyBlock|MaterialPropertyBlock]]}}|TypeAdv2=true| A list of material property blocks to apply to the materials on this mesh. Usually used for performance reasons where using multiple similar materials would take more resources.
|ShadowCastMode|ShadowCastMode| How this object will cast shadows onto the world, or if it <i>only</i> draws a shadow.
|ShadowCastMode|ShadowCastMode| How this object will cast shadows onto the world, or if it <i>only</i> draws a shadow.
|MotionVectorMode|MotionVectorMode|
|MotionVectorMode|MotionVectorMode| See Motion vector mode.
|SortingOrder|Int|
|SortingOrder|Int| Whether to render this before or after other renderers with geometry in the same location.
|BoundsComputeMethod|SkinnedBounds| How the bounds of this mesh will be calculated. Should be left as ''Static'' if possible, for performance reasons.
|BoundsComputeMethod|SkinnedBounds| How the bounds of this mesh will be calculated. Should be left as ''Static'' if possible, for performance reasons.
|ProxyBoundsSource|'''[[Component:SkinnedMeshRenderer|SkinnedMeshRenderer]]'''|TypeAdv7=true| A [[Component:SkinnedMeshRenderer|SkinnedMeshRenderer]] to use the <code>ExplicitLocalBounds</code> of rather than the <code>ExplicitLocalBounds</code> on this component.
|ExplicitLocalBounds|BoundingBox|
|ExplicitLocalBounds|BoundingBox| A box that within view will render the mesh, and when out of view will cull the mesh and stop rendering it. Is used when <code>ProxyBoundsSource</code> is null.
|Bones|{{RootFieldType|SyncRefList`1|[[Type:Slot|Slot]]}}|TypeAdv9=true| ''Automatically Assigned'' — List of bones present in this mesh
|Bones|{{RootFieldType|SyncRefList`1|[[Type:Slot|Slot]]}}|TypeAdv9=true| ''Automatically Assigned'' — List of bones present in this mesh
|BlendShapeWeights|{{RootFieldType|SyncFieldList`1|[[Type:Float|Float]]}}|TypeAdv10=true| ''Automatically Assigned'' — List of blendshapes present in this mesh, and their respective weights.
|BlendShapeWeights|{{RootFieldType|SyncFieldList`1|[[Type:Float|Float]]}}|TypeAdv10=true| ''Automatically Assigned'' — List of blendshapes present in this mesh, and their respective weights.
Line 49:
Line 49:
}}
}}
== Behavior ==
== Usage ==
<!--T:3-->
<!--T:3-->
While it ''can'' be used for rendering static meshes, it is '''not recommended''' as there is a slight performance penalty for using SkinnedMeshRenderer, even if the animation features aren't used — Please try to use [[MeshRenderer (Component)| MeshRenderer]] where possible.
While it ''can'' be used for rendering static meshes, it is '''not recommended''' as there is a slight performance penalty for using SkinnedMeshRenderer, even if the animation features aren't used — Please try to use [[MeshRenderer (Component)| MeshRenderer]] where possible.
Latest revision as of 15:56, 12 April 2025
This article or section is a Stub. You can help the Resonite Wiki by expanding it.
Component image
SkinnedMeshRenderer component as seen in the Scene Inspector
The SkinnedMeshRenderer component is used for rendering animated/dynamic 3D meshes in the world, and applying materials to that mesh.
A list of material property blocks to apply to the materials on this mesh. Usually used for performance reasons where using multiple similar materials would take more resources.
Will merge all submeshes that use the same material
Usage
While it can be used for rendering static meshes, it is not recommended as there is a slight performance penalty for using SkinnedMeshRenderer, even if the animation features aren't used — Please try to use MeshRenderer where possible.