Snow that sticks
by Robert Stewart · in Torque Game Engine · 10/01/2005 (3:12 pm) · 7 replies
I need someway to have snow fall down and add up on the ground. I'm not really sure what to do there. Any advice.
About the author
#2
Here's an article on it:
www.garagegames.com/index.php?sec=mg&mod=resource&page=view&qid=8327
10/01/2005 (4:08 pm)
I believe he does..Here's an article on it:
www.garagegames.com/index.php?sec=mg&mod=resource&page=view&qid=8327
#3
The general principal isnt that hard really.
More or less, the system would function alot like how you would do shadow maps, except instead of checking where your shadows are cast, you check where the snow lands(though a possibly faster path would be where the snow doesnt land, thought that would ultimately be less accurate)
once you figure out where you want your snow, you blur the edgings of the non snowed areas so that it looks more natural, then pull that into your depth buffer and mess with it in there to acheive the actual "building up" of the snow.
The implementation i've seen(as well as the code) functioned like this, minus the depth buffer effect, so basically, you just figured how much snow you wanted, and where you wanted it, and it whited out more according to how much snow collected.
The problem with that was that they implemented a considerably slower method, so it wouldnt be good for games.
If you do want it in your game, i'd say base it off that whitepaper as a start(excellent research, and some good info on the idea as well)
I'm going to be looking alot more into this myself further down the road, so if i get there, i may offer some more detailed advice on it.
Hope i helped, if only slightly,
-Reno out
10/01/2005 (4:17 pm)
I've read that article(and have actually found some code to do it, as well)The general principal isnt that hard really.
More or less, the system would function alot like how you would do shadow maps, except instead of checking where your shadows are cast, you check where the snow lands(though a possibly faster path would be where the snow doesnt land, thought that would ultimately be less accurate)
once you figure out where you want your snow, you blur the edgings of the non snowed areas so that it looks more natural, then pull that into your depth buffer and mess with it in there to acheive the actual "building up" of the snow.
The implementation i've seen(as well as the code) functioned like this, minus the depth buffer effect, so basically, you just figured how much snow you wanted, and where you wanted it, and it whited out more according to how much snow collected.
The problem with that was that they implemented a considerably slower method, so it wouldnt be good for games.
If you do want it in your game, i'd say base it off that whitepaper as a start(excellent research, and some good info on the idea as well)
I'm going to be looking alot more into this myself further down the road, so if i get there, i may offer some more detailed advice on it.
Hope i helped, if only slightly,
-Reno out
#4
Unless of course you're not using it for a game.
10/01/2005 (4:24 pm)
It be interesting to be able to figure out how the player would be able to walk on the snow, even though it is accumulating and growing larger. How would you prevent the snow from piling up on the player, etc.Unless of course you're not using it for a game.
#5
So if you had a sniper on a hill, the snow would accumulate on him, but not if your walking around.
as said, probably not that hard.
10/01/2005 (4:38 pm)
It really wouldnt be all that hard to check really, just make a small check, like, "has this object moved X space in this last stretch of time, and if not, accumulate some more"So if you had a sniper on a hill, the snow would accumulate on him, but not if your walking around.
as said, probably not that hard.
#6
10/01/2005 (9:56 pm)
Wow that is allot of usefull information, thank you all.
#7
10/03/2005 (12:24 pm)
Time to ressurect this thread, anyone have the PDF file for the Real-time Rendering of Accumulated Snow? Someone mentioned TGE Code? Will you be willing to sell?
Associate Joseph Euan