Documentation
¶
Index ¶
- Constants
- func GetElevationFromLocalFile(path string, lat, lon float64) (float64, error)
- type LocalFileSrtmStorage
- func (ds LocalFileSrtmStorage) FileExists(dem, zip, fn string) (string, error)
- func (ds LocalFileSrtmStorage) IsNotExists(err error) bool
- func (ds LocalFileSrtmStorage) LoadFile(dem, zip, fn string) ([]byte, error)
- func (ds LocalFileSrtmStorage) SaveFile(dem, zip, fn string, bytes []byte) error
- func (ds LocalFileSrtmStorage) Unzip(dem, fn string, data []byte) error
- type Srtm
- type SrtmLocalStorage
Constants ¶
View Source
const ( DEM1 = "dem1" DEM3 = "dem3" DEMURL0 = "http://viewfinderpanoramas.org/" DEMURL1 = "http://dem.gpxsee.org/" DEMURL2 = "https://step.esa.int/auxdata/dem/SRTMGL1/" SOURCE_VIEW = 0 SOURCE_GPXSEE = 1 SOURCE_ESA = 2 )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type LocalFileSrtmStorage ¶
type LocalFileSrtmStorage struct {
// contains filtered or unexported fields
}
func NewLocalFileSrtmStorage ¶
func NewLocalFileSrtmStorage(source int) (*LocalFileSrtmStorage, error)
func (LocalFileSrtmStorage) FileExists ¶
func (ds LocalFileSrtmStorage) FileExists(dem, zip, fn string) (string, error)
func (LocalFileSrtmStorage) IsNotExists ¶
func (ds LocalFileSrtmStorage) IsNotExists(err error) bool
func (LocalFileSrtmStorage) LoadFile ¶
func (ds LocalFileSrtmStorage) LoadFile(dem, zip, fn string) ([]byte, error)
type Srtm ¶
type Srtm struct {
// contains filtered or unexported fields
}
func (*Srtm) GetElevation ¶
type SrtmLocalStorage ¶
type SrtmLocalStorage interface { // LoadFile loads a file, if not available, then err!=nil and IsNotExists(err) must be true FileExists(dem, zip, fn string) (string, error) LoadFile(dem, zip, fn string) ([]byte, error) IsNotExists(err error) bool SaveFile(dem, zip, fn string, bytes []byte) error Unzip(dem, fn string, data []byte) error }
Click to show internal directories.
Click to hide internal directories.