Third step of the editor.ts decomposition. Pulls TransformControls
ownership and the gizmo lifecycle out of Editor into a focused module.
GizmoController owns:
control (TransformControls).
Methods take their dependencies as method arguments — no `editor`
reference, no `import type Editor`, no circular import:
configure(camera, domElement, scene, callbacks)
changeMode(type, space)
setSpace(space)
canToggleSpace()
attach(object), detach()
addToScene(scene), removeFromScene(scene)
setVisible(v), isVisible()
Editor exposes the gizmo as `editor.gizmo` and constructs it empty in
the constructor; configure() is called from initialize() once camera
and renderer exist. The two existing public methods stay on Editor as
facades, so the external callers (actions/setTransformMode.ts,
comps/Controls3D.tsx, engine/keymap.ts) keep working unchanged:
Editor.change_mode reads the store's transformSpace and forwards.
Editor.toggleTransformSpace toggles the store and pushes into gizmo.
External readers updated:
helper.ts (SceneUtils.lockUnlockObject + removeTransformControls)
routes through editor.gizmo.attach/detach/addToScene/removeFromScene
instead of poking editor.control directly.
Editor.snapShotOfCurrentFrame uses editor.gizmo.setVisible /
isVisible instead of touching control.visible.
Editor passes editor.gizmo.control to the MouseControls constructor
where it previously passed editor.control.
Dead code removed:
- transform_interaction on Editor: passed by value to MouseControls
(which has its own internal copy that overrides) and the `= true`
write in change_mode mutated a field nothing read. Pure dead code.
- The "if (this.control == undefined) return;" guard immediately
after `new TransformControls(...)` — that branch was unreachable.
- Unused TransformControls import in editor.ts.
Net: editor.ts down to 1196 LOC. Typecheck error count drops by 3.
The IDE for artists.
ArtCraft
ArtCraft is the IDE for interactive AI image and video creation. We turn prompting into crafting, so your ideas become a form of tangible expression and computing. This is Adobe Photoshop for everyone, and we're giving away the source code!
Show, Don't Tell: Advanced Crafting Features
Text-to-image is great, but artists need control. It's important to know what your image will look like before you generate it, and it's vitally important to achieve consistency and repeatability.
Note: all of the above videos were generated for free with Grok Video; the cost to build this README was negligible.
Quick and Easy Prompting
We haven't abandoned text-to-asset generation for quick prototyping and ideation. We support every popular workflow in a first class fashion.
Models and Providers Supported within Artcraft
| Provider | Features |
|---|---|
| Artcraft | Nano Banana, Nano Banana Pro, GPT-Image-1 / 1.5, Seedance 1.0 Lite / 1.5 Pro / 2.0, Seedream 4 / 4.5, Flux 1.1 / Kontext, Veo 2 / 3 / 3.1, Kling 1.6 / 2.1 / 2.5 / 2.6, Sora 2 / Pro, Hunyuan 3d 2 / 3 |
| Grok | Grok Imagine, Grok Video |
| Midjourney | Image Gen (all versions) |
| Sora | Sora 1, Sora 2, GPT-Image-1 |
| WorldLabs | Marble (Gaussian Splat World Generation) |
We're going to be adding the following providers soon: Kling (via Kling website accounts), Google (via API keys), Runway (via website account), Luma (via website account).
We're potentially interested in adding other aggregators for those who already have subscriptions and credits at those providers, for example: OpenArt, FreePik, etc.
Downloads
- Visit our website for the stable Windows and MacOS releases
- Or you can grab a more recent Windows and MacOS build directly
- Linux requires building from source for now
