search for: update_raster

Displaying 1 result from an estimated 1 matches for "update_raster".

2013 Oct 08
0
PostGIS 2.1 rasters available to Rails code: breadcrumbs
...b!(''}'','']'') eval(str) end # Update a raster band (default: first band) in the database with values from arr. Note that arr can be any # subset of the size of the full raster. Corner is X,Y (or long,lat), with the upper left corner as [1,1]. def self.update_raster(tablename,id,arr,band=1,corner=[1,1]) update_str = <<-END select st_setvalues( (select rast from #{tablename} where rid=#{id}), #{band},#{corner[0]},#{corner[1]}, array#{arr.to_s}::double precision[][] ) END update_str = "update #{tablename} set rast...