Visibility and Hidden Surface Removal

Visibility and Hidden Surface Removal Visibility and Hidden Surface Removal

30.12.2013 Views

BSP algorithm • Binary space partitioning of object space to create a binary tree – object-space algorithm • Tree traversal gives back-to-front ordering depending on view point • Creating/updating the tree is time- and space-intensive (do it in preprocessing), but traversal is not – efficient for static group of polygons and dynamic view • Basic idea: render polygons in the half- © Machiraju/Zhang/Möller space at the back first, then front 64

Building the BSP trees • Object space is split by a root polygon (A) and with respect to its surface normal (in front of or behind the root) • Polygons (C) which lie in both spaces are split • Front and back subspaces are divided recursively to form a © Machiraju/Zhang/Möller binary tree 65 B D C 1 C 2 A E B E front back back C 1 front A back D C 2

Building the BSP trees<br />

• Object space is split by<br />

a root polygon (A) <strong>and</strong><br />

with respect to its<br />

surface normal (in front<br />

of or behind the root)<br />

• Polygons (C) which lie<br />

in both spaces are split<br />

• Front <strong>and</strong> back<br />

subspaces are divided<br />

recursively to form a<br />

© Machiraju/Zhang/Möller<br />

binary tree 65<br />

B<br />

D<br />

C 1<br />

C 2<br />

A<br />

E<br />

B E<br />

front back back<br />

C 1<br />

front<br />

A<br />

back<br />

D C 2

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!