Polygon with holes

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

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

Originally posted by mikael_aronsson:
[b]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[/b]
Thanks 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

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.