https: AGINFO > Raster Data Providing Service > Documents
This page describes the specification of JSON based format for general raster data.
Usually, coordinate system of rasters is as following.
Affine transformation is used to map the raster to the geospatial coordinate system. In other words, it is used to transformed from raster coordinate system to the geospatial coordinate system.
Affine transformation is written as following.
ux = a11 * cx + a12 * cy + b1 uy = a21 * cx + a22 * cy + b2
Where cx
and cy
are row and column index (starting with 0) of the raster, ux
and uy
are position of the left-top corner on the geospatial coordinate system.
Following figure shows mapped raster.
Note that Y-axis of geospatial coordinate system is upward where one of raster coordinate system is downward. Therefore, a22
is usually negative.
"transform" property (1d array) represents as following (Equivalant to ST_Affine()).
[a11, a12, a21, a22, b1, b2]
a11, a21, a12, a22, b1, b2
.ux, uy
means the location of the center of the mesh.b1, a11, a12, b2, a21, a22
."type": "raster"
part should be available within 50 charasters from the starting.{ "type": "raster", "transform": [1,0,0,-1,135,35], "crs": "EPSG:4612", "nodata_values": [11], "data_types": ["float32"], "values": [ [ [11, 12, 13], [14, 15, 16] ] ] }
{ "type": "raster", "transform": [1.11111111000000e-4,0.00000000000000e+0,0.00000000000000e+0,-1.11111111000000e-4,1.34995333333335e+2,3.50016666666580e+1], "crs": "EPSG:3857", "nodata_values": [11,12,11], "data_types": ["int32", "int32", "int32"], "values": [ [ [11, 12, 13], [14, 15, 16] ], [ [11, 12, 13], [14, 15, 16] ], [ [11, 12, 13], [14, 15, 16] ] ] }