Hi,
3 questions:
First: Is there a best approach on how to implement lighting in a voxel engine? I already have a directional light and shadows, but the brightness of the shadow is the same everythere... I thought about storing a "light level" for each voxel in a texture and compute how dark a shadow is in a post-processing shader (per pixel), so I could not just determine the darkness of the shadows on the voxels, but also of the shadows on characters and objects. Should I do this for lit areas (which are determined by the shadow mapping) or should I just take the diffuse directional lighting intensity plus the intensity of point lights for lit areas?
Second: Are there any other things I could do to improve the look of a voxel game? It is not easy to navigate in caves because everything looks similar, even with textures... I don't know how to describe this... you sometimes can hardly see the edges of a voxel...
Third: How can I achieve that if you look from outside into a cave, everything is really dark, but when you walk into that cave, your eyes get used to the darkness and everything seems a little bit brighter (and vice versa when you leave the cave)? Should I just use the light intensity at the camera position for this?
Screenshot (4.07 MiB)