Re: [Algorithms] The rain rendering indoor/outdoor problem
Brought to you by:
vexxed72
From: Francis B. <fra...@ub...> - 2007-09-27 19:16:45
|
That's interesting. I was trying to stay away from particles, but I'm not sure why. When you're saying a ray per particle, do you actually mean one billboard quad, or a bunch? How big are your quads and are your rain textures containing one droplet or a bunch of strokes? -----Original Message----- From: gda...@li... [mailto:gda...@li...] On Behalf Of Jon Watte Sent: September 27, 2007 2:26 PM To: Game Development Algorithms Subject: Re: [Algorithms] The rain rendering indoor/outdoor problem What I've done, and it works, is to spawn rain as actual particles, and=20 trace a ray from the spawn point to the impact point, which will be a=20 roof or the ground. Then let the particle follow its ray. For snow,=20 perturb the particle away from the ray location, but "logically" follow=20 the ray. This sounds really expensive, but it doesn't have to be, for=20 two reasons: 1) You only cast a ray once per particle, when spawning a particle. It=20 then follows the ray, no matter what. You only spawn some small number=20 of particles per frame. 2) You can re-use some of the rays, and re-send particles down the same=20 ray. Nobody will notice that some drops hit exactly where some=20 "previous" drop hit a second ago. You can further fancify it by only spawning drops in the view frustum,=20 and if drops move out of the view frustum on the right-hand side, those=20 drops are re-positioned into the frustum on the left hand side, at the=20 same parametric location along the ray. You need to cast a new ray per=20 drop, but you will have a very effective illusion of there being rain=20 "everywhere" even though you only manage particles that are actually seen. Cheers, / h+ Francis Boivin wrote: > Hello, > > I was wondering if there was some "litterature" or tricks or the trade > to get around the problem of rendering rain when your indoors and > looking outside? The problem being that you obviouslly still want to > render rain, but you want it to appear as it it were outside. > =20 --=20 -- Revenge is the most pointless and damaging of human desires. ------------------------------------------------------------------------ - This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ GDAlgorithms-list mailing list GDA...@li... https://lists.sourceforge.net/lists/listinfo/gdalgorithms-list Archives: http://sourceforge.net/mailarchive/forum.php?forum_name=3Dgdalgorithms-li= s t |