|
@@ 85-90 (lines=6) @@
|
| 82 |
|
if ($poly[$i - 1]['y'] == $poly[$i]['y']) { |
| 83 |
|
if ($poly[$i - 1]['x'] == $poly[$i]['x']) |
| 84 |
|
continue; // twice the same point |
| 85 |
|
else { // infinite elevation of the edge |
| 86 |
|
if (is_array($bords[$poly[$i]['y']])) |
| 87 |
|
array_push($bords[$poly[$i]['y']], $poly[$i]['x']); |
| 88 |
|
$old_pente = 0; |
| 89 |
|
continue; |
| 90 |
|
} |
| 91 |
|
} |
| 92 |
|
|
| 93 |
|
//echo 'point:'.$poly[$i]['y']; bug here |
|
@@ 95-96 (lines=2) @@
|
| 92 |
|
|
| 93 |
|
//echo 'point:'.$poly[$i]['y']; bug here |
| 94 |
|
// adding the point as a part of an edge |
| 95 |
|
if (is_array($bords[$poly[$i]['y']])) //avoid warning |
| 96 |
|
array_push($bords[$poly[$i]['y']], $poly[$i]['x']); |
| 97 |
|
if (DEBUG) echo '('.$poly[$i]['x'].';'.$poly[$i]['y'].') '; |
| 98 |
|
|
| 99 |
|
/* computing the elevation of the edge going */ |
|
@@ 110-111 (lines=2) @@
|
| 107 |
|
if ($i > 1) |
| 108 |
|
if (($old_pente < 0 && $pente > 0) |
| 109 |
|
|| ($old_pente > 0 && $pente < 0)) { |
| 110 |
|
if (is_array($bords[$poly[$i]['y']])) //avoid warning |
| 111 |
|
array_push($bords[$poly[$i]['y']], $poly[$i]['x']); |
| 112 |
|
|
| 113 |
|
if (DEBUG) |
| 114 |
|
echo '*('.$poly[$i]['x']. |