[PROJ] Migrating from PROJ 7 to 8
Thomas Knudsen
knudsen.thomas at gmail.com
Thu Jun 16 14:39:45 PDT 2022
Torsten,
I believe you will find the answer over at
https://proj.org/development/quickstart.html
Where you a.o. will find this example:
b = proj_trans(P, PJ_FWD, a);
/Thomas
Den tor. 12. maj 2022 kl. 12.07 skrev Torsten Martinsen via PROJ <
proj at lists.osgeo.org>:
> Hi,
>
> I have some code (written by a previous coworker) that uses the functions
> pj_ctx_alloc(), pj_init_plus_ctx(), and pj_fwd(). These have been
> deprecated for some time and were removed in PROJ 8.
>
> I have searched the documentation etc., and while it is quite simple to
> figure out the current equivalents for the two first functions, I cannot
> figure out the replacement for pj_fwd().
>
> For reference, the code in question is in essence:
>
> void projection::forward(double& x, double&y) const
> {
> projUV p;
> p.u = x * geo::deg_to_rad;
> p.v = y * geo::deg_to_rad;
> p = pj_fwd(p, proj_);
> x = p.u * geo::rad_to_deg;
> y = p.v * geo::rad_to_deg;
> }
>
> where 'proj_' is returned from pj_init_plus_ctx().
>
> Regards,
> Torsten Martinsen
> _______________________________________________
> PROJ mailing list
> PROJ at lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/proj
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/proj/attachments/20220616/be932545/attachment.htm>
More information about the PROJ
mailing list