5 ms·
I've been working on a 3D voxel-based game engine for like 10 years in my spare time. The most recent big job has been to port the world gen and editor to the G
by jesse__ 1y ago
I've been working on a 3D voxel-based game engine for like 10 years in my spare time. The most recent big job has been to port the world gen and editor to the GPU, which has had some pretty cute knock-on effects. The most interesting is you can hot-reload the world gen shaders and out pop your changes on the screen, like a voxel version of shadertoy.
https://github.com/scallyw4g/bonsai https://github.com/scallyw4g/bonsai
I also wrote a metaprogramming language which generates a lot of the editor UI for the engine. It's a bespoke C parser that supports a small subset of C++, which is exposed to the user through a 'scripting-like' language you embed directly in your source files. I wrote it as a replacement for C++ templates and in my completely unbiased opinion it is WAY better.
https://github.com/scallyw4g/poof https://github.com/scallyw4g/poof
- throw-qqqqq 1y agoWow the voxel engine work is beautiful! Impressive work man
- jesse__ 1y agoThank you! It's definitely been a labour of love
- jacquesm 1y agoThat is so neat. I built something a little bit like this for a simulator of a 3D portal mill. Trying it on real wood got expensive fast so for debugging runs and trials of designs I would run a simulation where the toolbit would hack out the shape out of a three dimensional array of voxels. This was then displayed using a very simple engine built with PyGame. I got a lot of use out of that and it saved days (and a small forest). Great to see something along those lines but with much better visuals.
- jesse__ 1y agoThat's an interesting application! I'm excited to see where these kinds of projects go now that we have so much computing power.
- jacquesm 1y agoThis thing I built was in 2006 or so iirc, here is a screenshot: https://jacquesmattheij.com/snapshot4.png https://jacquesmattheij.com/snapshot4.png Apologies for the low resolution, I don't think I have a better one.
- apitman 1y agoCool. Especially love the low dependency approach. Readme says OpenGL 3.3. Are you doing the GPU compute using old-school GPGPU techniques?
- jesse__ 1y agoYeah, just render to texture, with one instance of cpu readback (for generating voxel data). There are a couple features I'd like to implement that require 4.3, but I'm pretty committed to the bit at this point. Maybe one day I'll have some optional features.
- abcd_f 1y ago"Function" link in the Examples section of the poof repo is 404.
- jesse__ 1y agoOh, thank you! Will fix that when I'm at my laptop
- ramon156 1y agoDo you know the whole story about HyTale? I feel like you'd be an amazing fit to help out there.
- jesse__ 1y agoI'm nominally familiar with the story. Are you connected to the team in any way? I'd be interested in learning more about the project
- frankfrank13 1y agoLooks so good!
- jesse__ 1y agoThank you!