Pseudo Voxel Effect
Been asked a couple of times why I keep calling my rendering style recently “pseudo” voxels - it’s because it’s not a real voxel rendering. There’s a fairly significant restriction that you can only view from a fixed single angle.
The game world is actually voxels, i.e. theres a huge 3D array that maps out where each single “cube” is in the world. However, the renderer doesn’t do what you might think - it doesn’t march cubes and optimize the mesh in any way. It doesn’t in fact render anything in 3D at all.
The rendering uses a second buffer, almost like a Z buffer. As cubes are added or removed to the world a ray is cast out along the known view angle - to keep this fast the view vector is always (0,-1,-1). If the new cube is not blocked by another it’s added to the buffer, along with it’s depth, whether it’s shadowed and whether it’s top is show (easily calculated by looking at the surrounding blocks). When a block is removed, the second buffer is checked to see if it was the visible block - if it was then scan back from the old cube position to find the new visible block.
Then when rendering scan through the almost Z buffer and rendering the blocks that have been deemed to be visible as simple sprites (of blocks). Take into account whether a block is shadowed and whether it’s top is showing and thats it.
It’s pretty low cost to render but it’s not incredibly efficient to update. The mechanism to determine whether blocks are visible correctly and work out which ones are shadow is a bit fiddly but outside of that it’s really very easy to implement.
So yes, it’s not real voxel. No it’s not as cool. I still like the style of things that come out tho. :)