Hey all. I have a number of questions about Voxels, Marching cubes etc that I need to be awnsered specifically, as everywhere I look gives no clear definition or proper implementation of the Marching Cubes algorithm.
1. What exactly does it do?
Please do not link wikipedia, as I assure you. I have read over the links countless times.
2. What are it’s clear Implementations?
What can it be used for. Procedual destruction? Procedual environment production?
3. Why use it?
What benifits does it give to the user? Less memory use? Easier caching?
Please help me understand. I really would appreciate it as I am going to set one of my team coders on the sole job of procedually generated terrain that is editable and random. Is voxels/Marching cubes the best way to go.
Thanks for your understanding and commitment to helping me learn
~Myhijim
This isn’t the marching cubes algorithm, but the marching squares algorithm.
But (to my knowledge) the two are quite similar. Marching squares is 2d, marching cubes is 3d.
Voxels are the 3d equivalent of a pixel (I am pretty sure).
As you can probably tell, I know pretty much nothing on the subject.
I am just learning about it myself.
Does anyone at all have ideas on where to start with a voxel engine. I’ve been studying it hard but can’t seem to get it to click.
All I find are C# or other. I would probably be willing to spend my time translating. But where to start?
Depends on your skillz. I’m guessing a C# book aimed at intermediate programmers should be good for now. Later on you can learn the advanced features of C# but all you really need right now is to get used to the syntax differences and maybe recap the basics. Book wise I recommend safari-library as a excellent resource - alternatively there’s a ton of free tutorials via google.
Completely different kettle of fish - feel free to take a look but I expect it’s going to be too different to easily convert.
The algorithm is the same regardless of which language you implement it in. You shouldn’t need to know C# just because the resources you have found are in C#.
So what steps (For the voxel engine) would I need to take?
How would I achieve a randomized peril noise? Is that what I should be aiming for?
Then from there to generating a voxelised blah blah from there?
Can someone please give me a place to start
I consider myself an intermediate programer, for this game I am currently coding I have made a fully fledged inventory and crafting system (Almost identical to minecraft).
A) Find a good book/set of resources that take you from naught to hero.
B) DIY with experimentation googleing.
A while back I made a mandlebrot fractal in U3D. From there it wasn’t hard to start generating simple terrains, then making those terrains 3D was interesting… I stopped there because it wasn’t of great interest to me, but if you spend enough time thinking about the problems + a little reading you can usually ‘rediscover’ how these systems are made. Problem is you can spend a lot of time rediscovering basic formula - finding a good tutorial can save you a lot of time.
You can generate infinite/random terrain with PerlinNoise , create objects for you game (destructible,deformable). Terrain is destructible, you can use it for mining or create trees for business lumberjack in your game. All is possible with marching cubes.
I am on my phone right now so I will probably come back later and expand on this further. What you are really researching is how to create is isosurfaces. Knowing that you should be able to fund tons or research papers on the different methodes that are used. Marching cubes is just an algorithmr creating the isosurface that became so popular that it is being thrown around more often than the real issue that it was created to solve.
I am currently working on a voxel engine as well that uses several techniques to develop isosurfaces and have found several faster alternatives to marching cubes that have similar results. I will probably be posting more on it later when I have all the texturing and editor tools built. I find this stuff really neat and interesting as well. If all goes well I hope to maybe give it away or sell the engine for $25 or something around that price point.