Opened 13 years ago

Closed 13 years ago

Last modified 13 years ago

#3804 closed defect (fixed)

DXF: wrong curved lines conversion

Reported by: zanollim Owned by: warmerdam
Priority: normal Milestone: 1.8.0
Component: OGR_SF Version: svn-trunk
Severity: normal Keywords: DXF Splines
Cc:

Description

Take a look on the very simple attached dxf file. For example, if I convert this layer to a shapefile, it results completely wrong (no curved lines but straight lines).

Another little DXF improvement request:

KML format has a very useful creation option: nameField

Is it possible to have a similar creation option to create DXF texts (labels)? For example: textField that maps its content to the DXF Text attribute?

Thanks, michele

Attachments (5)

spini.dxf (39.6 KB ) - added by zanollim 13 years ago.
DXF curved lines example
out.gml (25.9 KB ) - added by warmerdam 13 years ago.
autocad2009.png (7.6 KB ) - added by zanollim 13 years ago.
gdal_1.7.2.png (3.3 KB ) - added by zanollim 13 years ago.
qgis_gdal_trunk.png (7.5 KB ) - added by warmerdam 13 years ago.
with gdal trunk and qgis…

Download all attachments as: .zip

Change History (9)

by zanollim, 13 years ago

Attachment: spini.dxf added

DXF curved lines example

comment:1 by warmerdam, 13 years ago

Component: defaultOGR_SF
Keywords: DXF added
Milestone: 1.8.0
Status: newassigned

Michele,

I did a conversion to GML, loaded the result in a viewer and compared to how the dxf was displayed in QCAD. The results seems similar.

OGR does not support true curves so curves are approximated as line strings.

I am attaching my GML for you to examine. If you think the translation results are wrong you will need to be fairly specific about in what way it is wrong.

Currently the DXF writer only supports writing MTEXT entities when the input features has a style string with a LABEL tool. I realize this is not very convenient to prepare with just the commandline tools. I'll take your suggestion under advisement but no promises of action on this front.

by warmerdam, 13 years ago

Attachment: out.gml added

comment:2 by zanollim, 13 years ago

Thank you Frank for the answers, let me try to be more specific...

I attached two screenshots:

  • autocad2009.png --> what I see when I open the file spini.dxf with Autocad 2009
  • gdal_1.7.2 --> what I see when I open the spini.dxf with QGIS (compiled with gdal 1.7.2) or, alternatively, when I open the shapefile created with gdal 1.7.2.

Sorry, but I'm not able to open/convert your GML with my gdal 1.7.2.

by zanollim, 13 years ago

Attachment: autocad2009.png added

by zanollim, 13 years ago

Attachment: gdal_1.7.2.png added

by warmerdam, 13 years ago

Attachment: qgis_gdal_trunk.png added

with gdal trunk and qgis...

comment:3 by warmerdam, 13 years ago

Keywords: Splines added
Milestone: 1.8.0
Resolution: fixed
Status: assignedclosed

On closer review I get the same behavior you see with GDAL 1.7.x (including 1.7.3 now in release candidate). It appears the spline support was only added in trunk and won't be in a regular release until 1.8.0 comes out.

So spline are supported, but not in 1.7.x.

comment:4 by zanollim, 13 years ago

OK, so I'll wait the 1.8.0 release.

Thanks, michele

Note: See TracTickets for help on using tickets.