aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorEven Rouault <even.rouault@spatialys.com>2019-12-04 15:32:33 +0100
committerEven Rouault <even.rouault@spatialys.com>2019-12-06 16:06:35 +0100
commit41ff94791abfebaf8cf2c346b4aefb4895248bf3 (patch)
treeed0e5e7ea96035083988e6236accf42da3fb1d60 /src
parentb6f0153e5aa27dc11d2c879dc4a62a0f35a122cb (diff)
downloadPROJ-41ff94791abfebaf8cf2c346b4aefb4895248bf3.tar.gz
PROJ-41ff94791abfebaf8cf2c346b4aefb4895248bf3.zip
Remove obsolete and presumably unfinished implementation of grid catalog functionality
Diffstat (limited to 'src')
-rw-r--r--src/Makefile.am1
-rw-r--r--src/apply_gridshift.cpp4
-rw-r--r--src/datum_set.cpp21
-rw-r--r--src/gc_reader.cpp248
-rw-r--r--src/gridcatalog.cpp306
-rw-r--r--src/lib_proj.cmake2
-rw-r--r--src/malloc.cpp1
-rw-r--r--src/proj_internal.h47
8 files changed, 1 insertions, 629 deletions
diff --git a/src/Makefile.am b/src/Makefile.am
index 2e14d1dd..80596ef8 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -195,7 +195,6 @@ libproj_la_SOURCES = \
release.cpp gauss.cpp \
fileapi.cpp \
\
- gc_reader.cpp gridcatalog.cpp \
nad_cvt.cpp nad_init.cpp nad_intr.cpp \
apply_gridshift.cpp datums.cpp datum_set.cpp transform.cpp \
geocent.cpp geocent.h utils.cpp gridinfo.cpp gridlist.cpp \
diff --git a/src/apply_gridshift.cpp b/src/apply_gridshift.cpp
index e6c7b2b1..2f46ca11 100644
--- a/src/apply_gridshift.cpp
+++ b/src/apply_gridshift.cpp
@@ -89,10 +89,6 @@ int pj_apply_gridshift_2( PJ *defn, int inverse,
double *x, double *y, double *z )
{
- if( defn->catalog_name != nullptr )
- return pj_gc_apply_gridshift( defn, inverse, point_count, point_offset,
- x, y, z );
-
if( defn->gridlist == nullptr )
{
defn->gridlist =
diff --git a/src/datum_set.cpp b/src/datum_set.cpp
index 873d7be5..15d51613 100644
--- a/src/datum_set.cpp
+++ b/src/datum_set.cpp
@@ -41,7 +41,7 @@
int pj_datum_set(projCtx ctx, paralist *pl, PJ *projdef)
{
- const char *name, *towgs84, *nadgrids, *catalog;
+ const char *name, *towgs84, *nadgrids;
projdef->datum_type = PJD_UNKNOWN;
@@ -118,25 +118,6 @@ int pj_datum_set(projCtx ctx, paralist *pl, PJ *projdef)
}
/* -------------------------------------------------------------------- */
-/* Check for grid catalog parameter, and optional date. */
-/* -------------------------------------------------------------------- */
- else if( (catalog = pj_param(ctx, pl,"scatalog").s) != nullptr )
- {
- const char *date;
-
- projdef->datum_type = PJD_GRIDSHIFT;
- projdef->catalog_name = pj_strdup(catalog);
- if (!projdef->catalog_name) {
- pj_ctx_set_errno(ctx, ENOMEM);
- return 1;
- }
-
- date = pj_param(ctx, pl, "sdate").s;
- if( date != nullptr)
- projdef->datum_date = pj_gc_parsedate( ctx, date);
- }
-
-/* -------------------------------------------------------------------- */
/* Check for towgs84 parameter. */
/* -------------------------------------------------------------------- */
else if( (towgs84 = pj_param(ctx, pl,"stowgs84").s) != nullptr )
diff --git a/src/gc_reader.cpp b/src/gc_reader.cpp
deleted file mode 100644
index def52a11..00000000
--- a/src/gc_reader.cpp
+++ /dev/null
@@ -1,248 +0,0 @@
-/******************************************************************************
- * Project: PROJ.4
- * Purpose: Code to read a grid catalog from a .cvs file.
- * Author: Frank Warmerdam, warmerdam@pobox.com
- *
- ******************************************************************************
- * Copyright (c) 2012, Frank Warmerdam <warmerdam@pobox.com>
- *
- * Permission is hereby granted, free of charge, to any person obtaining a
- * copy of this software and associated documentation files (the "Software"),
- * to deal in the Software without restriction, including without limitation
- * the rights to use, copy, modify, merge, publish, distribute, sublicense,
- * and/or sell copies of the Software, and to permit persons to whom the
- * Software is furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included
- * in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
- * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
- * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
- * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *****************************************************************************/
-
-#define PJ_LIB__
-
-#include <ctype.h>
-#include <errno.h>
-#include <stdlib.h>
-#include <string.h>
-
-#include "proj.h"
-#include "proj_internal.h"
-
-static int gc_readentry(projCtx ctx, PAFile fid, PJ_GridCatalogEntry *entry);
-
-/************************************************************************/
-/* pj_gc_readcatalog() */
-/* */
-/* Read a grid catalog from a .csv file. */
-/************************************************************************/
-
-PJ_GridCatalog *pj_gc_readcatalog( projCtx ctx, const char *catalog_name )
-{
- PAFile fid;
- PJ_GridCatalog *catalog;
- int entry_max;
- char line[302];
-
- fid = pj_open_lib( ctx, catalog_name, "r" );
- if (fid == nullptr)
- return nullptr;
-
- /* discard title line */
- pj_ctx_fgets(ctx, line, sizeof(line)-1, fid);
-
- catalog = (PJ_GridCatalog *) calloc(1,sizeof(PJ_GridCatalog));
- if( !catalog )
- {
- pj_ctx_set_errno(ctx, ENOMEM);
- pj_ctx_fclose(ctx, fid);
- return nullptr;
- }
-
- catalog->catalog_name = pj_strdup(catalog_name);
- if (!catalog->catalog_name) {
- pj_ctx_set_errno(ctx, ENOMEM);
- free(catalog);
- pj_ctx_fclose(ctx, fid);
- return nullptr;
- }
-
- entry_max = 10;
- catalog->entries = (PJ_GridCatalogEntry *)
- malloc(entry_max * sizeof(PJ_GridCatalogEntry));
- if (!catalog->entries) {
- pj_ctx_set_errno(ctx, ENOMEM);
- free(catalog->catalog_name);
- free(catalog);
- pj_ctx_fclose(ctx, fid);
- return nullptr;
- }
-
- while( gc_readentry( ctx, fid,
- catalog->entries+catalog->entry_count) == 0)
- {
- catalog->entry_count++;
-
- if( catalog->entry_count == entry_max )
- {
- PJ_GridCatalogEntry* new_entries;
- entry_max = entry_max * 2;
- new_entries = (PJ_GridCatalogEntry *)
- realloc(catalog->entries,
- entry_max * sizeof(PJ_GridCatalogEntry));
- if (new_entries == nullptr )
- {
- int i;
- for( i = 0; i < catalog->entry_count; i++ )
- free( catalog->entries[i].definition );
- free( catalog->entries );
- free( catalog->catalog_name );
- free( catalog );
- pj_ctx_fclose(ctx, fid);
- return nullptr;
- }
- catalog->entries = new_entries;
- }
- }
-
- pj_ctx_fclose(ctx, fid);
-
- return catalog;
-}
-
-/************************************************************************/
-/* gc_read_csv_line() */
-/* */
-/* Simple csv line splitter with fixed maximum line size and */
-/* token count. */
-/************************************************************************/
-
-static int gc_read_csv_line( projCtx ctx, PAFile fid,
- char **tokens, int max_tokens )
-{
- char line[302];
-
- while( pj_ctx_fgets(ctx, line, sizeof(line)-1, fid) != nullptr )
- {
- char *next = line;
- int token_count = 0;
-
- while( isspace(*next) )
- next++;
-
- /* skip blank and comment lines */
- if( next[0] == '#' || next[0] == '\0' )
- continue;
-
- while( token_count < max_tokens && *next != '\0' )
- {
- const char *start = next;
- char* token;
-
- while( *next != '\0' && *next != ',' )
- next++;
-
- if( *next == ',' )
- {
- *next = '\0';
- next++;
- }
-
- token = pj_strdup(start);
- if (!token) {
- while (token_count > 0)
- free(tokens[--token_count]);
- pj_ctx_set_errno(ctx, ENOMEM);
- return 0;
- }
- tokens[token_count++] = token;
- }
-
- return token_count;
- }
-
- return 0;
-}
-
-/************************************************************************/
-/* pj_gc_parsedate() */
-/* */
-/* Parse a date into a floating point year value. Acceptable */
-/* values are "yyyy.fraction" and "yyyy-mm-dd". Anything else */
-/* returns 0.0. */
-/************************************************************************/
-
-double pj_gc_parsedate( projCtx ctx, const char *date_string )
-{
- (void) ctx;
-
- if( strlen(date_string) == 10
- && date_string[4] == '-' && date_string[7] == '-' )
- {
- int year = atoi(date_string);
- int month = atoi(date_string+5);
- int day = atoi(date_string+8);
-
- /* simplified calculation so we don't need to know all about months */
- return year + ((month-1) * 31 + (day-1)) / 372.0;
- }
- else
- {
- return pj_atof(date_string);
- }
-}
-
-
-/************************************************************************/
-/* gc_readentry() */
-/* */
-/* Read one catalog entry from the file */
-/* */
-/* Format: */
-/* gridname,ll_long,ll_lat,ur_long,ur_lat,priority,date */
-/************************************************************************/
-
-static int gc_readentry(projCtx ctx, PAFile fid, PJ_GridCatalogEntry *entry)
-{
-#define MAX_TOKENS 30
- char *tokens[MAX_TOKENS];
- int token_count, i;
- int error = 0;
-
- memset( entry, 0, sizeof(PJ_GridCatalogEntry) );
-
- token_count = gc_read_csv_line( ctx, fid, tokens, MAX_TOKENS );
- if( token_count < 5 )
- {
- error = 1; /* TODO: need real error codes */
- if( token_count != 0 )
- pj_log( ctx, PJ_LOG_ERROR, "Short line in grid catalog." );
- }
- else
- {
- entry->definition = tokens[0];
- tokens[0] = nullptr; /* We take ownership of tokens[0] */
- entry->region.ll_long = dmstor_ctx( ctx, tokens[1], nullptr );
- entry->region.ll_lat = dmstor_ctx( ctx, tokens[2], nullptr );
- entry->region.ur_long = dmstor_ctx( ctx, tokens[3], nullptr );
- entry->region.ur_lat = dmstor_ctx( ctx, tokens[4], nullptr );
- if( token_count > 5 )
- entry->priority = atoi( tokens[5] ); /* defaults to zero */
- if( token_count > 6 )
- entry->date = pj_gc_parsedate( ctx, tokens[6] );
- }
-
- for( i = 0; i < token_count; i++ )
- free( tokens[i] );
-
- return error;
-}
-
-
-
diff --git a/src/gridcatalog.cpp b/src/gridcatalog.cpp
deleted file mode 100644
index 15d81dd7..00000000
--- a/src/gridcatalog.cpp
+++ /dev/null
@@ -1,306 +0,0 @@
-/******************************************************************************
- * Project: PROJ.4
- * Purpose: Code in support of grid catalogs
- * Author: Frank Warmerdam, warmerdam@pobox.com
- *
- ******************************************************************************
- * Copyright (c) 2012, Frank Warmerdam <warmerdam@pobox.com>
- *
- * Permission is hereby granted, free of charge, to any person obtaining a
- * copy of this software and associated documentation files (the "Software"),
- * to deal in the Software without restriction, including without limitation
- * the rights to use, copy, modify, merge, publish, distribute, sublicense,
- * and/or sell copies of the Software, and to permit persons to whom the
- * Software is furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included
- * in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
- * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
- * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
- * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- *****************************************************************************/
-
-#define PJ_LIB__
-
-#include <assert.h>
-#include <math.h>
-#include <stdlib.h>
-#include <string.h>
-
-#include "proj.h"
-#include "proj_internal.h"
-
-static PJ_GridCatalog *grid_catalog_list = nullptr;
-
-static
-PJ_GRIDINFO *pj_gc_findgrid( projCtx_t *ctx,
- PJ_GridCatalog *catalog, int after,
- PJ_LP location, double date,
- PJ_Region *optional_region,
- double *grid_date );
-
-/************************************************************************/
-/* pj_gc_unloadall() */
-/* */
-/* Deallocate all the grid catalogs (but not the referenced */
-/* grids). */
-/************************************************************************/
-
-void pj_gc_unloadall( projCtx ctx )
-{
- (void) ctx;
-
- while( grid_catalog_list != nullptr )
- {
- int i;
- PJ_GridCatalog *catalog = grid_catalog_list;
- grid_catalog_list = grid_catalog_list->next;
-
- for( i = 0; i < catalog->entry_count; i++ )
- {
- /* we don't own gridinfo - do not free here */
- free( catalog->entries[i].definition );
- }
- free( catalog->entries );
- free( catalog->catalog_name );
- free( catalog );
- }
-}
-
-/************************************************************************/
-/* pj_gc_findcatalog() */
-/************************************************************************/
-
-PJ_GridCatalog *pj_gc_findcatalog( projCtx ctx, const char *name )
-
-{
- PJ_GridCatalog *catalog;
-
- pj_acquire_lock();
-
- for( catalog=grid_catalog_list; catalog != nullptr; catalog = catalog->next )
- {
- if( strcmp(catalog->catalog_name, name) == 0 )
- {
- pj_release_lock();
- return catalog;
- }
- }
-
- pj_release_lock();
-
- catalog = pj_gc_readcatalog( ctx, name );
- if( catalog == nullptr )
- return nullptr;
-
- pj_acquire_lock();
- catalog->next = grid_catalog_list;
- grid_catalog_list = catalog;
- pj_release_lock();
-
- return catalog;
-}
-
-/************************************************************************/
-/* pj_gc_apply_gridshift() */
-/************************************************************************/
-
-int pj_gc_apply_gridshift( PJ *defn, int inverse,
- long point_count, int point_offset,
- double *x, double *y, double *z )
-
-{
- int i;
- (void) z;
-
- if( defn->catalog == nullptr )
- {
- defn->catalog = pj_gc_findcatalog( defn->ctx, defn->catalog_name );
- if( defn->catalog == nullptr )
- return defn->ctx->last_errno;
- }
-
- defn->ctx->last_errno = 0;
-
- for( i = 0; i < point_count; i++ )
- {
- long io = i * point_offset;
- PJ_LP input, output_after, output_before;
- double mix_ratio;
- PJ_GRIDINFO *gi;
-
- input.phi = y[io];
- input.lam = x[io];
-
- /* make sure we have appropriate "after" shift file available */
- if( defn->last_after_grid == nullptr
- || input.lam < defn->last_after_region.ll_long
- || input.lam > defn->last_after_region.ur_long
- || input.phi < defn->last_after_region.ll_lat
- || input.phi > defn->last_after_region.ll_lat ) {
- defn->last_after_grid =
- pj_gc_findgrid( defn->ctx, defn->catalog,
- 1, input, defn->datum_date,
- &(defn->last_after_region),
- &(defn->last_after_date));
- if( defn->last_after_grid == nullptr )
- {
- pj_ctx_set_errno( defn->ctx, PJD_ERR_FAILED_TO_LOAD_GRID );
- return PJD_ERR_FAILED_TO_LOAD_GRID;
- }
- }
- gi = defn->last_after_grid;
- assert( gi->child == nullptr );
-
- /* load the grid shift info if we don't have it. */
- if( gi->ct->cvs == nullptr && !pj_gridinfo_load( defn->ctx, gi ) )
- {
- pj_ctx_set_errno( defn->ctx, PJD_ERR_FAILED_TO_LOAD_GRID );
- return PJD_ERR_FAILED_TO_LOAD_GRID;
- }
-
- output_after = nad_cvt( input, inverse, gi->ct );
- if( output_after.lam == HUGE_VAL )
- {
- if( defn->ctx->debug_level >= PJ_LOG_DEBUG_MAJOR )
- {
- pj_log( defn->ctx, PJ_LOG_DEBUG_MAJOR,
- "pj_apply_gridshift(): failed to find a grid shift table for\n"
- " location (%.7fdW,%.7fdN)",
- x[io] * RAD_TO_DEG,
- y[io] * RAD_TO_DEG );
- }
- continue;
- }
-
- if( defn->datum_date == 0.0 )
- {
- y[io] = output_after.phi;
- x[io] = output_after.lam;
- continue;
- }
-
- /* make sure we have appropriate "before" shift file available */
- if( defn->last_before_grid == nullptr
- || input.lam < defn->last_before_region.ll_long
- || input.lam > defn->last_before_region.ur_long
- || input.phi < defn->last_before_region.ll_lat
- || input.phi > defn->last_before_region.ll_lat ) {
- defn->last_before_grid =
- pj_gc_findgrid( defn->ctx, defn->catalog,
- 0, input, defn->datum_date,
- &(defn->last_before_region),
- &(defn->last_before_date));
- if( defn->last_before_grid == nullptr )
- {
- pj_ctx_set_errno( defn->ctx, PJD_ERR_FAILED_TO_LOAD_GRID );
- return PJD_ERR_FAILED_TO_LOAD_GRID;
- }
- }
-
- gi = defn->last_before_grid;
- assert( gi->child == nullptr );
-
- /* load the grid shift info if we don't have it. */
- if( gi->ct->cvs == nullptr && !pj_gridinfo_load( defn->ctx, gi ) )
- {
- pj_ctx_set_errno( defn->ctx, PJD_ERR_FAILED_TO_LOAD_GRID );
- return PJD_ERR_FAILED_TO_LOAD_GRID;
- }
-
- output_before = nad_cvt( input, inverse, gi->ct );
- if( output_before.lam == HUGE_VAL )
- {
- if( defn->ctx->debug_level >= PJ_LOG_DEBUG_MAJOR )
- {
- pj_log( defn->ctx, PJ_LOG_DEBUG_MAJOR,
- "pj_apply_gridshift(): failed to find a grid shift table for\n"
- " location (%.7fdW,%.7fdN)",
- x[io] * RAD_TO_DEG,
- y[io] * RAD_TO_DEG );
- }
- continue;
- }
-
- mix_ratio = (defn->datum_date - defn->last_before_date)
- / (defn->last_after_date - defn->last_before_date);
-
- y[io] = mix_ratio * output_after.phi
- + (1.0-mix_ratio) * output_before.phi;
- x[io] = mix_ratio * output_after.lam
- + (1.0-mix_ratio) * output_before.lam;
- }
-
- return 0;
-}
-
-/************************************************************************/
-/* pj_c_findgrid() */
-/************************************************************************/
-
-static
-PJ_GRIDINFO *pj_gc_findgrid( projCtx ctx, PJ_GridCatalog *catalog, int after,
- PJ_LP location, double date,
- PJ_Region *optional_region,
- double *grid_date )
-{
- int iEntry;
- PJ_GridCatalogEntry *entry = nullptr;
-
- for( iEntry = 0; iEntry < catalog->entry_count; iEntry++ )
- {
- entry = catalog->entries + iEntry;
-
- if( (after && entry->date < date)
- || (!after && entry->date > date) )
- continue;
-
- if( location.lam < entry->region.ll_long
- || location.lam > entry->region.ur_long
- || location.phi < entry->region.ll_lat
- || location.phi > entry->region.ur_lat )
- continue;
-
- if( entry->available == -1 )
- continue;
-
- break;
- }
-
- if( entry == nullptr )
- {
- if( grid_date )
- *grid_date = 0.0;
- if( optional_region != nullptr )
- memset( optional_region, 0, sizeof(PJ_Region));
- return nullptr;
- }
-
- if( grid_date )
- *grid_date = entry->date;
-
- if( optional_region )
- {
-
- }
-
- if( entry->gridinfo == nullptr )
- {
- PJ_GRIDINFO **gridlist = nullptr;
- int grid_count = 0;
- gridlist = pj_gridlist_from_nadgrids( ctx, entry->definition,
- &grid_count);
- // FIXME: this leaks gridlist itself, and memory ownership of
- // entry->gridinfo is also confusing. Coverity CID 193539
- if( grid_count == 1 )
- entry->gridinfo = gridlist[0];
- }
-
- return entry->gridinfo;
-}
-
diff --git a/src/lib_proj.cmake b/src/lib_proj.cmake
index d1bc8836..1b0db531 100644
--- a/src/lib_proj.cmake
+++ b/src/lib_proj.cmake
@@ -234,11 +234,9 @@ set(SRC_LIBPROJ_CORE
fileapi.cpp
fwd.cpp
gauss.cpp
- gc_reader.cpp
geocent.cpp
geocent.h
geodesic.c
- gridcatalog.cpp
gridinfo.cpp
gridlist.cpp
init.cpp
diff --git a/src/malloc.cpp b/src/malloc.cpp
index 393437e3..d2e2d87a 100644
--- a/src/malloc.cpp
+++ b/src/malloc.cpp
@@ -228,7 +228,6 @@ PJ *pj_default_destructor (PJ *P, int errlev) { /* Destructor */
/* free grid lists */
pj_dealloc( P->gridlist );
pj_dealloc( P->vgridlist_geoid );
- pj_dealloc( P->catalog_name );
/* We used to call pj_dalloc( P->catalog ), but this will leak */
/* memory. The safe way to clear catalog and grid is to call */
diff --git a/src/proj_internal.h b/src/proj_internal.h
index 3ca927a3..ffa533e7 100644
--- a/src/proj_internal.h
+++ b/src/proj_internal.h
@@ -490,20 +490,6 @@ struct PJconsts {
int is_long_wrap_set = 0;
char axis[4] = {0,0,0,0}; /* Axis order, pj_transform/pj_adjust_axis */
- /* New Datum Shift Grid Catalogs */
- char *catalog_name = nullptr;
- struct _PJ_GridCatalog *catalog = nullptr;
-
- double datum_date = 0.0; /* TODO: Description needed */
-
- struct _pj_gi *last_before_grid = nullptr; /* TODO: Description needed */
- PJ_Region last_before_region = {0,0,0,0}; /* TODO: Description needed */
- double last_before_date = 0.0; /* TODO: Description needed */
-
- struct _pj_gi *last_after_grid = nullptr; /* TODO: Description needed */
- PJ_Region last_after_region = {0,0,0,0}; /* TODO: Description needed */
- double last_after_date = 0.0; /* TODO: Description needed */
-
/*************************************************************************************
ISO-19111 interface
**************************************************************************************/
@@ -795,27 +781,6 @@ typedef struct _pj_gi {
struct _pj_gi *child;
} PJ_GRIDINFO;
-typedef struct {
- PJ_Region region;
- int priority; /* higher used before lower */
- double date; /* year.fraction */
- char *definition; /* usually the gridname */
-
- PJ_GRIDINFO *gridinfo;
- int available; /* 0=unknown, 1=true, -1=false */
-} PJ_GridCatalogEntry;
-
-typedef struct _PJ_GridCatalog {
- char *catalog_name;
-
- PJ_Region region; /* maximum extent of catalog data */
-
- int entry_count;
- PJ_GridCatalogEntry *entries;
-
- struct _PJ_GridCatalog *next;
-} PJ_GridCatalog;
-
/* procedure prototypes */
double PROJ_DLL dmstor(const char *, char **);
double dmstor_ctx(projCtx_t *ctx, const char *, char **);
@@ -894,18 +859,6 @@ PJ_GRIDINFO *pj_gridinfo_init( projCtx_t *, const char * );
int pj_gridinfo_load( projCtx_t *, PJ_GRIDINFO * );
void pj_gridinfo_free( projCtx_t *, PJ_GRIDINFO * );
-PJ_GridCatalog *pj_gc_findcatalog( projCtx_t *, const char * );
-PJ_GridCatalog *pj_gc_readcatalog( projCtx_t *, const char * );
-void pj_gc_unloadall( projCtx_t *);
-int pj_gc_apply_gridshift( PJ *defn, int inverse,
- long point_count, int point_offset,
- double *x, double *y, double *z );
-int pj_gc_apply_gridshift( PJ *defn, int inverse,
- long point_count, int point_offset,
- double *x, double *y, double *z );
-
-double pj_gc_parsedate( projCtx_t *, const char * );
-
void *proj_mdist_ini(double);
double proj_mdist(double, double, double, const void *);
double proj_inv_mdist(projCtx_t *ctx, double, const void *);