PDA

View Full Version : Projected Geometry



bobGL
08-31-2008, 10:20 PM
Is there a way to "Project a Geometry" the same way we project textures?

I found this example: http://www.imgtec.com/powervr/insider/demos/shadowtechniques.asp

But from what I understand as long as the "ground" is a plane its working fine but if its like a terrain not really. Is there any way to tweak this technique in order to use it with a terrain?

Cheers,

sqrt[-1]
09-01-2008, 12:09 AM
I would no think so - what are you trying to accomplish with this?

zeoverlord
09-01-2008, 12:13 AM
No, at least not in a simple way as you would have to start clipping or subdividing geometry.

Though there are other techniques that produces similar results to some of the effects that uses it, but that depends a little on what your end result should be like.

bobGL
09-01-2008, 12:30 AM
Well Im working on hardware with OpenGL ES that doesn't have no stencil buffer so no shadow volume... And projected shadowmap is not even an option (too limited in memory)... Im using glLight for the shading (cuz I have no other choice), and Im looking for a "fast" way to get hard shadows.

Brolingstanz
09-01-2008, 02:03 AM
A pretty common hack is to "drop" a shadow onto the geometry from one direction. You get a bit of stretch off-axis, but it's usually not too bad. Find the axis that best represents the "normal" of the receiver then make that the plane of projection. (If this ends up looking like monkyspunk, pretend I never said anything.)

bobGL
09-01-2008, 03:35 AM
nah..... already tried that one... work fine when terrain is smooth but as soon as you got like an hard edge it's looking really strange the shadow it like half hanging in the air... not cool...

zeoverlord
09-01-2008, 04:06 AM
If your dealing with those kind of limitation i think hard shadows are a bit too much to hope for, the only method left for you is using the model to create a cutout of the terrain, this is somewhat processor intensive and seeing your using openGL ES i don't know if you have any to spare.

bobGL
09-01-2008, 04:55 AM
Well that's basically what Im dealing with ;)

http://www.opengl.org/discussion_boards/ubbthreads.php?ubb=showflat&Number=245157#Post245157