示例#1
0
 /// <summary>
 /// Initializes a new instance of the <c>PolyfaceMesh</c> class.
 /// </summary>
 public PolyfaceMesh()
     : base(DxfObjectCode.Polyline)
 {
     this.flags       = PolylineTypeFlags.PolyfaceMesh;
     this.faces       = new List <PolyfaceMeshFace>();
     this.layer       = Layer.Default;
     this.color       = AciColor.ByLayer;
     this.lineType    = LineType.ByLayer;
     this.endSequence = new EndSequence();
 }
示例#2
0
 /// <summary>
 /// Initializes a new instance of the <c>Polyline3d</c> class.
 /// </summary>
 /// <param name="vertexes">3d polyline <see cref="Polyline3dVertex">vertex</see> list.</param>
 /// <param name="isClosed">Sets if the polyline is closed</param>
 public Polyline3d(List <Polyline3dVertex> vertexes, bool isClosed)
     : base(DxfObjectCode.Polyline)
 {
     this.flags       = isClosed ? PolylineTypeFlags.ClosedPolylineOrClosedPolygonMeshInM | PolylineTypeFlags.Polyline3D : PolylineTypeFlags.Polyline3D;
     this.vertexes    = vertexes;
     this.layer       = Layer.Default;
     this.color       = AciColor.ByLayer;
     this.lineType    = LineType.ByLayer;
     this.endSequence = new EndSequence();
 }
示例#3
0
 /// <summary>
 /// Initializes a new instance of the <c>Polyline3d</c> class.
 /// </summary>
 public Polyline3d()
     : base(DxfObjectCode.Polyline)
 {
     this.flags       = PolylineTypeFlags.Polyline3D;
     this.vertexes    = new List <Polyline3dVertex>();
     this.layer       = Layer.Default;
     this.color       = AciColor.ByLayer;
     this.lineType    = LineType.ByLayer;
     this.endSequence = new EndSequence();
 }
示例#4
0
 /// <summary>
 /// Initializes a new instance of the <c>Polyline3d</c> class.
 /// </summary>
 /// <param name="vertexes">3d polyline <see cref="Polyline3dVertex">vertex</see> list.</param>
 public Polyline3d(List<Polyline3dVertex> vertexes)
     : base(DxfObjectCode.Polyline)
 {
     this.flags = PolylineTypeFlags.Polyline3D;
     this.vertexes = vertexes;
     this.layer = Layer.Default;
     this.color = AciColor.ByLayer;
     this.lineType = LineType.ByLayer;
     this.endSequence = new EndSequence();
 }
示例#5
0
 /// <summary>
 /// Initializes a new instance of the <c>Polyline3d</c> class.
 /// </summary>
 /// <param name="vertexes">3d polyline <see cref="Polyline3dVertex">vertex</see> list.</param>
 /// <param name="isClosed">Sets if the polyline is closed</param>
 public Polyline3d(List<Polyline3dVertex> vertexes, bool isClosed)
     : base(DxfObjectCode.Polyline)
 {
     this.flags = isClosed ? PolylineTypeFlags.ClosedPolylineOrClosedPolygonMeshInM | PolylineTypeFlags.Polyline3D : PolylineTypeFlags.Polyline3D;
     this.vertexes = vertexes;
     this.layer = Layer.Default;
     this.color = AciColor.ByLayer;
     this.lineType = LineType.ByLayer;
     this.endSequence = new EndSequence();
 }
示例#6
0
 /// <summary>
 /// Initializes a new instance of the <c>PolyfaceMesh</c> class.
 /// </summary>
 public PolyfaceMesh()
     : base(DxfObjectCode.Polyline)
 {
     this.flags = PolylineTypeFlags.PolyfaceMesh;
     this.faces = new List<PolyfaceMeshFace>();
     this.layer = Layer.Default;
     this.color = AciColor.ByLayer;
     this.lineType = LineType.ByLayer;
     this.endSequence = new EndSequence();
 }
示例#7
0
 /// <summary>
 /// Initializes a new instance of the <c>Polyline</c> class.
 /// </summary>
 public Polyline()
     : base(DxfObjectCode.Polyline)
 {
     this.vertexes    = new List <PolylineVertex>();
     this.isClosed    = false;
     this.layer       = Layer.Default;
     this.color       = AciColor.ByLayer;
     this.lineType    = LineType.ByLayer;
     this.normal      = Vector3f.UnitZ;
     this.elevation   = 0.0f;
     this.flags       = PolylineTypeFlags.OpenPolyline;
     this.endSequence = new EndSequence();
 }
示例#8
0
 /// <summary>
 /// Initializes a new instance of the <c>Polyline</c> class.
 /// </summary>
 /// <param name="vertexes">Polyline vertex list in object coordinates.</param>
 /// <param name="isClosed">Sets if the polyline is closed</param>
 public Polyline(List<PolylineVertex> vertexes, bool isClosed)
     : base(DxfObjectCode.Polyline)
 {
     this.vertexes = vertexes;
     this.isClosed = isClosed;
     this.layer = Layer.Default;
     this.color = AciColor.ByLayer;
     this.lineType = LineType.ByLayer;
     this.normal = Vector3f.UnitZ;
     this.elevation = 0.0f;
     this.thickness = 0.0f;
     this.flags = isClosed ? PolylineTypeFlags.ClosedPolylineOrClosedPolygonMeshInM : PolylineTypeFlags.OpenPolyline;
     this.endSequence = new EndSequence();
 }
示例#9
0
 /// <summary>
 /// Initializes a new instance of the <c>Polyline</c> class.
 /// </summary>
 /// <param name="vertexes">Polyline vertex list in object coordinates.</param>
 /// <param name="isClosed">Sets if the polyline is closed</param>
 public Polyline(List <PolylineVertex> vertexes, bool isClosed)
     : base(DxfObjectCode.Polyline)
 {
     this.vertexes    = vertexes;
     this.isClosed    = isClosed;
     this.layer       = Layer.Default;
     this.color       = AciColor.ByLayer;
     this.lineType    = LineType.ByLayer;
     this.normal      = Vector3f.UnitZ;
     this.elevation   = 0.0f;
     this.thickness   = 0.0f;
     this.flags       = isClosed ? PolylineTypeFlags.ClosedPolylineOrClosedPolygonMeshInM : PolylineTypeFlags.OpenPolyline;
     this.endSequence = new EndSequence();
 }
示例#10
0
        /// <summary>
        /// Initializes a new instance of the <c>Insert</c> class.
        /// </summary>
        /// <param name="block">Insert block definition.</param>
        /// <param name="insertionPoint">Insert <see cref="Vector3f">point</see>.</param>
        public Insert(Block block, Vector3f insertionPoint)
            : base(DxfObjectCode.Insert)
        {
            if (block == null)
                throw new ArgumentNullException("block");

            this.block = block;
            this.insertionPoint = insertionPoint;
            this.scale = new Vector3f(1.0f, 1.0f, 1.0f);
            this.rotation = 0.0f;
            this.normal = Vector3f.UnitZ;
            this.layer = Layer.Default;
            this.color = AciColor.ByLayer;
            this.lineType = LineType.ByLayer;
            this.attributes = new List<Attribute>();
            foreach (AttributeDefinition attdef in block.Attributes.Values)
            {
                this.attributes.Add(new Attribute(attdef));
            }
            this.endSequence = new EndSequence();
        }
示例#11
0
        /// <summary>
        /// Initializes a new instance of the <c>Insert</c> class.
        /// </summary>
        /// <param name="block">Insert <see cref="Blocks.Block">block definition</see>.</param>
        public Insert(Block block)
            : base(DxfObjectCode.Insert)
        {
            if (block == null)
            {
                throw new ArgumentNullException("block");
            }

            this.block          = block;
            this.insertionPoint = Vector3f.Zero;
            this.scale          = new Vector3f(1.0f, 1.0f, 1.0f);
            this.rotation       = 0.0f;
            this.normal         = Vector3f.UnitZ;
            this.layer          = Layer.Default;
            this.color          = AciColor.ByLayer;
            this.lineType       = LineType.ByLayer;
            this.attributes     = new List <Attribute>();
            foreach (AttributeDefinition attdef in block.Attributes.Values)
            {
                this.attributes.Add(new Attribute(attdef));
            }
            this.endSequence = new EndSequence();
        }
示例#12
0
 /// <summary>
 /// Initializes a new instance of the <c>Polyline</c> class.
 /// </summary>
 public Polyline()
     : base(DxfObjectCode.Polyline)
 {
     this.vertexes = new List<PolylineVertex>();
     this.isClosed = false;
     this.layer = Layer.Default;
     this.color = AciColor.ByLayer;
     this.lineType = LineType.ByLayer;
     this.normal = Vector3f.UnitZ;
     this.elevation = 0.0f;
     this.flags = PolylineTypeFlags.OpenPolyline;
     this.endSequence = new EndSequence();
 }