Re: [Algorithms] Hemisphere of points ?
Brought to you by:
vexxed72
From: Peter-Pike S. <pp...@wi...> - 2007-03-06 05:29:00
|
The differential solid angle is the same as it is for cube maps - you are just stretch out the plane: =20 1/( (u^2 + v^2 + 1)^(3/2) ) =20 This is assuming the "Z" is 1, and u/v are the XY axis (so a cube map would just evaluate this expression from [-1,1], if you want a bigger FOV just make u/v go outside of [-1,1]...) =20 No numerical computation is necessary for this term. =20 -Peter-Pike Sloan =20 ________________________________ From: gda...@li... [mailto:gda...@li...] On Behalf Of Jon Watte Sent: Monday, March 05, 2007 3:48 PM To: Game Development Algorithms Subject: Re: [Algorithms] Hemisphere of points ? =20 Paul at Home wrote:=20 Well, ok. I'll be honest, I don't really have the ability either. When I read =20 =20 You will have to compensate for the anisotropy of each pixel in the render target, but that is a pre-process weighting matrix you can calculate once (and fudge if you want :-) =20 =20 I start to dribble! Do you think rhombic pixels would have a big enough=20 effect to worry about ? =20 =20 My guess is that it's only the area that's a problem. You will have a larger area area (in steradians) of a pixel at the corner, as opposed to a pixel in the center, because of the planar projection. This is really quite simple trig; turning one delta-degree into delta-length at the far edge of a triangle (whose English name I've never learned). You can calculate it with finite differencing, even, subtracting tan(A) from tan(A+delta). You can also plot the X, Y locations of the different directions onto a flat grid, to see the distribution for yourself. You could even measure (using a ruler) the difference in area, and fudge the compensation (it's going to be the same for all pixels), which is why I said it's fudge-able :-) I've wanted to do something like this for quite a while, but never had the time, so my ulterior motive is for you to do it and post the code, btw :-) Cheers, / h+ |