Sign in to follow this  

More Questions on Voxels

Recommended Posts

I've been reading more about voxel engines with 6 degrees of freedom and something's been nagging me for a while now. Regardless of the fact that the voxel world is three dimensional, the monitor you see the voxel world with is two dimensional. The screen is composed of pixels. Not voxels. So, when it comes down to it, the rendering is done in pixels. Wouldn't this mean we can use shaders from the GPU to work some visual effects over the resulting frames generated from modifying the voxel grid? Or is there a speed issue between the CPU and GPU that makes it too slow for the shaders to wait on data from the CPU to work on? Perhaps I'm still completely missing the point/concept. If I'm misguided here please let me know. Thanks!

Share this post

Link to post
Share on other sites
Lets see if I can remember what exactly I was rambling on about before the forum decided to have a "processing error" and lose all of my writing (all after I clicked submit just a split second before going "I should have copied my text just in case").


I was thinking the following:

Use a 2 bit per pixel heightmap to store voxel data and reconstruct cells of voxels (1024v x 1024v x 1024v in dimension where v = voxel).

The way this works is simple but I feel compelled to explain anyways. The cell contains 1073741824 binary voxels (1024^3) consiting of either a single material or no material.

The first bit of any pixel on the heightmap indicates if a voxel is on in that column of the uniform voxel grid which is the cell. The second bit indicates if a voxel is on in the row of the grid. For instance, the 5th pixel in our heightmap would tell us that we have a voxel that needs to be turned on in the 5th column, 5th row of our cell IF both the high and low bits are set.

So in short, the idea here is that it should be possible to store a binary voxel data set consisting of roughly 1 billion voxels in a 256 kilobyte heightmap.

I just had another idea concerning raycasting using the heightmap but Ill save that for when I have something that seems to make sense to me to write about.

Anyways, I'm going to bed. I'd love to see some replies when I wake up regardless if it's positive, negative, or neutral. I just want to hear some thoughts on this.

A couple last things before I post this:
- This is just speculation on a possible (simple) way to store volumetric data
- I haven't considered impact on resources (GPU, CPU, etc..) in regards to reconstructing data out of the heightmap nor have I thought about scenarios such as the geometry being static or dynamic.

//Edited for poor word choice.

[Edited by - caldiar on September 16, 2008 3:44:47 AM]

Share this post

Link to post
Share on other sites
you can use anything you want to process your data afterwards on the gpu. look up deffered rendering for what is possible in screenspace only (hdr tonemapping, bloom/glow, ssao, etc...)

just don't transfer back from the gpu, so they can stay in parallel.

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this