-
-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DXF file can't be saved as SHP #16782
Comments
Author Name: Giovanni Manghi (@gioman) on QGIS master it gives error while exporting to shape, but it gives also a result (attached). Please try and report back. Cheers. Export to vector file failed.
|
Author Name: John Sankey (John Sankey) DXF can contain points, lines and polygons - this one comes from an AutoCAD user. (So can WKT, which I also tried to use for another user's maps earlier - see #16614.) QGIS needs to creat three layers for this DXF, one pont, one line, one polygon. It doesn't, and that's why it fails. This is not only a bug, but a blocker for bringing in these AutoCAD maps. I attach a PDF from the user showing what the result should look like, also a GIF of what I get in QGIS 1.8 with this file.
|
Author Name: Alessandro Ciali (Alessandro Ciali) I tried to import the dxf file as it is, obtaining the same error. but, performing the following feature subset:
|
Author Name: John Sankey (John Sankey) I've asked the user for his version. In the meantime, here is the native DWG of AutoCAD.
|
Author Name: Alessandro Ciali (Alessandro Ciali) I exported the DWG to dxf2000 version. I exported then to shp without problem (see attached shape). In order to correctly export dxf layer to shape, I suggest to follow these steps:
I think that you can close this ticket.
|
Author Name: John Sankey (John Sankey) Alessandro, how do I do step 2 within a DXF layer? (With 1700+ features, it can't be one by one...) Also, when I save-as there is no option to set SHP type to point,line or polygon - I can only do that when I create a new SHP. |
Author Name: Alessandro Ciali (Alessandro Ciali)
|
Author Name: John Sankey (John Sankey) Alessandro, I can't find anything about this in the user manual. I tried the exact phrase you quote and it wiped out many of the lines as well as all points and labels. What are the subclass statements for Polygons, Points, multiline, multipoint etc.? And, how do I get labelled points, which are most of the features on this map? This is definitely a workaround method, not one that should be considered as final in a stable version of QGIS... |
Author Name: Alessandro Ciali (Alessandro Ciali) Hi jhon, the user manual does not contain anything about this because this is a workaround that I use for representing CAD drawing in QGIS. I found this way through some attemps. I attached a QGIS project, you have only to reconnect the dxf you find to the project. See how I have represented the different layers (based from different subclesses of the same dxf file).
|
Author Name: Giovanni Manghi (@gioman)
There are well known issues around DXF files, please see http://lists.osgeo.org/pipermail/qgis-developer/2013-February/024592.html and add your notes. Cheers! |
Author Name: John Sankey (John Sankey) Hi all: please do not close this thread. Here's why: Until very recently GIS systems were far too expensive for individual professionals - of course I thank all those working on QGIS for dramatically changing that. What it meant was that all of us involved in mapping looked for an affordable system, usually one we needed for other work, that allowed numeric data from field surveys to be entered. I started in the '60s with Fortran programs I wrote myself, and transitioned to the 1980's SigmaPlot when it became available. The output of many, such as SigmaPlot, can be converted with a script to WKT - but see #16614 for my problems with that. The next person I tried used AutoCAD, which outputs in DWG (closed, proprietary i.e. useless for open source) and DXF; you can see here the problems with it. I'm certain the next user I try will use yet another available numeric-based system. QGIS needs to work on dealing with these old ersatz methods to allow us all to move to the far superior control of output that a true GIS gives. But in particular, it needs to provide continuing solid support for numerical data from surveys - these continue to be produced by all surveyors. WKT would probably be the most flexible if someone would be willing to work on it to make it solid, as it's easily written directly by anyone with survey data in hand - most of us keep our fieldbooks. My most recent user has his original survey data, so it might well be easier for me to rewrite it in WKT rather than deal with the uncertainties of unknown-vintage DXF or who knows what next format. Many thanks all - I'll do my best to work with Alessandro's work. |
Author Name: Jürgen Fischer (@jef-n)
|
Author Name: John Sankey (John Sankey)
Original Redmine Issue: 7910
Affected QGIS version: 1.8.0
Redmine category:vectors
I've got a DXF file:
Storage type of this layer: DXF
Source for this layer: /Users/john/QGIS/OVPP/OAK VALLEY Drawing.dxf
Geometry type of the features in this layer: Line
The number of features in this layer: 1708
Editing capabilities of this layer:
Extents:
In layer spatial reference system units : xMin,yMin -357.179,-760.168 : xMax,yMax 16008.1,6793.72
Layer Spatial Reference System:
+proj=utm +zone=18 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs
It displays on the screen partly correctly - line features are shown correctly but all labels, such as in legends, are replaced by a single line for each label.
When I save as SHP, it creates:
Storage type of this layer: ESRI Shapefile
Source for this layer: /Users/john/QGIS/OVPP/oakvalley.shp
Geometry type of the features in this layer: Line
The number of features in this layer: 0
Editing capabilities of this layer: Create Spatial Index, Fast Access to Features at ID, Change Geometries
Extents:
In layer spatial reference system units : unknown extent
Layer Spatial Reference System:
+proj=utm +zone=18 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs
The text was updated successfully, but these errors were encountered: