[OSRS-PROJ] NTv2 Datum transformation

Frank Warmerdam warmerdam at pobox.com
Thu Nov 20 13:45:35 EST 2003


Brent Fraser wrote:
> Frank,
> 
>   I'm trying to work through a problem using proj4 to do datum conversions
> using NTv2 (the Canadian NAD83/27 datum shift grid file).  It seems that
> Proj4 goes through the list of U.S and Canadian grids as specified in
> pj_datums.c (line 75):
> 
> nadgrids=@conus, at alaska, at ntv2_0.gsb, at ntv1_can.dat
> 
> and uses the first one that returns a reasonable result.  So when I do a
> conversion on 49N 122W, it chooses the conus grid instead of the ntv2_0.gsb
> grid.
> 
> I see that with cs2cs I can set the shift file by specifying
> "+nadgrids=ntv2_0.gsb". Is there a way I can set the shift file to use using
> a proj4 function call (I'm making a VB-callable DLL) ?

Brent,

I am not sure I understand your constraints.  The shift file selected (and
they order they are checked for) is determined by the +nadgrids entry in
a coordinate system definition as passed to pj_init().   You can't really
alter the built-in datum definitions (+datum=nad27 is really just an alias
for the corresponding +nadgrids definition).

Best regards,
-- 
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | Geospatial Programmer for Rent


----------------------------------------
PROJ.4 Discussion List
See http://www.remotesensing.org/proj for subscription, unsubscription
and other information.



More information about the Proj mailing list