Dear All, I have added the “Times” projection to my private copy of proj4 and tested it. It works properly using proj and unproj.
Could anyone on this list maybe give me a little guidance as to how I can make GDAL aware of this new map projection so that I may use it with GDAL/OGR utilities? If everything works, I’ll submit my updates back to the package maintainers. Many thanks, Jed On 25 Mar 2014, at 11:49, Even Rouault <[email protected]> wrote: > Selon Dmitriy Baryshnikov <[email protected]>: > >> Hi Even, >> >> hfadataset.cpp near 3686 ln >> else if( EQUAL(pszProjName, "Times") ) >> { >> sPro.proNumber = EPRJ_TIMES; >> sPro.proName = (char*) "Times"; >> sPro.proParams[4] = oSRS.GetProjParm(SRS_PP_CENTRAL_MERIDIAN)*D2R; >> sPro.proParams[6] = oSRS.GetProjParm(SRS_PP_FALSE_EASTING); >> sPro.proParams[7] = oSRS.GetProjParm(SRS_PP_FALSE_NORTHING); >> } >> >> also I try this code >> OGRSpatialReference pSpaRef; >> const char *pszWkt = >> > "PROJCS[\"World_Times\",GEOGCS[\"GCS_WGS_1984\",DATUM[\"D_WGS_1984\",SPHEROID[\"WGS_1984\",6378137.0,298.257223563]],PRIMEM[\"Greenwich\",0.0],UNIT[\"Degree\",0.0174532925199433]],PROJECTION[\"Times\"],PARAMETER[\"Central_Meridian\",0.0],UNIT[\"Meter\",1.0]]"; >> pSpaRef.importFromWkt((char **)&pszWkt); >> char *pszPrtWKT = NULL; >> pSpaRef.exportToPrettyWkt(&pszPrtWKT ); >> CPLFree(pszPrtWKT ); >> >> And OGRSpatialReference eat this WKT. > > Ah ok, well it is just that it is valid WKT. But we cannot really tell that > GDAL > fully supports it currently. For example the Validate() method of > OGRSpatialReference would return FALSE since it doesn't know the Times > projection method, and which projection parameters are valid with it. And we > don't have a OGRSpatialReference.SetTimes() method. And not mentionning > importFromProj4/exportToProj4() (but we would need proj.4 support of it before > of course) > >> >> Best regards, >> Dmitry >> >> 25.03.2014 12:35, Even Rouault пОÑеÑ: >>> Dmitriy, >>> >>> where did you find reference to the "times" projection in OGR ? I can't >> find it. >>> >>> Even >>> >> >> > > _______________________________________________ gdal-dev mailing list [email protected] http://lists.osgeo.org/mailman/listinfo/gdal-dev
