Catchea
Topographic Data Browser
Functions
hgt_plugin.cpp File Reference
#include "hgt_plugin.h"
#include "utils.h"
#include <cstdlib>
#include <cstring>
#include <cstdio>
Include dependency graph for hgt_plugin.cpp:

Functions

char * hgt_path_for (char *folder_path, int lat, int lon)
 
RealTileRealTile__from_hgt_file (const char *filename)
 
RealTileRealTile__from_hgt_file (const char *filename, const int &lat, const int &lon)
 
RealTileRealTile__from_hgt_file_batch (const char *folder_path, const int &lat_min, const int &lon_min, const int &lat_max, const int &lon_max)
 

Detailed Description

Author
JMendyk
Date
21.01.18

Function Documentation

RealTile* RealTile__from_hgt_file ( const char *  filename)

Create RealTile from HGT file, deducing tile's coordinates based on filename

Parameters
[in]filenamepath to HGT file
Returns
NULL if HGT file does not exists or other errors happened, otherwise a valid pointer to RealTile
RealTile* RealTile__from_hgt_file ( const char *  filename,
const int &  lat,
const int &  lon 
)

Create RealTile from HGT file

Parameters
[in]filenamepath to HGT file
[in]latbottom-left corner's latitude of loaded tile
[in]lonbottom-left corner's longitude of loaded tile
Returns
NULL if HGT file does not exists or other errors happened, otherwise a valid pointer to RealTile
RealTile* RealTile__from_hgt_file_batch ( const char *  folder_path,
const int &  lat_min,
const int &  lon_min,
const int &  lat_max,
const int &  lon_max 
)

Load set of HGT file and merge them into one RealTile For files to be loaded in batch, they must match standard pattern, ex. N49E014.hgt.

Parameters
[in]folder_pathpath prefix for HGT files
[in]lat_minlatitude of first tile to load
[in]lon_minlongitude of first tile to load
[in]lat_maxlatitude of last tile to load
[in]lon_maxlongitude of last tile to load
Returns
NULL if any HGT file does not exist or other errors happened, otherwise a valid pointer to RealTile