Imports AutoCAD DWG documents as SceneModels — strokes from
LINE / LWPOLYLINE / POLYLINE / CIRCLE / ARC / ELLIPSE, fills from
3DFACE, recursive INSERT block expansion, and TEXT / MTEXT
rasterised as textured quads.
DWG parsing uses @mlightcad/libredwg-web (Emscripten port of
GNU libredwg) dynamically imported from a CDN on first call.
Licence: libredwg is GPL-3.0; apps shipping it (whether via
this loader's CDN default or a self-hosted copy) must honour
that licence.
See DWGLoadOptions for per-call tuning (scale, colour
overrides, circle tessellation, INSERT recursion limit, text
rasterisation options). The libredwg CDN URLs are configured once on
the constructor — see DWGLoaderParams.
Self-hosting / Node usage
Configure the CDN URLs on the constructor to self-host the WASM blob
(CSP / offline / version pinning):
xeokit AutoCAD DWG Loader
Imports AutoCAD DWG documents as
SceneModels — strokes from LINE / LWPOLYLINE / POLYLINE / CIRCLE / ARC / ELLIPSE, fills from 3DFACE, recursive INSERT block expansion, and TEXT / MTEXT rasterised as textured quads.DWG parsing uses
@mlightcad/libredwg-web(Emscripten port of GNU libredwg) dynamically imported from a CDN on first call. Licence: libredwg is GPL-3.0; apps shipping it (whether via this loader's CDN default or a self-hosted copy) must honour that licence.Usage
See DWGLoadOptions for per-call tuning (scale, colour overrides, circle tessellation, INSERT recursion limit, text rasterisation options). The libredwg CDN URLs are configured once on the constructor — see DWGLoaderParams.
Self-hosting / Node usage
Configure the CDN URLs on the constructor to self-host the WASM blob (CSP / offline / version pinning):
For Node, dynamic CDN imports don't work without polyfills — pre-initialise libredwg and inject it on the constructor: