#### Archived

This topic is now archived and is closed to further replies.

# Generating Patches from Polygons

This topic is 5982 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

hi, i´ve been concerning with creating patches from polygons for radiosity purposes. for rectangular polys, this is no problem, but how to make patches from triangles, etc? thanks Gammastrahler

##### Share on other sites
Rectangular patches are the easiest to create, because all you need to do is create two planes that are perpendicular to the polygon and perpendicular to each other, and then then generate rectangles in a loop, using the two planes to splut the polygon. If you want, you can break the regtangles into triangles.

##### Share on other sites
quote:

for rectangular polys, this is no problem, but how to make patches from triangles, etc?

If you settled using rectangular patches for your radiosity engine, then it''s better to stay with them throughout the whole scene (and not mix rectangular with triangular patches, or similar). It will give you a more consistent and visually appealing result.

To create patches from a triangle is just as easy as from any other planar polygon: imagine a grid put over your triangle, just as if you would texture map it. Each grid cell (or texel, for the texture map analogy) would be a patch. Some grid cells will be outside of the triangle, they don''t need to be considered in the radiosity process. Other patches will be partially covered, since the triangle outlines will cut through them. In that case, you need to compute the area covered by the triangle, and adjust the patch area in your formfactor calculations accordingly.

/ Yann

1. 1
2. 2
3. 3
Rutin
15
4. 4
khawk
14
5. 5
frob
12

• 9
• 11
• 11
• 23
• 12
• ### Forum Statistics

• Total Topics
633660
• Total Posts
3013221
×