Grid/Tile generation on n sided polygon surface.

Hi ,

I have got a polygon with n sides where all the edges are parallel to the coordinate axis(XZ)
this polygon form a floor with these edges and , i need to genrate the grid/Mesh for the polygon

ALL THE POLYGON EDGES LIE ON THE SAME PLANE

Think of the floor of the room like this

http://www.alistairmackintosh.co.uk/Media/images/WW%20Trav%20B'Room.JPG

I need to popluate the p X Q cell/title over the surface of the floor which is an n sided polygon.

Any Help will be greatly Appreciated

kumar.k

This question is better suited to the Math & Algos section, and please do not cross post.