[postgis-devel] [PostGIS] #31: Negative distance buffer

PostGIS trac at osgeo.org
Mon Dec 13 13:48:12 PST 2010


#31: Negative distance buffer
-------------------------------+--------------------------------------------
 Reporter:  joao...@…          |         Type:  defect  
   Status:  new                |     Priority:  medium  
Milestone:  PostGIS 1.4.3      |    Component:  postgis 
  Version:  1.4.X              |   Resolution:  accepted
 Keywords:                     |  
-------------------------------+--------------------------------------------
Changes (by pramsey):

  * status:  accepted => new
  * version:  => 1.4.X
  * milestone:  => PostGIS 1.4.3


Old description:

> I’ve detected a possible bug or at least a bizarre behavior when
> performing
> a buffer query with negative distances (e.g.: SELECT
> st_buffer(a.the_geom,
> -5.725)...). In some cases interior rings are not being used to perform
> the
> inner buffer generation (this is illustrated by the reddish features in
> the
> image attachment) although for most of the cases rings are correctly used
> (green features).
>  Tests using polygon/multipolygon themes revealed the same result. I've
> compared the areas of buffered and non-buffered polygons with very small
> distances, and in some cases the negative buffered area is bigger
> revealing
> the inclusion of the rings areas.
>

>  Performing an intersction positevely identifies the problematic
> polygons:
> SELECT  a.gid,
>         a.the_geom
> FROM    original a, negative_buffer b
> WHERE   st_intersects(a.the_geom, b.st_buffer) AND a.gid<>b.gid;
>
> Enviroment:
> -- WinXP SP2
> -- PostgreSQL 8.2.0.7
> -- PostGIS 1.3.3 (data imported under 1.3.2)

New description:

 I’ve detected a possible bug or at least a bizarre behavior when
 performing
 a buffer query with negative distances (e.g.: SELECT st_buffer(a.the_geom,
 -5.725)...). In some cases interior rings are not being used to perform
 the
 inner buffer generation (this is illustrated by the reddish features in
 the
 image attachment) although for most of the cases rings are correctly used
 (green features).
  Tests using polygon/multipolygon themes revealed the same result. I've
 compared the areas of buffered and non-buffered polygons with very small
 distances, and in some cases the negative buffered area is bigger
 revealing
 the inclusion of the rings areas.


  Performing an intersction positevely identifies the problematic polygons:
 SELECT  a.gid,
         a.the_geom
 FROM    original a, negative_buffer b
 WHERE   st_intersects(a.the_geom, b.st_buffer) AND a.gid<>b.gid;

 Enviroment:
 -- WinXP SP2
 -- PostgreSQL 8.2.0.7
 -- PostGIS 1.3.3 (data imported under 1.3.2)

--

Comment:

 Filed in GEOS at http://trac.osgeo.org/geos/ticket/194

-- 
Ticket URL: <http://trac.osgeo.org/postgis/ticket/31#comment:9>
PostGIS <http://trac.osgeo.org/postgis/>
The PostGIS Trac is used for bug, enhancement & task tracking, a user and developer wiki, and a view into the subversion code repository of PostGIS project.


More information about the postgis-devel mailing list