[GRASS-dev] [grass-code R][506] v.what.rast should be able to use other methods like bilinear

Hamish hamish_nospam at yahoo.com
Mon Oct 8 21:37:54 EDT 2007

> I would like to be able to sample a raster map using bilinear
> interpolation at points in a vector map.  I want the resulting raster
> value to end up in an attribute column of the vector map. With existing
> 6.3 tools, this becomes a several step process. 
> v.what.rast does what I need, but only with nearest neighbor sampling.
> I could use v.sample, but that creates a new map/table, and the only
> way to get the attribute back to the original map is to use an SQL
> join, which is unsupported in dbf and sqlite databases.  v.drape could
> also be used, but it also creates a new vector map, which has to
> replace the original, and sometimes the raster information does not
> make sense as a Z-coordinate.
> I've made some changes to v.sample so that it will update a column (and
> not create a new map).  However, I think the cleanest approach would be
> to have a new option for v.what.rast.  Furthermore, IMHO, v.rast.what
> should, through options,  do whatever v.sample does and v.sample should
> be be eliminated.  

v.buffer + v.rast.stats?  Then if you like attach v.buffer centroid
attributes to original points with v.distance or just extract the
centroids and convert them to points (v.extract + v.type).


More information about the grass-dev mailing list