1 # SPDX-License-Identifier: MIT
2 # Copyright 2012 Manfred Moitzi
4 # Purpose: constant values
5 # Created: 21.07.2012, taken from my ezdxf project
7 from __future__
import unicode_literals
8 __author__
= "mozman <mozman@gmx.at>"
10 ENV_CYTHON
= 'DXFGRABBER_CYTHON'
31 acad
: dxf
for dxf
, acad
in acadrelease
.items()
34 # Entity: Polyline, Polymesh
37 POLYLINE_MESH_CLOSED_M_DIRECTION
= POLYLINE_CLOSED
38 POLYLINE_CURVE_FIT_VERTICES_ADDED
= 2
39 POLYLINE_SPLINE_FIT_VERTICES_ADDED
= 4
40 POLYLINE_3D_POLYLINE
= 8
41 POLYLINE_3D_POLYMESH
= 16
42 POLYLINE_MESH_CLOSED_N_DIRECTION
= 32
43 POLYLINE_POLYFACE
= 64
44 POLYLINE_GENERATE_LINETYPE_PATTERN
=128
47 # 75 surface smooth type
48 POLYMESH_NO_SMOOTH
= 0
49 POLYMESH_QUADRIC_BSPLINE
= 5
50 POLYMESH_CUBIC_BSPLINE
= 6
51 POLYMESH_BEZIER_SURFACE
= 8
55 VERTEXNAMES
= ('vtx0', 'vtx1', 'vtx2', 'vtx3')
56 VTX_EXTRA_VERTEX_CREATED
= 1 ## Extra vertex created by curve-fitting
57 VTX_CURVE_FIT_TANGENT
= 2 ## Curve-fit tangent defined for this vertex.
58 ## A curve-fit tangent direction of 0 may be omitted from the DXF output, but is
59 ## significant if this bit is set.
60 ## 4 = unused, never set in dxf files
61 VTX_SPLINE_VERTEX_CREATED
= 8 ##Spline vertex created by spline-fitting
62 VTX_SPLINE_FRAME_CONTROL_POINT
= 16
63 VTX_3D_POLYLINE_VERTEX
= 32
64 VTX_3D_POLYGON_MESH_VERTEX
= 64
65 VTX_3D_POLYFACE_MESH_VERTEX
= 128
69 'polyline3d': VTX_3D_POLYLINE_VERTEX
,
70 'polymesh': VTX_3D_POLYGON_MESH_VERTEX
,
71 'polyface': VTX_3D_POLYGON_MESH_VERTEX | VTX_3D_POLYFACE_MESH_VERTEX
,
75 'polyline3d': POLYLINE_3D_POLYLINE
,
76 'polymesh': POLYLINE_3D_POLYMESH
,
77 'polyface': POLYLINE_POLYFACE
,
80 #---block-type flags (bit coded values, may be combined):
83 BLK_ANONYMOUS
= 1 # This is an anonymous block generated by hatching, associative dimensioning, other internal operations, or an application
84 BLK_NON_CONSTANT_ATTRIBUTES
= 2 # This block has non-constant attribute definitions (this bit is not set if the block has any attribute definitions that are constant, or has no attribute definitions at all)
85 BLK_XREF
= 4 # This block is an external reference (xref)
86 BLK_XREF_OVERLAY
= 8 # This block is an xref overlay
87 BLK_EXTERNAL
= 16 # This block is externally dependent
88 BLK_RESOLVED
= 32 # This is a resolved external reference, or dependent of an external reference (ignored on input)
89 BLK_REFERENCED
= 64 # This definition is a referenced external reference (ignored on input)
92 LWPOLYLINE_PLINEGEN
= 128
98 SPLINE_LINEAR
= 16 # planar bit is also set
103 MTEXT_MIDDLE_LEFT
= 4
104 MTEXT_MIDDLE_CENTER
= 5
105 MTEXT_MIDDLE_RIGHT
= 6
106 MTEXT_BOTTOM_LEFT
= 7
107 MTEXT_BOTTOM_CENTER
= 8
108 MTEXT_BOTTOM_RIGHT
= 9
110 MTEXT_LEFT_TO_RIGHT
= 1
111 MTEXT_TOP_TO_BOTTOM
= 2