ObjectARX
Table of Contents

This is the main libraries for customizing AutoCAD. It's meant for use in C++, though it's not impossible to be used in other languages by importing as shared / static libraries. Effectively, an extension created as an ARX file is a dynamic shared library which gets loaded into AutoCAD's memory space. It's also the only way to comprehensively customize AutoCAD for both Windows and the Mac. One caveat is that the use of MFC classes will fail when run on the Mac, while the use of Cocoa Objective C UI elements would conversely fail if run on Windows. So apart from having to compile for the 2 OS's the user interface elements needs to be written specifically for the target OS. Note BRX does not have such a strict incompatibility between Windows / Linux.

While some portions of ARX has already been "ported" (or rather wrapped) in other languages / models, it remains the only one which is comprehensive and works (mostly) in both Windows and Mac. The ActiveX/COM model, as well as the DotNet model is simply unavailable in Mac. Thus it is required to link to the ObjectARX libraries from Lisp in order to have the scripting language work with the newer elements of AutoCAD. The last time AutoDesk made any such upgrade to AutoLisp was when they introduced the layerstate functions around 2005 or so. Since then many new elements, e.g. Dynamic Blocks, Fields, Publish, Sheet Sets, eTransmit, Viewport Overrides, Page Setups, Annotative Scaling, Parametric Constraints, etc. are simply not available to inspection / modification through Lisp.

Some of these elements are editable through command invocation, but this is similar to running a command script and thus less than ideal (not to mention slow). Some elements (e.g. Annotative Scaling) is possible to obtain through working on the RAW DXF data inside the drawing, though this is totally undocumented and thus becomes a trail and error (mostly error) exercise. Some portions are available through ActiveX by linking through the Visual Lisp extensions, though when doing so the Lisp becomes incompatible for running on Mac. And most (if not all) elements in verticals of AutoCAD (e.g. MEP / ACA / C3D / etc.) is simply unavailable through either raw DXF or ActiveX, in these cases the only entry points would be DotNet / ObjectARX.

Therefore it becomes a prerogative to extend AutoLisp with functionality to inter-operate with ObjectARX. A perfect scenario would be if the libraries can be directly referenced in the lisp source code.