Beispiel #1
0
Datei: osr.go Projekt: kikht/gdal
// Set spatial reference from various text formats
func (sr SpatialReference) SetFromUserInput(name string) error {
	cName := C.CString(name)
	defer C.free(unsafe.Pointer(cName))
	err := C.OSRSetFromUserInput(sr.cval, cName)
	if err != 0 {
		return error(err)
	}

	return nil
}
Beispiel #2
0
// Set spatial reference from various text formats
func (sr SpatialReference) SetFromUserInput(name string) error {
	cName := C.CString(name)
	defer C.free(unsafe.Pointer(cName))
	return C.OSRSetFromUserInput(sr.cval, cName).Err()
}