PostGIS  2.3.8dev-r@@SVN_REVISION@@

◆ pt2gdt()

def rtrowdump.pt2gdt (   pt)
Translate WKT Raster pixel type to GDAL type

Definition at line 39 of file rtrowdump.py.

39 def pt2gdt(pt):
40  """Translate WKT Raster pixel type to GDAL type"""
41  pixtypes = {
42  '8BUI' : osgeo.gdalconst.GDT_Byte,
43  '16BSI' : osgeo.gdalconst.GDT_Int16,
44  '16BUI' : osgeo.gdalconst.GDT_UInt16,
45  '32BSI' : osgeo.gdalconst.GDT_Int32,
46  '32BUI' : osgeo.gdalconst.GDT_UInt32,
47  '32BF' : osgeo.gdalconst.GDT_Float32,
48  '64BF' : osgeo.gdalconst.GDT_Float64
49  }
50  return pixtypes.get(pt, 'UNKNOWN')
51 
def pt2gdt(pt)
Definition: rtrowdump.py:39