Class MeshComponent
A 3D mesh. To render this mesh, use the MeshRenderer class.
Inheritance
MeshComponent
Implements
Inherited Members
Namespace: Evergine.Components.Graphics3D
Assembly: Evergine.Framework.dll
Syntax
public class MeshComponent : BaseModel, IDependencyObject
Constructors
MeshComponent()
Initializes a new instance of the MeshComponent class.
Declaration
public MeshComponent()
Fields
meshContainer
The content of the mesh.
Declaration
protected MeshContainer meshContainer
Field Value
Type | Description |
---|---|
MeshContainer |
modelLink
Dependency System Reference Model.
Declaration
protected LoadableDependencyLink<Model> modelLink
Field Value
Type | Description |
---|---|
LoadableDependencyLink<Model> |
modelMeshName
The name of the model mesh.
Declaration
protected string modelMeshName
Field Value
Type | Description |
---|---|
string |
Properties
BoundingBox
Gets the mesh's bounding box.
Declaration
public override BoundingBox? BoundingBox { get; }
Property Value
Type | Description |
---|---|
BoundingBox? | The bounding box. |
Overrides
MeshContainer
Gets the mesh content.
Declaration
public MeshContainer MeshContainer { get; }
Property Value
Type | Description |
---|---|
MeshContainer |
MeshCount
Gets the number of meshes in this model.
Declaration
public override int MeshCount { get; }
Property Value
Type | Description |
---|---|
int |
Overrides
MeshNames
Gets the mesh name list from the FBX file.
Declaration
public IEnumerable MeshNames { get; }
Property Value
Type | Description |
---|---|
IEnumerable |
Meshes
Gets the mesh group.
Declaration
public override List<Mesh> Meshes { get; }
Property Value
Type | Description |
---|---|
List<Mesh> |
Overrides
Model
Gets or sets the model data.
Declaration
public virtual Model Model { get; set; }
Property Value
Type | Description |
---|---|
Model |
ModelMeshName
Gets or sets the specified mesh name to render.
Declaration
public virtual string ModelMeshName { get; set; }
Property Value
Type | Description |
---|---|
string |
Methods
OnAttached()
Invoked when the object is attached to the system.
Declaration
protected override bool OnAttached()
Returns
Type | Description |
---|---|
bool | True if everything is OK. |
Overrides
OnDestroy()
Invoked when the object is about to be disposed.
Declaration
protected override void OnDestroy()
Overrides
RefreshMesh()
Refreshes the mesh content.
Declaration
protected virtual void RefreshMesh()
ThrowRefreshEvent()
Throws a refresh model.
Declaration
protected override void ThrowRefreshEvent()
Overrides
UnloadModel()
Unloads the internal model.
Declaration
protected void UnloadModel()
Events
ChangedMesh
Event raised when there is a new mesh.
Declaration
public event EventHandler<MeshContainer> ChangedMesh
Event Type
Type | Description |
---|---|
EventHandler<MeshContainer> |