QGIS Exporting GIS Data to DXF 15 min HD

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hello this is a quick tutorial on QGIS this tutorial won't cover all the features of QGIS nor will it cover where to find GSD is data on this is specific to DXF export from QGIS so this is I'm going to look at today how to get data outside of QGIS into another format like DXF obviously is AutoCAD which then it can be used in Photoshop or sketchup or some other program from there something that's much more flexible than a shapefile format that is native to GIS so what I'm going to do is add a dataset in order to get started right now the my window is blank so you can see that there's nothing in there so before we can do anything when you actually need to have data to export so I actually have some available here that I downloaded it some GIS files from the county bunch I'm going to select everything I may not use everything but I'd like to see it so I can make that decision just takes a second to load make sure that's all in there and everything's good what I'm going to do is also go up to my layers I'm going to hide all my layers and then that way I can just toggle them on and off one by one so you can see that I have actually the city boundaries for each of the different cities in the county local streets railroad lines school districts etc what I'm going to do is what I'm really interested I think is um these parcel polygons and it's going to be a nice background for a series of maps that I'm working on has a nice rich texture to it gives me an idea about the density and just some different things so what I want to do is definitely be able to use this data now it by default QGIS brings in this color on all of its polygons layers it just assigns a color randomly so next time I open this file it may be a different color in this case what I'm gonna do real quick it's not imperative that I do this I'm just going to turn the color off I do that just graphically so it's a little bit easier to read especially if there's a layer underneath it that the color might be covering I want to be able to see that so in this case I have one layer turned on and I've actually removed the color fill just so I can see the line work by itself so everything looks good I'm ready to go so there's a couple different ways to export to DD XF in order to become a DWG eventually I'm going to start with the most basic one which is a going up to project and then DXF export so you can see it gives you some different settings here gives you a save as and of course it lists your layers so if I want to find my parcel polygon layer make sure that's selected and then I want to it's a little bit different for a Mac and PC what I'm going to do is browse to a path save to my desktop and call this parcels and I'm going to call it DX F so PC will automatically put the DXF a Mac won't so you may have a trouble exporting if you don't have the DXF on there make sure to check that so actually put the DX F in there if it doesn't automatically add it for you this case want to make sure that we have no symbology so we don't want is any any extra information the symbology mode and the scale shouldn't be shouldn't be a factor so I'm got my one layer selected and I'm going to go ahead and just hit OK the little watch and the my rainbow wheel says that's it's thinking which is good if it fails it will put a message in red real quick it'll say df/dx F export failed in this case the little message came up blue DX F export completed what I'm going to do is browse my parcel D X F now what it did was it exported all the parcel information which is why it's a 91 point 1 megabyte file which I know for past experience I may have trouble with in CAD you'll notice when you zoom out it's all the parcel information for the entire county of orange now in this case I'm really not interested in all of that that's just a going to be a waste of time for me to have to open that up and remove it and export it all that stuff when I'm really only interested in this section now there's a couple different ways to just get this section now we're going to go back and do the same process again project X or DX F export we're going to select the same parcel layer I'm going to call this parcels but I'll just call this selection something like that something will give me an idea of what I'm or cropped or something like that or Dana Point the city of Dan point so parcel selections save same thing everything else is saying now this one says here now this has worked it for me in the past but I want to show you just what this feature does and doesn't do export features intersecting the current map extent now in theory that's exactly what I want so I'm going to check that box what it should do this is your map extent so everything that shows up on my screen should actually show up in the export so it's not going to export everything it's just what we're looking at that's exactly what I want it to do so what I'm going to do is hit OK everything looks good it thinks for a second it says completed ok here's kind of the the trick so now we've got 1.2 megabytes you can see that that's quite a bit different than the 91.1 megabytes so i don't even want to open the 91.1 megabytes i know that may even crash my cat i'm going to grab just that 1.2 megabytes i'm going to go and take a look and see what that looks like I'll let CAD think about it for a second now the parcel layers for all the GIS drawings are going to be some of your larger data sets in fact for Orange County the entire data set was 92 megabytes for all those layers that we looked at and it was actually 76 megabytes for just the parcel layer so just to kind of keep that in mind is that the parcel layer creates quite a large number of polylines and therefore is quite large data set so I'm going to go and hit zoom extent to zoom out what I have here is a scale issue this is an issue that I've encountered if I select this little white dot will actually tell me that I have 8833 polylines but I can't actually get in to zoom it now there's something there's a scale bus to going on even though the scale shouldn't be relevant for my export so I'm finding that in this case even though it shows there's information there it's it's not X it's not accessible I can't zoom window it and I can't zoom extents it nor can I copy and paste it in a new drawing so unfortunately even though this shows there's data there it's not I can't do anything with it so there is a workaround to it that I found is there's always more than one way to do something now in this case what you can actually do instead of going Project DXF export and actually I guess before I show you this step is that sometimes another problem with the DXF export is sometimes it actually exports a blank drawing so in this case it shows that there's data there but I'm not able to see it oftentimes what you'll see is doing the DXF export is that it shows a 16 kilobyte file when something should be much larger that tells you that the drawing is empty so 16 kilobytes it just means that it's an empty CAD file so that's another issue that we find that I found as a bug with a DXF export I haven't solved the problem I don't know why so I found a workaround which is right clicking on the layer that you want going down to save as so this is a different way to do it the nice thing about this is it gives you multiple options if I actually wanted to save it as a shapefile and it already is a shapefile but let's say I was to draw my own custom map I can now export it is a shape my shape file in this case I want to selected AutoCAD DXF I'm gonna do the same thing I'm going to browse I'm going to call this parcels and I'm going to call this um in this case I'm just going to do it I'm going to just write save as just so I remember what I'm doing here the differences between the different files and this one says do I want to say I want to do I want the save file to come back to my map no in this case I actually just want to get it out of the map so I'm really not worried about adding it back in again in this case it asked me what extents do I want it gives me a couple different options I can either do the layer extent which is going to be all the parcels and I already know that's I'm able to do that it's just it's too large of a file so in this case I want to do the map view extent so if I click that now pay attention to on the coordinates what it does is you'll see that those those switched those became a much smaller number so what I'm going to do is just hit OK here it's going to ask me about a filter which I'm just going to go with the default setting didn't this time-saving done export has been completed so now what I'm going to do is I'm going to take a look at that file Parcells save as five point six megabytes okay so there's some data there that's good I'm going to see what this looks like what this does first thing I'm going to do is zoom enter zoom extents now this is something that I've seen is the default settings in QGIS is to save polygon layers as patches so I'm not actually exporting polylines I'm exporting polygons and therefore it gives us these hatches now I can run a command in CAD that says generate hatch boundary then I've got to actually generate the hatch boundary and then delete the hatch so what I would like to do is find a way to export DXF from QG is not as hatches but as poly lines I'm going to close that again another file it's not usable for me unfortunately so report over to I'm going to try again another way there's a setting up here called vector and geometry tools and geometry tools allows you to if you scroll down here it says polygons two lines well polygons is what we have here in polygons is also what generates that hatch boundary so if I can convert my polygons to lines then that should solve that problem so go ahead and click polygons two lines it's going to ask me which layer would I like to convert I'm going to scroll down to the parcel polygon layer alright by default wants to export a shape file which we're just going to ignore we'll go ahead and browse to the desktop we're just going to call this you know parcels it doesn't matter we're not going to use the shape files in this case we're just doing this because you can see the here the little button add result to canvas we actually want to bring in a new layer to our canvas and it's going to be a non polygon layer in this case it's going to be a line layer I'm going to go ahead and hit actually what I'm going to do is I'm going to change the name of that to parcels lines and that just reminds me that I'm converting this to lines and then I'll hit OK now even though I've selected the map it's tense when I can that's this that's sorry that's a the next layer so what it's doing unfortunately and this is converting the entire layer so what it's not doing is allowing me to convert just the selection so that in this case if I'm dealing if I'm converting a really large layer with lots of data like the parcel layer then even though I'm only interested in this section in order to convert it to lines I've got to go ahead and convert the entire layer now the nice thing about that is if if I did want to switch and I wanted to export a different part of the city or if I wanted to zoom out if I wanted to add data later I will have that lines layer in my file so I only have to do this on this export one time then I can keep it in my file I can use it again later so again it's only taking this long because if the polygon layer is such a large data set the other layers will much quicker and let this finish up we hit OK you'll notice that the layers turn colors and I'm gonna hit cancel because it's already done so you'll notice it actually have - now I've got a kind of a brown layer or an orange layer and I've got this Parsi parcel polygon so now I parse a line and I parse the polygon in this case I'm interested in the parcel line I'm going to do the same thing we just did in order to generate that hatch file save as browse parcels lines and it's a DXF on a shape file I'm going to come down here to I do not want to add it to my map I've already got it in my map and I do want to set the extent in this case I want to set it to the map view extent so I want to make sure that I'm not generating it for the entire county of lunch hit ok everything is done correctly it will give me a little blue um message okay I'm going to check that file for point nine megabytes again that's good that's quite a bit smaller than the 91 megabytes that that we got when we did the Parcells with no extents and I'm going to go and drag and drop that into my AutoCAD I hope it doesn't take too long to open okay now when I do my zoom extents this time there it is what you'll notice is that it adds to some of these longer lines anything that is any line that touches the map extent if that particular line goes past the map extent it will grab that whole line because it's a connected line so even though I set my math extent to something like this even though my math extent may have been much smaller something like this it will actually grab everything beyond that so anyway that's okay but it have a little too much than not enough so now I can actually just double check it and you'll notice that each each parcel is its own closed polyline and double check that doesn't say closed but if we need to if we did have a problem with it we could always close it should be closed even if it doesn't say it is and now what we can do is we can start creating our base map layer in AutoCAD so I'm going to is actually save this so when I save it it's going to ask me to see if it has a DWG and when you save it as a DWG what you'll notice is that it's actually quite a bit smaller than a DXF which is nice it's only one point six megabytes instead of four point nine so it keeps your file size nice and small nice and nimble and again I can then now decide to go back and do this to a different layer so it's a multi-step process but if getting a line work out of QGIS into AutoCAD is important for your project which a lot of case in a lot of cases it is then it's worth the the effort to do this multi-step process in order to be able to do that again once we do it one time once we get into AutoCAD once it's a DXF becomes a DWG we no longer have to worry about QGIS and in quirks that it has we can now move forward in autocad from here so that was it quick tutorial and quick workaround and I'll follow up with another tutorial that looks at the DXF export process if there's a way to fix that bug and try and bypass to avoid this extra step but in the meantime if you need to get the information out there is a way to do it thank you very much
Info
Channel: Prof Senn
Views: 37,769
Rating: undefined out of 5
Keywords:
Id: lwGhcVdrHHE
Channel Id: undefined
Length: 15min 37sec (937 seconds)
Published: Fri Oct 02 2015
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.