Docs

The API, per language

One C ABI in one library, cadaclysm — reading, meshing and writing under cadaclysm_*, the modelling kernel under cadaclysm_blacksmith_*, in four flavours from the whole of it down to the readers alone — and a wrapper per language over it. The wrappers are open source and ship with the SDK; they share one object model, so every language page has the same sections and the same anchors, and each signature on them is read from the wrapper's own source. A third library, cadaclysm_view, draws the scene in a native window straight from C or C++: see the C API.

Start

Getting started

Fetch the SDK, load the libraries, add the licence, run the first program — in every language.

Start →
Concepts

How it fits together

Scenes, nodes and placements; borrowed memory; errors; the modelling chain and its frames.

Concepts →
LLMs

Modelling with an LLM

One Markdown file that teaches ChatGPT, Gemini or Claude the kernel, so they write the Python that builds the part you describe.

LLMs →
Python

Python API

cadaclysm.py and cadaclysm_blacksmith.py: one file each over ctypes, numpy views for meshes.

Python →
C#

C# API

Cad.cs, Blacksmith.cs and View.cs over P/Invoke: spans over native memory, IDisposable handles.

C# →
Go

Go API

The cadaclysm and blacksmith packages over cgo, errors as values.

Go →
Java

Java API

Cad.java, Blacksmith.java and View.java on the JDK 22 foreign function API.

Java →
Node.js

Node.js API

cadaclysm and cadaclysm/blacksmith over koffi, with typings and async twins.

Node.js →
Rust

Rust API

The cadaclysm-sdk crate, loaded at run time: meshes borrowed for the scene's lifetime, no build script.

Rust →
Swift

Swift API

The Cadaclysm and Blacksmith modules of a Swift package, over the C headers imported as Clang modules.

Swift →
LuaJIT

LuaJIT API

cadaclysm.lua and cadaclysm_blacksmith.lua over the FFI, for LÖVE, LÖVR or a plain luajit: nothing to compile.

LuaJIT →
Godot

Godot API

A GDExtension for Godot 4.4 and later: CadaclysmScene, CadaclysmSolid and the rest in GDScript, with Godot's own types for meshes, transforms and bounds.

Godot →
C++

C++ API

Header-only C++17 over the library: Result<T> instead of exceptions, spans over native memory, a CMake package.

C++ →
C

C API

The three headers, cadaclysm.h, cadaclysm_blacksmith.h and cadaclysm_view.h, and the conventions every call follows.

C →
WebAssembly

In a web page

The web builds, the reader and the kernel: an ES module with typings, run in a Web Worker, and the View that draws through WebGPU or WebGL2.

WebAssembly →
C · Textures

Embedding the View in your own UI

The View as a texture in your own GPU interface: on your Vulkan or Metal device, or shared with fences on Direct3D 12, Direct3D 11, Vulkan and Metal.

C · Textures →
Tutorials

Step by step

Build something small from nothing, with the complete code at every step.

WebAssembly

A web view in ten lines

Step by step: a kernel cuboid on screen with the View — WebGPU or WebGL2, grid, edges and an orbit camera — then the same in a Web Worker.

Start the tutorial →
C++ · Qt

A Qt viewer

Step by step: a desktop app with the node tree on the left in Qt widgets and the file drawn on the right by cadaclysm_view — ticks, highlights and click-to-select, on Windows and Linux (and written for macOS).

Start the tutorial →
Swift · SwiftUI

A SwiftUI viewer

Step by step: a macOS app with the node tree in a SwiftUI sidebar and the file drawn on the right by cadaclysm_view with Metal — ticks, highlights and click-to-select.

Start the tutorial →
Robot bench

Build a robot on the bench

Step by step: snap real hobby parts together by their mounting holes, splines and shafts, move the joints, read the checks and take home STEP, URDF and a bill of materials.

Start the tutorial →
Measure

Measure between two points

Snap the cursor to a part's corners, midpoints and centres, click two points and draw the distance between them, in a web page.

Start the tutorial →
The Kiln

SubD to B-rep

Step by step: sculpt a subdivision cage in the browser and take it home as STEP, an exact solid of NURBS patches, or as STL, OBJ or glTF.

Start the tutorial →
The Mill

Part to G-code

Step by step: set your part on the table, pick your bits and a material, machine it with several end mills — each smaller one cleaning what the larger left — and take home Grbl G-code for a hobby router.

Start the tutorial →
BIM editor

Draw a building, export IFC

Step by step: start from the sample house, draw walls, doors, windows, floors, rooms, columns and beams on levels, change them in the properties panel, list them in schedules, and take the building home as IFC4 or IFC2x3.

Start the tutorial →
Also

Where the rest is written

The query language has its own page; so do the document format the Loom, the Forge and the robot bench save, formats read and written, the blacksmith's operations, the examples in every language, and the licence file. Questions go to the Discord server.