|
Algorithm 2: Pseudo code of the segmentation algorithm |
|
|
Input: Pxyz (points), Pfsp (feature space parameter of points), thos (distance threshold in object space) |
|
Output: Pid (plane segment index per point), (a, b, c, d) (plane parameter) |
1 |
repeat |
2 |
PSCxyz =Algorithm 1(Pxyz) |
3 |
scpl = nspl = regression plane(PSCxyz) |
4 |
repeat
|
5 |
|
6 |
determine d(Pnewseg, scpl)∀Pnewseg (cf. Eq. 5) |
7 |
|
8 |
nspl (new segment plane) = regression plane(Pnewseg) |
9 |
PSCxyz = {P: Pnewseg ∈ nspl} |
10 |
until
scpl = nspl
|
11 |
|
12 |
Pxyz=Pxyz \ Pnewseg
|
13 |
until
new(sc) = ∅ |
14 |
if ∃ disjunct sub-segments in a segment
then split segment |
15 |
if ∃ similar and touching segments
then merge segments |
|