Show / Hide Table of Contents

Class Mesh

Represents a mesh EntityObject.

Inheritance
System.Object
DxfObject
EntityObject
Mesh
Implements
IHasXData
System.ICloneable
Inherited Members
EntityObject.LayerChanged
EntityObject.OnLayerChangedEvent(Layer, Layer)
EntityObject.LinetypeChanged
EntityObject.OnLinetypeChangedEvent(Linetype, Linetype)
EntityObject.XDataAddAppReg
EntityObject.OnXDataAddAppRegEvent(ApplicationRegistry)
EntityObject.XDataRemoveAppReg
EntityObject.OnXDataRemoveAppRegEvent(ApplicationRegistry)
EntityObject.Reactors
EntityObject.Type
EntityObject.Color
EntityObject.Layer
EntityObject.Linetype
EntityObject.Lineweight
EntityObject.Transparency
EntityObject.LinetypeScale
EntityObject.IsVisible
EntityObject.Normal
EntityObject.Owner
EntityObject.XData
EntityObject.TransformBy(Matrix4)
EntityObject.ToString()
DxfObject.CodeName
DxfObject.Handle
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
Namespace: netDxf.Entities
Assembly: CADability.dll
Syntax
public class Mesh : EntityObject, IHasXData, ICloneable
Remarks

Use this entity to overcome the limitations of the PolyfaceMesh, but, keep in mind that this entity was first introduced in AutoCad 2010.
The maximum number of faces a mesh can have is 16000000 (16 millions).

Constructors

| Improve this Doc View Source

Mesh(IEnumerable<Vector3>, IEnumerable<Int32[]>)

Initializes a new instance of the Mesh class.

Declaration
public Mesh(IEnumerable<Vector3> vertexes, IEnumerable<int[]> faces)
Parameters
Type Name Description
System.Collections.Generic.IEnumerable<Vector3> vertexes

Mesh vertex list.

System.Collections.Generic.IEnumerable<System.Int32[]> faces

Mesh faces list.

| Improve this Doc View Source

Mesh(IEnumerable<Vector3>, IEnumerable<Int32[]>, IEnumerable<MeshEdge>)

Initializes a new instance of the Mesh class.

Declaration
public Mesh(IEnumerable<Vector3> vertexes, IEnumerable<int[]> faces, IEnumerable<MeshEdge> edges)
Parameters
Type Name Description
System.Collections.Generic.IEnumerable<Vector3> vertexes

Mesh vertex list.

System.Collections.Generic.IEnumerable<System.Int32[]> faces

Mesh faces list.

System.Collections.Generic.IEnumerable<MeshEdge> edges

Mesh edges list, this parameter is only really useful when it is required to assign creases values to edges.

Properties

| Improve this Doc View Source

Edges

Gets the mesh edges list.

Declaration
public List<MeshEdge> Edges { get; }
Property Value
Type Description
System.Collections.Generic.List<MeshEdge>
| Improve this Doc View Source

Faces

Gets the mesh faces list.

Declaration
public List<int[]> Faces { get; }
Property Value
Type Description
System.Collections.Generic.List<System.Int32[]>
| Improve this Doc View Source

SubdivisionLevel

Gets or sets the mesh subdivision level.

Declaration
public byte SubdivisionLevel { get; set; }
Property Value
Type Description
System.Byte
Remarks

The valid range is from 0 to 255. The recommended range is 0-5 to prevent creating extremely dense meshes.

| Improve this Doc View Source

Vertexes

Gets the mesh vertexes list.

Declaration
public List<Vector3> Vertexes { get; }
Property Value
Type Description
System.Collections.Generic.List<Vector3>

Methods

| Improve this Doc View Source

Clone()

Creates a new Mesh that is a copy of the current instance.

Declaration
public override object Clone()
Returns
Type Description
System.Object

A new Mesh that is a copy of this instance.

Overrides
EntityObject.Clone()
| Improve this Doc View Source

TransformBy(Matrix3, Vector3)

Moves, scales, and/or rotates the current entity given a 3x3 transformation matrix and a translation vector.

Declaration
public override void TransformBy(Matrix3 transformation, Vector3 translation)
Parameters
Type Name Description
Matrix3 transformation

Transformation matrix.

Vector3 translation

Translation vector.

Overrides
EntityObject.TransformBy(Matrix3, Vector3)
Remarks

Matrix3 adopts the convention of using column vectors to represent a transformation matrix.

Implements

IHasXData
System.ICloneable
  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX