Changeset 655:5c8fa4d23292


Ignore:
Timestamp:
05/16/08 22:28:31 (2 years ago)
Author:
Howard Butler <hobu.inc@…>
Branch:
default
Convert:
svn:1766ff46-f334-0410-ab20-d63176f87757/trunk@722
Message:

support get/set proj4 strings

Location:
python
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • python/liblas/core.py

    r620 r655  
    380380las.LASHeader_SetMax.errcheck = check_return 
    381381 
     382las.LASHeader_GetProj4.argtypes = [ctypes.c_void_p] 
     383las.LASHeader_GetProj4.errcheck = check_value_free 
     384las.LASHeader_SetProj4.restype = ctypes.c_int 
     385las.LASHeader_SetProj4.argtypes = [ctypes.c_void_p, ctypes.c_char_p] 
     386las.LASHeader_SetProj4.errcheck = check_return 
     387 
     388 
    382389las.LASWriter_Create.restype = ctypes.c_void_p 
    383390las.LASWriter_Create.argtypes = [ctypes.c_char_p, ctypes.c_void_p, ctypes.c_int] 
  • python/liblas/header.py

    r620 r655  
    304304    max = property(get_max, set_max) 
    305305 
     306    def get_proj4(self): 
     307        return core.las.LASHeader_GetProj4(self.handle) 
     308    def set_proj4(self, value): 
     309        return core.las.LASHeader_SetProj4(self.handle, value) 
     310    proj4 = property(get_proj4, set_proj4) 
  • python/tests/Header.txt

    r484 r655  
    8181  >>> h.header_size 
    8282  227 
     83   
     84  >>> h.proj4 
     85  '' 
     86  >>> h.proj4 = '+proj=utm +zone=17 +ellps=WGS84 +units=m' 
     87  >>> h.proj4 
     88  '+proj=utm +zone=17 +ellps=WGS84 +units=m' 
Note: See TracChangeset for help on using the changeset viewer.