Some questions
2 posters
Blokworld :: Development :: Information
Page 1 of 1
Some questions
Hey there! First of all, let me say your engine is quite incredible. So I've got some questions about this project of yours
1.) As far as I know, each mesh can only have one material. You divide your map in chunks, so each chunk is a separate mesh. So, how is it possible you have different bump maps for most of your blocks? (It's one mesh-one material in the Unity 3D Game Engine, not sure how you did it though)
2.) Again, not sure how you did it, but; do you generate chunk mesh data in another thread as I have noticed very little lag present.
3.) Lighting - how do you do it? I have heard it's flood-fill, but mind explaining this a bit more or giving a link to a good tutorial?
Thanks a lot for answering.
1.) As far as I know, each mesh can only have one material. You divide your map in chunks, so each chunk is a separate mesh. So, how is it possible you have different bump maps for most of your blocks? (It's one mesh-one material in the Unity 3D Game Engine, not sure how you did it though)
2.) Again, not sure how you did it, but; do you generate chunk mesh data in another thread as I have noticed very little lag present.
3.) Lighting - how do you do it? I have heard it's flood-fill, but mind explaining this a bit more or giving a link to a good tutorial?
Thanks a lot for answering.
octane468- Posts : 3
Join date : 2011-08-08
Re: Some questions
Hi there,
1. I use DirectX 10. One of the main reasons is Texture Arrays. Imagine a single texture that contains 'pages' all the same size, and all mip-mapped properly. It's like a 3d texture but without the 3d mip-mapping (where it blends layers together). Each 'page' is a single texture for a block face. I (basically) use 4 such texture arrays and combine them using a custom pixel shader. Color, Normals, Height and Specular. So, the whole mesh for a chunk uses 4 textures as such but the vertices contain a 'page number' to say which 'page' to reference.
2. The main thread only issues draw calls (and uploads already generated meshes to the GFX card). Everything else is done on other threads.
3. The thread https://blokworld.forumotion.co.uk/t6-lighting-technique goes into a bit of detail about the lighting. This doesn't cover everything in complete detail since there are a good few optimisations that can be performed.
1. I use DirectX 10. One of the main reasons is Texture Arrays. Imagine a single texture that contains 'pages' all the same size, and all mip-mapped properly. It's like a 3d texture but without the 3d mip-mapping (where it blends layers together). Each 'page' is a single texture for a block face. I (basically) use 4 such texture arrays and combine them using a custom pixel shader. Color, Normals, Height and Specular. So, the whole mesh for a chunk uses 4 textures as such but the vertices contain a 'page number' to say which 'page' to reference.
2. The main thread only issues draw calls (and uploads already generated meshes to the GFX card). Everything else is done on other threads.
3. The thread https://blokworld.forumotion.co.uk/t6-lighting-technique goes into a bit of detail about the lighting. This doesn't cover everything in complete detail since there are a good few optimisations that can be performed.
Slaihne- Posts : 264
Join date : 2011-03-17
Age : 56
Re: Some questions
Well, that cleared some things up, thank you
octane468- Posts : 3
Join date : 2011-08-08
Blokworld :: Development :: Information
Page 1 of 1
Permissions in this forum:
You cannot reply to topics in this forum
|
|
Fri Jul 01, 2016 7:25 am by croxxx
» Source?
Thu Jul 12, 2012 9:55 am by raistlinthewiz
» Version Available (Take 2)
Sat Jun 09, 2012 3:23 am by kamild1996
» Terrain Rendering Bug
Thu May 17, 2012 8:07 am by sackboy789
» Mystery Block!
Thu Mar 29, 2012 4:42 am by Corvin73
» Your procedural tree/plant seeding technique?
Sat Mar 24, 2012 3:10 am by Slaihne
» Voxeliq project
Wed Mar 07, 2012 4:25 am by raistlinthewiz
» What is a Tech-Test?
Wed Jan 18, 2012 12:32 pm by joeydmars
» Images
Fri Jan 06, 2012 6:02 am by croxxx