In the Tailor Made Software conversion, data-extraction and data-manipulation engines, we map the Entities between DWG and PDF the following way:
Entity Mapping from DWG to PDF
An AutoCAD Drawing file (DWG) has a much more complex file format than an Adobe Portable Document Format (PDF) file. PDF files have a very limited set of entities: paths (essentially moveto, curveto and lineto operators), text and images.
The only “grouping” type element in PDF is the Optional Content Group which is usually used to emulate layers.
Any “higher order” AutoCAD entities, such as dimensions, leaders, faces and, of course, blocks, have to be devolved into many, now unrelated, seperate PDF operators.
|AutoCad Entity||Description||Relationship||PDF types|
|line||two point line||1:1||path|
|polyline||multiple point line, can have “bulges” (arcs)||1:1||path|
|xline||infinite line from point in two directions||1:1||path 1)|
|shape||Elements from an AutoCAD shape file||1:many||various|
|arc||circular arc||1:1||path 2)|
|solid||3 or 4 coordinate solid||1:1||path|
|ray||infinite line from point in one direction||1:1||path*|
|spline||various forms of splines||1:1||path 2)|
|MLine||two or more parallel lines||1:many||path|
|leader||leader lines||1:many||path and text|
|hatch||Filled areas with polygons and donuts||1:many||paths|
|mpolygon||Filled areas with polygons and donuts||1:many||paths|
|attribute||text information associated with block||1:1||text|
|MLeader||Multiple leader lines||1:many||paths|
|Image||Raster Image||1:1||Image 3)|
Note:1) PDF cannot represent an infinite entity where the line keeps going in one or both directions. As a result the XLine and Ray can only be approximate to the edge of the drawing.
Note:2) PDF uses Bezier Splines for curve definition, while AutoCAD can use circles, circular arcs, ellipses, and various forms of splines (not including the Bezier Spline), so any conversion to PDF’s Bezier Spline is approximate.
Note:3) PDF only supports JPEG and PNG images so Image may need to be converted
Entity Mapping from PDF to DWG
Since PDF has a limited set of entity types compared to DWG, a round-trip conversion (DWG->PDF->DWG) would differ greatly from the original DWG.
|PDF Type||Description||Relationship||DWG Type|
|Path||MoveTo, DrawTo||1:1||Line, Polyline, Polygon|
|Path||MoveTo, CurveTo (Bezier segment)||1:1||Circle, Arc, Ellipse, Spline 1)|
|Path||MoveTo, LineTo, CurveTo||1:Many||Polyline, Arc and/or Spline 1)|
Note:1) What sort of entity can be used is determined by the mathmatics of the Bezier Spline (CurveTo) operators in the PDF file and the tolerances allowed. For instance, any Bezier Spline can be approximated by a series of arcs, but it may require A LOT of arcs to do it, depending on the curve and the tolerance. However, for a very large tolerance it is possible to fit a linear polyline. It will not look as good as the series of arcs, but mathmatically it will be correct. So a series of CurveTo operators may end up as a circle, an arc, an ellipse, a series of arcs and line (or a polyline with bulges), or even a spline.
Please Contact us for your specific platform, encapsulation and format requirements, and we’ll build it for you!