Tidying up after the party…#
After April’s sprint, May was about consolidation. Fewer commits, but most of them were about turning ’lots of shiny new capability’ into ‘something I can actually work in’. Two projects pulled Gremlin along this month: CNCWorkbench (no surprise there) and Skirmish, which was getting its turn sequence and movement phase into shape.
My main distraction this month was my part in Vectric’s stand at Makers Central at the NEC in Birmingham. The new particled-up VictorVector was revealed to the Great British Public inside a Linux-driven, custom-made arcade cabinet.

CNCWorkbench also got some pixel polish in order to drive the QuickDrawing app, which we ran on 4 old (but freshly Linuxed) laptops and the SainSmart Genmitsu CNC machines, so the kids (including some very big kids…) could try their hand at racing Victor to draw a picture using custom GRBL support and an Xbox controller.
One document to rule them all#
April left the CNCWorkbench data scattered all over the place - dexel stock in the CAD document, CSG somewhere else, toolpaths somewhere else again. In May the stock, CAD, CSG and toolpath records all moved into a single WorkbenchDoc, with serialisers and tests to match. On the app side, one DocRenderSystem now draws that document on every screen.
Contours also got simple integer IDs. Sounds trivial, but it means other things - like the toolpaths generated from a contour - can refer to them without Gremlin’s CAD code needing to know toolpaths exist. The dependency arrow keeps pointing the right way, and by the end of the month CNCWorkbench could regenerate every toolpath from the CAD elements that made it.
The arcball that argued with itself#
The Arcball camera controller used to keep its own copy of the orientation, which then had to be kept in sync with the camera’s Transform. Two sources of truth for one thing? That’s a bug waiting to happen.
So I deleted the duplicate. The arcball no longer has any state of its own; it modifies the target entity’s Transform directly, applying per-frame deltas around an orbit centre. One source of truth, and CNCWorkbench’s main screens now share the same arcball, with gamepad bindings to ’twiddle’ the view.
It wasn’t plain sailing afterwards, mind. Later in the month CNCWorkbench developed what my commit messages describe, in technical terms, as ‘orbit craziness’. The root cause turned out to be toggling jogging on and off, which left jogging and the arcball competing for control of the camera.
Skirmish wanted a different kind of camera altogether - looking down on the battlefield - so there’s now a dedicated overhead camera system with a default controller mapping too.
Room for more than one pass#
CNCWorkbench now shows several viewports at once, which the standard ‘draw the scenes’ path wasn’t built for. So DrawScenes has been broken out of Draw as a method you can override, and a state with unusual needs can take over the scene pass without rewriting the whole draw. Alongside it came:
- 3D grid drawing on any plane - CNCWorkbench now shows the XZ plane and the machine extents too,
- new mesh primitives, so the cutting tools can be drawn as 3D meshes in the main views,
- a transparent pass in
GeometryRenderSystemthat writes depth, so see-through things still hide what’s behind them, - 3D shape primitives that sort properly amongst billboards. Skirmish needed exactly this to fix its draw order.
Same file, every OS#
A small fix I’m oddly proud of. PropertyStore files are now binary identical whether they were written on Windows or Linux, and keys keep their order between load and save. Different line endings were making git think files had changed when they hadn’t, and shuffled keys made settings files impossible to compare by eye. There’s also a new SaveData type for simple, flat storage.
Bits & bobs#
- Fonts now come from the UI theme, with a sensible default when there isn’t one.
- A couple of small improvements to OpenGL debug output, for clarity.

