[postgis-tickets] [PostGIS] #2924: [raster] bogus handling of identity matrix by _st_gdalwarp

PostGIS trac at osgeo.org
Fri Sep 5 08:50:16 PDT 2014


#2924: [raster] bogus handling of identity matrix by _st_gdalwarp
--------------------+-------------------------------------------------------
 Reporter:  strk    |       Owner:  dustymugs    
     Type:  defect  |      Status:  new          
 Priority:  medium  |   Milestone:  PostGIS 2.1.4
Component:  raster  |     Version:  2.1.x        
 Keywords:          |  
--------------------+-------------------------------------------------------
 As reported in #2911, rotating a raster with scale 1/-1 and offset 0/0
 results in wrong output.

 Testcase:
 {{{
 select x, y, m.width, m.height, m.skewx, m.skewy
 from generate_series(-1, 1) x, generate_series(-1, 1) y,
 ST_AddBand(ST_MakeEmptyRaster(10, 10, x, y, 1, -1, 0, 0, 0),
   1, '8BUI', 0, 0) r, st_metadata(st_gdalwarp(r,'NearestNeighbor',
 0.125,NULL,NULL,NULL,NULL,NULL,1,1)) m;
  x  | y  | width | height | skewx | skewy
 ----+----+-------+--------+-------+-------
  -1 | -1 |    10 |     15 |     1 |     1
   0 | -1 |    10 |     15 |     1 |     1
   1 | -1 |    10 |     15 |     1 |     1
  -1 |  0 |    10 |     15 |     1 |     1
   0 |  0 |     1 |     12 |     1 |     1
   1 |  0 |    10 |     15 |     1 |     1
  -1 |  1 |    10 |     15 |     1 |     1
   0 |  1 |    10 |     15 |     1 |     1
   1 |  1 |    10 |     15 |     1 |     1
 (9 rows)
 }}}

 Notice how width/height are different from the others...

-- 
Ticket URL: <http://trac.osgeo.org/postgis/ticket/2924>
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-tickets mailing list