[GRASS-dev] Re: [GRASS GIS] #465: r.proj.seg thins along null areas and raster bounds for bilinear and cubic methods

GRASS GIS trac at osgeo.org
Sun Jan 25 15:32:14 EST 2009


#465: r.proj.seg thins along null areas and raster bounds for bilinear and cubic
methods
------------------------+---------------------------------------------------
  Reporter:  kyngchaos  |       Owner:  grass-dev at lists.osgeo.org
      Type:  defect     |      Status:  new                      
  Priority:  major      |   Milestone:                           
 Component:  Raster     |     Version:  svn-develbranch6         
Resolution:             |    Keywords:                           
  Platform:  All        |         Cpu:  All                      
------------------------+---------------------------------------------------
Comment (by kyngchaos):

 Replying to [comment:3 glynn]:
 > The existing behaviour regarding actual nulls is correct, and will be
 preserved. If you want nulls filled, use e.g. r.fillnulls. Don't go
 stuffing ad-hoc fudges into r.proj.

 The problem is not when the target input cell is null - that I don't have
 a problem with.  It's when input cell is non-null, but some or all of the
 cells in the surrounding interpolation matrix are null.  The basic
 interpolation algorithms need values in all cells, and I'm suggesting an
 option to fake those surrounding values (in the worst case, the
 interpolation drops down to a nearest neighbor interp).

 It comes down to - if there is a cell in the input, I want a cell there in
 the output.  Hmmm, I suppose this would work (could be done from the
 main.c loop), and it would not mess with the algorithms:

  * if cubic option, interpolate cell cubic
  * if no value yet, or bilinear option, interpolate cell bilinear
  * if no value yet, or nearest option, interpolate cell nearest

 This would attempt lower interpolations if the higher one did not work
 because of nulls in the matrix.

-- 
Ticket URL: <http://trac.osgeo.org/grass/ticket/465#comment:4>
GRASS GIS <http://grass.osgeo.org>


More information about the grass-dev mailing list