Thanks a lot guys =D Breakdowns will come but I'm not going to promise anything like I did last time xD
@Hatred: Yes, more of less @Cirle of Friends: Yeah I've had a lot of time to experiment and really wanted realtime shadows, got them working although it costs a bit more performance and memory, The shadows and light are layered now so we paint both wherever we want. Which also gives us some very cool options for special effects and puzzles hehe And we can blend between painted shadows and realtime shadows like this(and very specifically optimize if we keep the light direction static while your progressing through the game:
(The left shadow border is painted, the cube is casting realtime shadows)
That's fantastic, really liking it. I have mocked up a scene in unity quickly that blends between two diffuse textures, a lit texture and a shadow texture that is the same texture but painted bluer and have managed to get the unity shadow to lerp in the second texture, but you're clearly doing some much cleverer stuff.
How are you getting it to cut out on your painted shadows? Your painted shadows can't all be the same tone so I really can't work out how you're doing it unless it's some kind of clamp or something?
wow, that is really cool! how do you do that? are you painting directly in the light map or is some sort of shader magic?
I believe the lightmap is literally just a pipeline thing to help the diffuse painter know where to paint accurately, I don't think it's actually used in game. I might be wrong though.
So I was thinking how would you get something like this and I had an idea.
Do you guys have your assets, textured with no lighting info baked in, then position them in max/maya and bake the lighting in a different set of diffuse textures. And after that you somehow blend them in the engine? I might be horribly wrong though...
Anyhow, great work guys!
my guess is that they baked shadows into layer and then merge with final diffuse. Those baked shadows (+probably some of them were painted by hand) serve as mask too.
Alright I'm just going to explain this in text for now because I don't have a lot of time to break this down with images but I'll get down to that in the future.
The thing we wanted was to have a very artistic approach to the whole painting part so I wouldn't have to bother with making sure I am on a "correct" layer when painting darks or lights.
I was trying to achieve fully real-time shadows with a rotating sun but to keep it in style that meant I had to paint the scene with a complete light layer, and a complete dark layer. This was a very mind bending approach and the global illumination would also get lost mostly.
I tried it with special masks and multiple layers but it really slowed down my process, created a lot of frustration and I was unable to get myself in the "flow" for painting.
So we resorted to just static shadows like we had but the once we had some blockout characters on top of the scene they didn't really feel grounded. So I went back to the drawing board and made a compromise.
We are now keeping a static sun direction throughout the game, this means I always know what will be in shadow (I do not know what will be in light because we are going to cast shadows on that)
So my process is as follows:
I model and UV the scene, I paint whatever I want it to look like with lights and darks and everything on a single layer, I am not really using baked lightmaps anymore, mostly because I like to cheat:P. What I do instead is "play" the sun in Mari, this just means that I position my camera viewpoint as if looking at my scene from the suns direction, and painting the light with objects blocking my paint. This gives me full control over what I want to enhance and where I want to cheat.
When I like what I did I make a second layer and only paint a dark layer on top of the light layer, having full control over whatever will be the dark layer, So I could have things appear in your shadow that wouldn't be there before.
Then in unity I apply the fully painted version as the main texture, then I put the dark texture on top and use a shadow buffer as mask. Another great benefit from this approach is that you can keep the shadow drawing distance and the amount of shadow casting objects very small because if you zoom out the painted shadows will take over and it will look almost the same. The game actually runs way better than I expected and my realtime shadows are as tight as the painted ones.
Wow, Fantastic stuff! I feel like I just caught up to the current episode in a tv show but now I have to wait for the next episode to actually air before I get to watch it. Can't wait to see more!
Replies
That's fantastic, really liking it. I have mocked up a scene in unity quickly that blends between two diffuse textures, a lit texture and a shadow texture that is the same texture but painted bluer and have managed to get the unity shadow to lerp in the second texture, but you're clearly doing some much cleverer stuff.
How are you getting it to cut out on your painted shadows? Your painted shadows can't all be the same tone so I really can't work out how you're doing it unless it's some kind of clamp or something?
Amazing stuff.
I believe the lightmap is literally just a pipeline thing to help the diffuse painter know where to paint accurately, I don't think it's actually used in game. I might be wrong though.
Do you guys have your assets, textured with no lighting info baked in, then position them in max/maya and bake the lighting in a different set of diffuse textures. And after that you somehow blend them in the engine? I might be horribly wrong though...
Anyhow, great work guys!
The thing we wanted was to have a very artistic approach to the whole painting part so I wouldn't have to bother with making sure I am on a "correct" layer when painting darks or lights.
I was trying to achieve fully real-time shadows with a rotating sun but to keep it in style that meant I had to paint the scene with a complete light layer, and a complete dark layer. This was a very mind bending approach and the global illumination would also get lost mostly.
I tried it with special masks and multiple layers but it really slowed down my process, created a lot of frustration and I was unable to get myself in the "flow" for painting.
So we resorted to just static shadows like we had but the once we had some blockout characters on top of the scene they didn't really feel grounded. So I went back to the drawing board and made a compromise.
We are now keeping a static sun direction throughout the game, this means I always know what will be in shadow (I do not know what will be in light because we are going to cast shadows on that)
So my process is as follows:
I model and UV the scene, I paint whatever I want it to look like with lights and darks and everything on a single layer, I am not really using baked lightmaps anymore, mostly because I like to cheat:P. What I do instead is "play" the sun in Mari, this just means that I position my camera viewpoint as if looking at my scene from the suns direction, and painting the light with objects blocking my paint. This gives me full control over what I want to enhance and where I want to cheat.
When I like what I did I make a second layer and only paint a dark layer on top of the light layer, having full control over whatever will be the dark layer, So I could have things appear in your shadow that wouldn't be there before.
Then in unity I apply the fully painted version as the main texture, then I put the dark texture on top and use a shadow buffer as mask. Another great benefit from this approach is that you can keep the shadow drawing distance and the amount of shadow casting objects very small because if you zoom out the painted shadows will take over and it will look almost the same. The game actually runs way better than I expected and my realtime shadows are as tight as the painted ones.
^ I wanna play this game right now.
http://www.pokugame.com/devlog/releasing-the-teaser-trailer/