Thursday, October 23, 2014

Shadows!

I've been working hard on the graphics infrastructure for Legacy*, and I finally have something to show for it! Check out the shadows at the bases of the figures below:


Because of the way I'm calculating light and faking shadows**, shadows are relatively cheap for me, so we can have a lot of them.


Aside from the cool shadows themselves, you'll notice that light is now blocked by walls (those pits you see will actually contain obstructions some day, which is why I have them blocking light.

So now that we know how much light is hitting each tile, we can potentially attach mechanisms to that. I would probably need to find a way to make different light levels more distinct.

So this is a good start but I'm not happy with it. The light tends to either blow out or be too dim, and it's tough to get it balanced, so I might take a look at some HDR techniques to see if I can get better results that way. In Legacy we want to be able to show a fairly broad range of environments, from outdoor daytime to dark dungeons, so I think the HDR sidequest is justified.


*I forked libgdx to fix some bugs and have been looking into OpenGL core profiles.. a real learning experience.
**Ask me about it if you want the details, but I might talk your ear off.

No comments:

Post a Comment