Changes between Version 127 and Version 128 of WKTRaster/SpecificationWorking03


Ignore:
Timestamp:
Jul 6, 2011, 1:25:35 PM (13 years ago)
Author:
pracine
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • WKTRaster/SpecificationWorking03

    v127 v128  
    5151 -Default is the smallest of the width or height of the extent of the source geometry divided by 250. If the smallest of the width or height of the extent of the source geometry is zero then a warning is reported an no NULL is returned.
    5252
    53  * It would be interesting to have an option to create a second band with the length of the line or the area of polygon intersecting each pixel. This band could then be used in a subsequent ST_Union() to decide which pixel value to burn (the one with the longest length of the biggest area). For this to be useful ST_Union should work with a ST_MapAlgebra(rast1, rast2) able to refer to pixel value in any band. e.g. rast1.2 referring to the pixel value in the second band. The ST_Union(rast, 'MAX_LENGTH') aggregate could then be implemented with the following state expression: 'CASE WHEN rast1.2 > rast2.2 THEN rast1.1 ELSE rast2.1 ENDIF'. ST_Union(rast, 'MAX_COMBINED_LENGTH') could also use a ST_MapAlgebra(rast1, rast2) able to take a custom user function. The state function that would accumulate, in a temporary table, the total length for a same value over every overlapping pixels and the final function would determine which of the values from the table is the right one to burn in the final raster pixel.
     53 * It would be interesting to have an option to create a second band with the length of the line or the area of polygon intersecting each pixel. This band could then be used in a ST_Union(rast, 'MAX_LENGTH') or a ST_Union(rast, 'MAX_LENGTH') function burning the value of the line having the longest intersection with the pixel or the value of the polygon having the biggest intersecting area. For this to be useful ST_Union should work with a ST_MapAlgebra(rast1, rast2) able to refer to pixel value in any band (e.g. rast1.2 referring to the pixel value in the second band). The ST_Union(rast, 'MAX_LENGTH') aggregate could then be implemented with the following state expression: 'CASE WHEN rast1.2 > rast2.2 THEN rast1.1 ELSE rast2.1 ENDIF'. Otherwise we would have to imbricate four Mapalgebra functions. ST_Union(rast, 'MAX_COMBINED_LENGTH') could use a ST_MapAlgebra(rast1, rast2) able to take a custom user function. The state function would accumulate, in a temporary table, the total intersecting length or area for a same value over every overlapping pixels and the final function would determine which of the values from the temporary table would be the right one to burn in the final raster pixel.
    5454
    5555 '''Variants'''