예제 #1
1
 /// <summary>
 /// Initializes a new instance of the <c>PolylineVertex</c> class.
 /// </summary>
 /// <param name="location">Polyface mesh vertex <see cref="Vector3d">location</see>.</param>
 public PolyfaceMeshVertex(Vector3d location)
     : base(DxfObjectCode.Vertex)
 {
     this.flags = VertexTypeFlags.PolyfaceMeshVertex | VertexTypeFlags.Polygon3dMesh;
     this.location = location;
     this.layer = Layer.Default;
     this.color = AciColor.ByLayer;
     this.lineType = LineType.ByLayer;
 }
예제 #2
0
 /// <summary>
 /// Initializes a new instance of the <c>PolylineVertex</c> class.
 /// </summary>
 public PolyfaceMeshVertex()
     : base(DxfObjectCode.Vertex)
 {
     this.flags    = VertexTypeFlags.PolyfaceMeshVertex | VertexTypeFlags.Polygon3dMesh;
     this.location = Vector3d.Zero;
     this.layer    = Layer.Default;
     this.color    = AciColor.ByLayer;
     this.lineType = LineType.ByLayer;
 }
예제 #3
0
 /// <summary>
 /// Initializes a new instance of the <c>PolylineVertex</c> class.
 /// </summary>
 /// <param name="x">X coordinate.</param>
 /// <param name="y">Y coordinate.</param>
 /// <param name="z">Z coordinate.</param>
 public Polyline3dVertex(float x, float y, float z)
     : base(DxfObjectCode.Vertex)
 {
     this.flags    = VertexTypeFlags.Polyline3dVertex;
     this.location = new Vector3d(x, y, z);
     this.layer    = Layer.Default;
     this.color    = AciColor.ByLayer;
     this.lineType = LineType.ByLayer;
 }
예제 #4
0
 /// <summary>
 /// Initializes a new instance of the PolylineVertex class.
 /// </summary>
 /// <param name="x">X coordinate.</param>
 /// <param name="y">Y coordinate.</param>
 /// <param name="z">Z coordinate.</param>
 public PolyfaceMeshVertex(float x, float y, float z)
     : base(DxfObjectCode.Vertex)
 {
     this.flags = VertexTypeFlags.PolyfaceMeshVertex | VertexTypeFlags.Polygon3dMesh;
     this.location = new Vector3d(x, y, z);
     this.layer = Layer.Default;
     this.color = AciColor.ByLayer;
     this.lineType = LineType.ByLayer;
 }
 /// <summary>
 /// Initializes a new instance of the <c>PolyfaceMeshFace</c> class.
 /// </summary>
 /// <remarks>
 /// By default the face is made up of three vertexes.
 /// </remarks>
 public PolyfaceMeshFace()
     : base(DxfObjectCode.Vertex)
 {
     this.flags         = VertexTypeFlags.PolyfaceMeshVertex;
     this.vertexIndexes = new int[3];
     this.layer         = Layer.Default;
     this.color         = AciColor.ByLayer;
     this.lineType      = LineType.ByLayer;
 }
 /// <summary>
 /// Initializes a new instance of the PolylineVertex class.
 /// </summary>
 /// <param name="x">X coordinate.</param>
 /// <param name="y">Y coordinate.</param>
 /// <param name="z">Z coordinate.</param>
 public PolyfaceMeshVertex(double x, double y, double z)
     : base(DxfObjectCode.Vertex)
 {
     this.flags    = VertexTypeFlags.PolyfaceMeshVertex | VertexTypeFlags.Polygon3dMesh;
     this.location = new Vector3(x, y, z);
     this.layer    = Layer.Default;
     this.color    = AciColor.ByLayer;
     this.lineType = LineType.ByLayer;
 }
예제 #7
0
 /// <summary>
 /// Initializes a new instance of the <c>Polyline3dVertex</c> class.
 /// </summary>
 /// <param name="location">Polyline <see cref="Vector3d">vertex</see> coordinates.</param>
 public Polyline3dVertex(Vector3d location)
     : base(DxfObjectCode.Vertex)
 {
     this.flags    = VertexTypeFlags.Polyline3dVertex;
     this.location = location;
     this.layer    = Layer.Default;
     this.color    = AciColor.ByLayer;
     this.lineType = LineType.ByLayer;
 }
예제 #8
0
 /// <summary>
 /// Initializes a new instance of the <c>PolyfaceMeshFace</c> class.
 /// </summary>
 /// <remarks>
 /// By default the face is made up of three vertexes.
 /// </remarks>
 public PolyfaceMeshFace()
     : base(DxfObjectCode.Vertex)
 {
     this.flags = VertexTypeFlags.PolyfaceMeshVertex;
     this.vertexIndexes = new int[3];
     this.layer = Layer.Default;
     this.color = AciColor.ByLayer;
     this.lineType = LineType.ByLayer;
 }
예제 #9
0
 /// <summary>
 /// Initializes a new instance of the <c>Polyline3dVertex</c> class.
 /// </summary>
 /// <param name="location">Polyline <see cref="Vector3f">vertex</see> coordinates.</param>
 public Polyline3dVertex(Vector3f location)
     : base(DxfObjectCode.Vertex)
 {
     this.flags = VertexTypeFlags.Polyline3dVertex;
     this.location = location;
     this.layer = Layer.Default;
     this.color = AciColor.ByLayer;
     this.lineType = LineType.ByLayer;
 }
예제 #10
0
 /// <summary>
 /// Initializes a new instance of the <c>PolylineVertex</c> class.
 /// </summary>
 /// <param name="x">X coordinate.</param>
 /// <param name="y">Y coordinate.</param>
 /// <param name="z">Z coordinate.</param>
 public Polyline3dVertex(double x, double y, double z)
     : base(DxfObjectCode.Vertex)
 {
     this.flags = VertexTypeFlags.Polyline3dVertex;
     this.location = new Vector3d(x, y, z);
     this.layer = Layer.Default;
     this.color = AciColor.ByLayer;
     this.lineType = LineType.ByLayer;
 }
예제 #11
0
 /// <summary>
 /// Initializes a new instance of the <c>PolyfaceMeshFace</c> class.
 /// </summary>
 /// <param name="vertexIndexes">Array of indexes to the vertex list of a polyface mesh that makes up the face.</param>
 public PolyfaceMeshFace(IEnumerable<short> vertexIndexes)
     : base(DxfObjectCode.Vertex)
 {
     if (vertexIndexes == null)
         throw new ArgumentNullException(nameof(vertexIndexes));
     this.flags = VertexTypeFlags.PolyfaceMeshVertex;
     this.vertexIndexes = new List<short>(vertexIndexes);
     if (this.vertexIndexes.Count > 4)
         throw new ArgumentOutOfRangeException(nameof(vertexIndexes), this.vertexIndexes.Count, "The maximum number of vertexes per face is 4");
 }
 /// <summary>
 /// Initializes a new instance of the <c>PolyfaceMeshFace</c> class.
 /// </summary>
 /// <param name="vertexIndexes">Array of indexes to the vertex list of a polyface mesh that makes up the face.</param>
 public PolyfaceMeshFace(short[] vertexIndexes)
     : base(DxfObjectCode.Vertex)
 {
     if (vertexIndexes == null)
         throw new ArgumentNullException(nameof(vertexIndexes));
     if (vertexIndexes.Length>4)
         throw new ArgumentOutOfRangeException(nameof(vertexIndexes), vertexIndexes.Length, "The maximum number of vertexes per face is 4");
     
     this.flags = VertexTypeFlags.PolyfaceMeshVertex;
     this.vertexIndexes = vertexIndexes;
 }
예제 #13
0
파일: Vertex.cs 프로젝트: tbscer/SharpDxf
 /// <summary>
 /// Initializes a new instance of the <c>Vertex</c> class.
 /// </summary>
 public Vertex()
     : base(DxfObjectCode.Vertex)
 {
     this.flags          = VertexTypeFlags.PolylineVertex;
     this.location       = Vector3f.Zero;
     this.layer          = Layer.Default;
     this.color          = AciColor.ByLayer;
     this.lineType       = LineType.ByLayer;
     this.bulge          = 0.0f;
     this.beginThickness = 0.0f;
     this.endThickness   = 0.0f;
 }
예제 #14
0
 /// <summary>
 /// Initializes a new instance of the <c>Vertex</c> class.
 /// </summary>
 /// <param name="location">Vertex <see cref="netDxf.Vector2d">location</see>.</param>
 public Vertex(Vector2d location)
     : base(DxfObjectCode.Vertex)
 {
     this.flags          = VertexTypeFlags.PolylineVertex;
     this.location       = new Vector3d(location.X, location.Y, 0.0);
     this.layer          = Layer.Default;
     this.color          = AciColor.ByLayer;
     this.lineType       = LineType.ByLayer;
     this.bulge          = 0.0;
     this.beginThickness = 0.0f;
     this.endThickness   = 0.0f;
 }
예제 #15
0
 /// <summary>
 /// Initializes a new instance of the <c>Vertex</c> class.
 /// </summary>
 /// <param name="location">Vertex <see cref="netDxf.Vector3">location</see>.</param>
 public Vertex(Vector3 location)
     : base(DxfObjectCode.Vertex)
 {
     this.flags      = VertexTypeFlags.PolylineVertex;
     this.location   = location;
     this.layer      = Layer.Default;
     this.color      = AciColor.ByLayer;
     this.lineType   = LineType.ByLayer;
     this.bulge      = 0.0;
     this.startWidth = 0.0;
     this.endWidth   = 0.0;
 }
 /// <summary>
 /// Initializes a new instance of the <c>PolylineVertex</c> class.
 /// </summary>
 /// <param name="x">X coordinate.</param>
 /// <param name="y">Y coordinate.</param>
 /// <param name="bulge">Vertex bulge.</param>
 public PolylineVertex(double x, double y, double bulge = 0.0)
     : base(DxfObjectCode.Vertex)
 {
     this.flags      = VertexTypeFlags.PolylineVertex;
     this.location   = new Vector2(x, y);
     this.layer      = Layer.Default;
     this.color      = AciColor.ByLayer;
     this.lineType   = LineType.ByLayer;
     this.bulge      = bulge;
     this.beginWidth = 0.0;
     this.endWidth   = 0.0;
 }
예제 #17
0
 /// <summary>
 /// Initializes a new instance of the <c>Vertex</c> class.
 /// </summary>
 /// <param name="location">Vertex <see cref="netDxf.Vector2f">location</see>.</param>
 public Vertex(Vector2f location)
     : base(DxfCodigoObjeto.Vertex)
 {
     this.flags = VertexTypeFlags.PolylineVertex;
     this.location = new Vector3f(location.X, location.Y, 0.0f);
     //this.layer = Layer.Default;
     //this.color = AciColor.ByLayer;
     //this.lineType = LineType.ByLayer;
     this.bulge = 0.0f;
     this.beginThickness = 0.0f;
     this.endThickness = 0.0f;
 }
예제 #18
0
 /// <summary>
 /// Initializes a new instance of the <c>PolylineVertex</c> class.
 /// </summary>
 /// <param name="x">X coordinate.</param>
 /// <param name="y">Y coordinate.</param>
 public PolylineVertex(float x, float y)
     : base(DxfObjectCode.Vertex)
 {
     this.flags          = VertexTypeFlags.PolylineVertex;
     this.location       = new Vector2f(x, y);
     this.layer          = Layer.Default;
     this.color          = AciColor.ByLayer;
     this.lineType       = LineType.ByLayer;
     this.bulge          = 0.0f;
     this.beginThickness = 0.0f;
     this.endThickness   = 0.0f;
 }
예제 #19
0
 /// <summary>
 /// Initializes a new instance of the <c>PolylineVertex</c> class.
 /// </summary>
 /// <param name="location">Polyline <see cref="Vector2f">vertex</see> coordinates.</param>
 public PolylineVertex(Vector2f location)
     : base(DxfObjectCode.Vertex)
 {
     this.flags = VertexTypeFlags.PolylineVertex;
     this.location = location;
     this.layer = Layer.Default;
     this.color = AciColor.ByLayer;
     this.lineType = LineType.ByLayer;
     this.bulge = 0.0f;
     this.beginThickness = 0.0f;
     this.endThickness = 0.0f;
 }
예제 #20
0
 /// <summary>
 /// Initializes a new instance of the <c>Vertex</c> class.
 /// </summary>
 /// <param name="x">X coordinate.</param>
 /// <param name="y">Y coordinate.</param>
 /// <param name="z">Z coordinate.</param>
 public Vertex(double x, double y, double z)
     : base(DxfObjectCode.Vertex)
 {
     this.flags          = VertexTypeFlags.PolylineVertex;
     this.location       = new Vector3d(x, y, z);
     this.layer          = Layer.Default;
     this.color          = AciColor.ByLayer;
     this.lineType       = LineType.ByLayer;
     this.bulge          = 0.0;
     this.beginThickness = 0.0f;
     this.endThickness   = 0.0f;
 }
예제 #21
0
 /// <summary>
 /// Initializes a new instance of the <c>Vertex</c> class.
 /// </summary>
 /// <param name="position">Vertex <see cref="Vector3">location</see>.</param>
 public Vertex(Vector3 position)
     : base(DxfObjectCode.Vertex)
 {
     flags         = VertexTypeFlags.PolylineVertex;
     this.position = position;
     layer         = Layer.Default;
     color         = AciColor.ByLayer;
     linetype      = Linetype.ByLayer;
     bulge         = 0.0;
     startWidth    = 0.0;
     endWidth      = 0.0;
 }
 /// <summary>
 /// Initializes a new instance of the <c>PolylineVertex</c> class.
 /// </summary>
 public PolylineVertex()
     : base(DxfObjectCode.Vertex)
 {
     this.flags      = VertexTypeFlags.PolylineVertex;
     this.location   = Vector2.Zero;
     this.layer      = Layer.Default;
     this.color      = AciColor.ByLayer;
     this.lineType   = LineType.ByLayer;
     this.bulge      = 0.0;
     this.beginWidth = 0.0;
     this.endWidth   = 0.0;
 }
예제 #23
0
        /// <summary>
        /// Initializes a new instance of the <c>PolyfaceMeshFace</c> class.
        /// </summary>
        /// <param name="vertexIndexes">Array of indexes to the vertex list of a polyface mesh that makes up the face.</param>
        public PolyfaceMeshFace(int[] vertexIndexes)
            : base(DxfObjectCode.Vertex)
        {
            if (vertexIndexes == null)
                throw new ArgumentNullException("vertexIndexes");
            if (vertexIndexes.Length>4)
                throw new ArgumentOutOfRangeException("vertexIndexes", vertexIndexes.Length, "The maximun number of index vertexes in a face is 4");

            this.flags = VertexTypeFlags.PolyfaceMeshVertex;
            this.vertexIndexes = vertexIndexes;
            this.layer = Layer.Default;
            this.color = AciColor.ByLayer;
            this.lineType = LineType.ByLayer;
        }
예제 #24
0
 public PolyfaceMeshFace(IEnumerable <short> vertexIndexes)
     : base(DxfObjectCode.Vertex)
 {
     if (vertexIndexes == null)
     {
         throw new ArgumentNullException(nameof(vertexIndexes));
     }
     this.flags         = VertexTypeFlags.PolyfaceMeshVertex;
     this.vertexIndexes = new List <short>(vertexIndexes);
     if (this.vertexIndexes.Count > 4)
     {
         throw new ArgumentOutOfRangeException(nameof(vertexIndexes), this.vertexIndexes.Count, "The maximum number of vertexes per face is 4");
     }
 }
예제 #25
0
 /// <summary>
 /// Initializes a new instance of the <c>Vertex</c> class.
 /// </summary>
 public Vertex()
     : base(DxfObjectCode.Vertex)
 {
     this.flags          = VertexTypeFlags.Polyline2DVertex;
     this.position       = Vector3.Zero;
     this.layer          = null;
     this.color          = null;
     this.linetype       = null;
     this.bulge          = 0.0;
     this.startWidth     = 0.0;
     this.endWidth       = 0.0;
     this.vertexIndexes  = null;
     this.subclassMarker = netDxf.SubclassMarker.Polyline2DVertex;
 }
예제 #26
0
        /// <summary>
        /// Initializes a new instance of the <c>PolyfaceMeshFace</c> class.
        /// </summary>
        /// <param name="vertexIndexes">Array of indexes to the vertex list of a polyface mesh that makes up the face.</param>
        public PolyfaceMeshFace(short[] vertexIndexes)
            : base(DxfObjectCode.Vertex)
        {
            if (vertexIndexes == null)
            {
                throw new ArgumentNullException("vertexIndexes");
            }
            if (vertexIndexes.Length > 4)
            {
                throw new ArgumentOutOfRangeException("vertexIndexes", vertexIndexes.Length, "The maximum number of vertexes per face is 4");
            }

            this.flags         = VertexTypeFlags.PolyfaceMeshVertex;
            this.vertexIndexes = vertexIndexes;
        }
        /// <summary>
        /// Initializes a new instance of the <c>PolyfaceMeshFace</c> class.
        /// </summary>
        /// <param name="vertexIndexes">Array of indexes to the vertex list of a polyface mesh that makes up the face.</param>
        public PolyfaceMeshFace(int[] vertexIndexes)
            : base(DxfObjectCode.Vertex)
        {
            if (vertexIndexes == null)
            {
                throw new ArgumentNullException("vertexIndexes");
            }
            if (vertexIndexes.Length > 4)
            {
                throw new ArgumentOutOfRangeException("vertexIndexes", vertexIndexes.Length, "The maximun number of index vertexes in a face is 4");
            }

            this.flags         = VertexTypeFlags.PolyfaceMeshVertex;
            this.vertexIndexes = vertexIndexes;
            this.layer         = Layer.Default;
            this.color         = AciColor.ByLayer;
            this.lineType      = LineType.ByLayer;
        }
예제 #28
0
 static public bool HasFlag(this VertexTypeFlags flags, VertexTypeFlags flag)
 {
     return((flags & flag) != 0);
 }
예제 #29
0
 /// <summary>
 /// Initializes a new instance of the <c>PolylineVertex</c> class.
 /// </summary>
 /// <param name="location">Polyline <see cref="Vector3">vertex</see> coordinates.</param>
 public PolylineVertex(Vector3 location)
     : base(DxfObjectCode.Vertex)
 {
     this.flags    = VertexTypeFlags.Polyline3dVertex;
     this.location = location;
 }
예제 #30
0
 /// <summary>
 /// Initializes a new instance of the <c>PolylineVertex</c> class.
 /// </summary>
 /// <param name="x">X coordinate.</param>
 /// <param name="y">Y coordinate.</param>
 /// <param name="z">Z coordinate.</param>
 public Polyline3dVertex(float x, float y, float z)
     : base(DxfCodigoObjeto.Vertex)
 {
     this.flags = VertexTypeFlags.Polyline3dVertex;
     this.location = new Vector3f(x, y, z);
     //this.layer = Layer.Default;
     //this.color = AciColor.ByLayer;
     //this.lineType = LineType.ByLayer;
 }
예제 #31
0
파일: Vertex.cs 프로젝트: Core2D/netdxf
 /// <summary>
 /// Initializes a new instance of the <c>Vertex</c> class.
 /// </summary>
 /// <param name="position">Vertex <see cref="Vector3">location</see>.</param>
 public Vertex(Vector3 position)
     : base(DxfObjectCode.Vertex)
 {
     this.flags = VertexTypeFlags.PolylineVertex;
     this.position = position;
     this.layer = Layer.Default;
     this.color = AciColor.ByLayer;
     this.linetype = Linetype.ByLayer;
     this.bulge = 0.0;
     this.startWidth = 0.0;
     this.endWidth = 0.0;
 }
예제 #32
0
 /// <summary>
 /// Initializes a new instance of the <c>PolylineVertex</c> class.
 /// </summary>
 /// <param name="location">Polyface mesh vertex <see cref="Vector3">location</see>.</param>
 public PolyfaceMeshVertex(Vector3 location)
     : base(DxfObjectCode.Vertex)
 {
     this.flags    = VertexTypeFlags.PolyfaceMeshVertex | VertexTypeFlags.Polygon3dMesh;
     this.location = location;
 }
예제 #33
0
 /// <summary>
 /// Initializes a new instance of the <c>PolylineVertex</c> class.
 /// </summary>
 /// <param name="position">Polyline <see cref="Vector3">vertex</see> coordinates.</param>
 public PolylineVertex(Vector3 position)
     : base(DxfObjectCode.Vertex)
 {
     flags         = VertexTypeFlags.Polyline3dVertex;
     this.position = position;
 }
예제 #34
0
 /// <summary>
 /// Initializes a new instance of the <c>PolylineVertex</c> class.
 /// </summary>
 public PolylineVertex()
     : base(DxfCodigoObjeto.Vertex)
 {
     this.flags = VertexTypeFlags.PolylineVertex;
     this.location = Vector2f.Zero;
     //this.layer = Layer.Default;
     //this.color = AciColor.ByLayer;
     //this.lineType = LineType.ByLayer;
     this.bulge = 0.0f;
     this.beginThickness = 0.0f;
     this.endThickness = 0.0f;
 }
예제 #35
0
파일: Vertex.cs 프로젝트: fearog/axecalc
 /// <summary>
 /// Initializes a new instance of the <c>Vertex</c> class.
 /// </summary>
 /// <param name="x">X coordinate.</param>
 /// <param name="y">Y coordinate.</param>
 public Vertex(double x, double y)
     : base(DxfObjectCode.Vertex)
 {
     this.flags = VertexTypeFlags.PolylineVertex;
     this.location = new Vector3d(x, y, 0.0f);
     this.layer = Layer.Default;
     this.color = AciColor.ByLayer;
     this.lineType = LineType.ByLayer;
     this.bulge = 0.0f;
     this.beginThickness = 0.0f;
     this.endThickness = 0.0f;
 }
예제 #36
0
 /// <summary>
 /// Initializes a new instance of the <c>PolylineVertex</c> class.
 /// </summary>
 /// <param name="location">Polyface mesh vertex <see cref="Vector3">location</see>.</param>
 public PolyfaceMeshVertex(Vector3 location)
     : base(DxfObjectCode.Vertex)
 {
     this.flags = VertexTypeFlags.PolyfaceMeshVertex | VertexTypeFlags.Polygon3dMesh;
     this.location = location;
 }
예제 #37
0
 /// <summary>
 /// Initializes a new instance of the <c>PolylineVertex</c> class.
 /// </summary>
 public PolyfaceMeshVertex()
     : base(DxfCodigoObjeto.Vertex)
 {
     this.flags = VertexTypeFlags.PolyfaceMeshVertex | VertexTypeFlags.Polygon3dMesh;
     this.location = Vector3f.Nulo;
     //this.layer = Layer.Default;
     //this.color = AciColor.ByLayer;
     //this.lineType = LineType.ByLayer;
 }
예제 #38
0
 /// <summary>
 /// Initializes a new instance of the <c>PolylineVertex</c> class.
 /// </summary>
 /// <param name="location">Polyline <see cref="Vector3">vertex</see> coordinates.</param>
 public PolylineVertex(Vector3 location)
     : base(DxfObjectCode.Vertex)
 {
     this.flags = VertexTypeFlags.Polyline3dVertex;
     this.location = location;
 }