February 03, 2006

The Complete CAD Spatial Reference

I have done my share of painting and have found that people take one of four approaches to painting around outlets. 1. Paint over everything, I guess this usually starts by forgetting that the electrical outlet is there, then trying to use the roller to go around it accidentally painting over it and then saying to yourself, that doesn't look that bad doesn’t it? (it does look that bad!) 2. Use a brush to cut around the plates; this usually results in a ridge around the outside of the plate and a small sliver of the underlying color showing through. 3. Tape around the switch plate and then paint. This is the worst one, although depending on your skills of taping (and more importantly removing the tape) it can create a nice finished result; however, it is ten times more work than is needed. 4. The best practice for painting around switch plates is to remove the plates, paint and then after everything is dry put the plates back on. (Same can be said for light fixtures, air vents, etc...)

Best practices for CAD interoperability can take many forms since the use of CAD and GIS data can be very diverse. Last post I discussed the fact that it is always better (although not required) to include a coordinate projection file with your CAD drawings to define where on the world you are. If you don’t you’ll get a little annoying message telling you that the data you’ve added to ArcMap has an unknown spatial reference. Besides that ArcGIS won’t know what to do with your CAD data if it is added or copied to a map frame with a different coordinate projection. ArcGIS will use the coordinates in the drawing unmodified unless you give it more information about where on the globe the data belongs.

Another file that can be included with a CAD drawing is called an ESRI world file. This file is an ASCII file of two sets of coordinates that define a coordinate transformation. The file containts two base points and two target points. If a world file exists in the same directory with the same name as the drawing with a .WLD file extension. The four points in the world file will be used to calculate new coordinates for the drawing. With these four points there is enough information to define a MOVE, SCALE and ROTATE transformation. When data is created in page units or some local coordinate system the world file can be used to push the CAD data into its proper position. If you have 500 drawings that are all oriented correctly one to another, but are drawn in a local coordinate system, say using an origin coordinate (0,0) at the corner of some building, you can create an ESRI world file that defines the proper geographic location of that building corner (0,0) and one other point on the map and then include what the proper coordinates should be. Since each of the drawings is properly oriented one to another, you can save time by simply copying the one world file 500 time renaming it for each file name, with a .WLD extension. By also including a projection file properly named for each of the 500 CAD files, ArcGIS would have a complete and accurate spatial reference for the data in each CAD file even though the data was drawn in a local coordinate system. Better than creating a world file for each of these CAD drawings would be to use your CAD program to MOVE, SCALE and ROTATE the drawing contents into the proper coordinates space so that the ESRI world file would not be needed. World files are for people who don't have or know how to use their CAD program.

What if there was a sample tool that could control your AutoCAD application and use a single ESRI world file definition to update all your CAD drawings for you? What if this tool also allowed you to pick a spatial reference (projection file) for all of them and create the properly named file? Would that be useful to you…? Send me your comments.
FREE hit counter and Internet traffic statistics from freestats.com