public function reduce( $tolerance )
    {
        $this->_tolerance = $tolerance;
        $sentinelKey = 0;
        while ($sentinelKey < $this->count()-1) {
            $testKey = $sentinelKey + 1;
            while ( $sentinelKey < $this->count()-1
                && $this->_isInTolerance($sentinelKey, $testKey) ) {
                unset($this->points[$testKey]);
                $testKey++;
            }
            $this->reindex();
            $sentinelKey++;
        }
        return $this->reindex();
    }
public function reduce( $tolerance )
    {
        $this->_tolerance = $tolerance;
        $sentinelKey = 0;
        while ($sentinelKey < $this->count()-1) {
            $testKey = $sentinelKey + 1;
            while ( $sentinelKey < $this->count()-1
                && $this->_isInTolerance($sentinelKey, $testKey) ) {
                unset($this->points[$testKey]);
                $testKey++;
            }
            $this->reindex();
            $sentinelKey++;
        }
        return $this->reindex();
    }
public function reduce ( $ tolerance ) { $ this -> _tolerance = $ tolerance ; $ sentinelKey = 0 ; while ( $ sentinelKey < $ this -> count ( ) - 1 ) { $ testKey = $ sentinelKey + 1 ; while ( $ sentinelKey < $ this -> count ( ) - 1 && $ this -> _isInTolerance ( $ sentinelKey , $ testKey ) ) { unset ( $ this -> points [ $ testKey ] ) ; $ testKey ++ ; } $ this -> reindex ( ) ; $ sentinelKey ++ ; } return $ this -> reindex ( ) ; }
Remove points with a distance under a given tolerance.

@param double $tolerance Maximum radial distance between points.

@return array Reduced set of points
Remove points with a distance under a given tolerance .