Convert — Autocad Coordinates To Google Earth
AutoCAD, Google Earth, coordinate transformation, WGS84, KML, geodesy, Helmert transformation. 1. Introduction 1.1 Problem Statement AutoCAD drawings are often created in local coordinate systems (e.g., assumed origin at building corner) to simplify drafting. However, for real-world visualization, environmental analysis, or infrastructure planning, these drawings must be placed accurately on Google Earth’s globe. Manual shifting is imprecise and time-consuming. 1.2 Objective To develop a repeatable, mathematically sound transformation pipeline that converts any AutoCAD coordinate set into a Google Earth KML file with minimal loss of accuracy. 1.3 Scope The paper focuses on 2D horizontal transformation plus vertical conversion from assumed sea level to WGS84 ellipsoidal height. 2. Coordinate Systems Involved | System | Units | Origin | Use | |--------|-------|--------|-----| | AutoCAD World UCS | Meters or feet | Arbitrary (e.g., 0,0 at building SW corner) | Local drafting | | Geographic (WGS84) | Degrees (lat/lon) | Earth’s center of mass | Google Earth | | Projected (UTM) | Meters | Zone central meridian | Intermediate step for scaling |
Author: [Your Name] Affiliation: [Your University/Company] Date: April 14, 2026 Abstract The integration of Computer-Aided Design (CAD) data with Geographic Information Systems (GIS) is a persistent challenge in civil engineering, urban planning, and environmental monitoring. AutoCAD typically operates in local or arbitrary Cartesian coordinate systems (X, Y), while Google Earth requires absolute geospatial referencing (latitude, longitude, and altitude in WGS84). This paper presents a structured methodology for converting AutoCAD coordinates to Google Earth-compatible KML/KMZ formats. The approach involves: (1) identifying control points with known real-world coordinates, (2) applying a 2D Helmert (similarity) transformation to correct for rotation, translation, and scaling, and (3) vertical datum adjustment from local orthometric heights to ellipsoidal heights (WGS84). A case study using a site plan of a university campus demonstrates that the proposed method achieves a horizontal accuracy of ±0.5 m when at least three control points are used. The paper concludes with a practical Python script and QGIS/AutoCAD Map 3D workflows for automation. convert autocad coordinates to google earth
The final KML overlaid on Google Earth showed alignment within 0.5 m of satellite imagery, sufficient for conceptual design and site analysis. import numpy as np from pyproj import Transformer import simplekml def autocad_to_google_earth(auto_points, control_pairs, utm_zone): # auto_points: list of (x, y) in AutoCAD # control_pairs: [ (ac_x, ac_y, lat, lon) ] # Step 1: project lat/lon to UTM transformer = Transformer.from_crs("EPSG:4326", f"EPSG:utm_zone") target_utm = [transformer.transform(lat, lon) for (_, _, lat, lon) in control_pairs] source_ac = [(x, y) for (x, y, _, _) in control_pairs] available via geographiclib or online calculator).
from pyproj import Transformer transformer = Transformer.from_crs("EPSG:4326", "EPSG:32618") # WGS84 to UTM 18N easting, northing = transformer.transform(lat, lon) Find parameters: translation (Tx, Ty), rotation (θ), scale (s). System: E = s*(X*cosθ – Y*sinθ) + Tx N = s*(X*sinθ + Y*cosθ) + Ty utm_zone): # auto_points: list of (x
# Step 2: Helmert (simplified – affine) A = [] B = [] for (x, y), (e, n) in zip(source_ac, target_utm): A.append([x, y, 1, 0]) A.append([y, -x, 0, 1]) B.append(e) B.append(n) params, _, _, _ = np.linalg.lstsq(A, B, rcond=None) a, b, tx, ty = params
Solve using least squares (≥2 points). Implement via numpy.linalg.lstsq . AutoCAD elevation (Z) → orthometric height (H) → ellipsoidal height (h) for Google Earth: h = H + N where N = geoid undulation (from EGM2008, available via geographiclib or online calculator).