PDA

View Full Version : Polygon with holes



Kumar K
04-26-2004, 08:06 PM
Hi Folks,

I have been creating different walls using polygon to simulate the virtual house. I now need to add doors and windows to those walls. How can I add this on to a filled polygon wall.How can i get a hole on the wall for the window.Any one thinks if its easy to do plz advise me.

Thanks
kumar.k

mikael_aronsson
04-26-2004, 09:42 PM
Hi !

Split up the walls yourself in simpler polygons or use the glu tesselator functions.

If you do use the tesselator place the resulting triangles in a display list or something because the tesselator is usually not that fast.

Mikael

Kumar K
04-27-2004, 09:02 PM
Originally posted by mikael_aronsson:
Hi !

Split up the walls yourself in simpler polygons or use the glu tesselator functions.

If you do use the tesselator place the resulting triangles in a display list or something because the tesselator is usually not that fast.

MikaelThanks u for the suggestion , I need to look into tesselator functions, which is new for me, I need to get the textures for the walls can the tesslator genrates the texture with out filling the windows

Aeluned
04-28-2004, 06:58 AM
You might also look into using the stencil buffer and performing a stencil test.
You would draw your windows, doors, etc into the stencil buffer to mask out these areas.

do a little digging on how to use the stencil buffer.