Beispiel #1
0
 def __init__(self, name, mapset='', mtype='CELL', *args, **kargs):
     self.name = name
     self.mapset = mapset
     self.c_cats = libraster.Categories()
     libraster.Rast_init_cats("", ctypes.byref(self.c_cats))
     self._mtype = mtype
     self._gtype = None if mtype is None else RTYPE[mtype]['grass type']
     super(Category, self).__init__(*args, **kargs)
 def __init__(self, mtype=None, *args, **kargs):
     self._cats = libraster.Categories()
     libraster.Rast_init_cats("", ctypes.byref(self._cats))
     self._mtype = mtype
     self._gtype = None if mtype is None else RTYPE[mtype]['grass type']
     super(Category, self).__init__(*args, **kargs)