9#ifndef _GEOTIFFDISPATCH_H
10#define _GEOTIFFDISPATCH_H
13#include "ncdispatch.h"
14#include "nc4internal.h"
18#include <geotiff/geotiff.h>
19#include <geotiff/geo_normalize.h>
23#define NC_FORMATX_NC_GEOTIFF NC_FORMATX_UDF1
26#define TIFF_MAGIC_LE 0x4949
27#define TIFF_MAGIC_BE 0x4D4D
30#define TIFF_VERSION_CLASSIC 42
31#define TIFF_VERSION_BIGTIFF 43
34#define TIFF_HEADER_SIZE 8
45#define NC_GEOTIFF_CRS_UNKNOWN 0
46#define NC_GEOTIFF_CRS_GEOGRAPHIC 1
47#define NC_GEOTIFF_CRS_PROJECTED 2
85#if defined(__cplusplus)
91 void *parameters,
const NC_Dispatch *,
int);
107 void *value, nc_type);
115#define GEOTIFF_INIT_OK() (NC_GEOTIFF_initialize() != NULL)
116#define GEOTIFF_INIT_AND_ASSIGN(ret) do { \
117 NC_Dispatch *_d = NC_GEOTIFF_initialize(); \
118 (ret) = (_d != NULL) ? NC_NOERR : NC_ENOTNC; \
137#if defined(__cplusplus)
int NC_GEOTIFF_detect_format(const char *path, int *is_geotiff)
Definition geotifffile.c:467
const NC_Dispatch * GEOTIFF_dispatch_table
Definition geotiffdispatch.c:114
NC_Dispatch * NC_GEOTIFF_initialize(void)
Definition geotiffdispatch.c:123
int NC_GEOTIFF_extract_metadata(NC_FILE_INFO_T *h5, NC_GEOTIFF_FILE_INFO_T *geotiff_info)
struct nc_geotiff_crs_info NC_GEOTIFF_CRS_INFO_T
int NC_GEOTIFF_get_vara(int ncid, int varid, const size_t *start, const size_t *count, void *value, nc_type)
int NC_GEOTIFF_finalize(void)
Definition geotiffdispatch.c:136
int NC_GEOTIFF_close(int ncid, void *ignore)
struct NC_VAR_GEOTIFF_INFO NC_VAR_GEOTIFF_INFO_T
int NC_GEOTIFF_inq_format(int ncid, int *formatp)
int NC_GEOTIFF_open(const char *path, int mode, int basepe, size_t *chunksizehintp, void *parameters, const NC_Dispatch *, int)
int NC_GEOTIFF_inq_format_extended(int ncid, int *formatp, int *modep)
int NC_GEOTIFF_abort(int ncid)
struct NC_GEOTIFF_FILE_INFO NC_GEOTIFF_FILE_INFO_T
NetCDF Extension Pack (NEP) - Public API.
Definition geotiffdispatch.h:69
uint16_t planar_config
Definition geotiffdispatch.h:78
int is_little_endian
Definition geotiffdispatch.h:73
int is_tiled
Definition geotiffdispatch.h:74
uint16_t samples_per_pixel
Definition geotiffdispatch.h:81
NC_GEOTIFF_CRS_INFO_T crs_info
Definition geotiffdispatch.h:82
uint32_t image_width
Definition geotiffdispatch.h:79
uint32_t rows_per_strip
Definition geotiffdispatch.h:77
void * tiff_handle
Definition geotiffdispatch.h:70
void * gtif_handle
Definition geotiffdispatch.h:71
uint32_t tile_width
Definition geotiffdispatch.h:75
uint32_t image_height
Definition geotiffdispatch.h:80
uint32_t tile_height
Definition geotiffdispatch.h:76
char * path
Definition geotiffdispatch.h:72
Definition geotiffdispatch.h:37
int geotiff_data_type
Definition geotiffdispatch.h:39
int band_num
Definition geotiffdispatch.h:38
size_t coord_len
Definition geotiffdispatch.h:41
double * coord_data
Definition geotiffdispatch.h:40
Definition geotiffdispatch.h:51
double central_meridian
Definition geotiffdispatch.h:62
double false_northing
Definition geotiffdispatch.h:60
int epsg_code
Definition geotiffdispatch.h:53
double latitude_of_origin
Definition geotiffdispatch.h:63
int ct_projection
Definition geotiffdispatch.h:54
double inverse_flattening
Definition geotiffdispatch.h:58
double scale_factor
Definition geotiffdispatch.h:61
int crs_type
Definition geotiffdispatch.h:52
char crs_name[NC_MAX_NAME+1]
Definition geotiffdispatch.h:56
double standard_parallel_1
Definition geotiffdispatch.h:64
double standard_parallel_2
Definition geotiffdispatch.h:65
double false_easting
Definition geotiffdispatch.h:59
double semi_major_axis
Definition geotiffdispatch.h:57
int raster_pixel_is_point
Definition geotiffdispatch.h:55