📄 mitab_bounds.cpp
字号:
/**********************************************************************
* $Id: mitab_bounds.cpp,v 1.8 2008/01/29 20:53:10 dmorissette Exp $
*
* Name: mitab_bounds.cpp
* Project: MapInfo TAB Read/Write library
* Language: C++
* Purpose: Implementation of bound lookup tables for known projections.
* Author: Daniel Morissette, dmorissette@dmsolutions.ca
*
**********************************************************************
* Copyright (c) 2001, Daniel Morissette
*
* 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.
**********************************************************************
*
* $Log: mitab_bounds.cpp,v $
* Revision 1.8 2008/01/29 20:53:10 dmorissette
* Added bounds for PSAD56 (Patch from AJD sent for bug #1754)
*
* Revision 1.7 2005/09/29 18:31:28 dmorissette
* New bounds entry for Finnish KKJ and Swedish projections (AJD, bug 1155)
*
* Revision 1.6 2005/03/31 22:00:38 dmorissette
* Added bounds entry to match datum 1011 based on MapInfo's "Svenska
* rikssystemet, 2,5 gon väst (RT 90 7 parametrar)" (bug 997)
*
* Revision 1.5 2005/03/22 23:24:54 dmorissette
* Added support for datum id in .MAP header (bug 910)
*
* Revision 1.4 2004/06/30 20:29:03 dmorissette
* Fixed refs to old address danmo@videotron.ca
*
* Revision 1.3 2001/02/14 21:17:33 daniel
* Check only if first char is "#" for comments in MITABLoadCoordSysTable()
*
* Revision 1.2 2001/01/23 22:06:50 daniel
* Added MITABCoordSysTableLoaded()
*
* Revision 1.1 2001/01/23 21:23:41 daniel
* Added projection bounds lookup table, called from TABFile::SetProjInfo()
*
**********************************************************************/
#include "mitab.h"
/*-----------------------------------------------------------------
* List of known coordsys bounds.
* 0xff in nEllipsoidId or nUnitsId fields means any value can match.
*
* __TODO__: nDatumId is always set to zero in this list, we'd have to
* reprocess the whole list to properly set all datum ids and accelerate
* bounds lookups
*----------------------------------------------------------------*/
static MapInfoBoundsInfo **gpapsExtBoundsList = NULL;
static MapInfoBoundsInfo gasBoundsList[] = {
{{1, 0xff, 0xff, {0,0,0,0,0,0}, 0,0,0,0, {0,0,0,0,0}}, -1000, -1000, 1000, 1000}, /* Lat/Lon */
{{2, 29, 0, {-85.5,13,0,0,0,0}, 0,0,0,0, {0,0,0,0,0}}, -18500.7190263237, -4067.43878447928, 30025.7571082958, 4067.43878447928},
{{2, 29, 0, {20,0,0,0,0,0}, 0,0,0,0, {0,0,0,0,0}}, -26284.8753911183, -3963.19059194305, 23518.0464025796, 3963.19059194305},
{{2, 7, 7, {0,30,0,0,0,0}, 0,-8,160,176, {0,0,0,0,0}}, -34706360.1398239, -7364918.36397399, 34706360.1398239, 7364918.36397399},
{{3, 0, 3, {-109.5,44.25,45,49,1968503.937,0}, 0,0,0,0, {0,0,0,0,0}}, -376322393.49652, -357755728.255206, 380259401.37052, 398826066.611833},
{{3, 0, 3, {-111.5,36.6666666667,37.2166666667,38.35,1640419.948,9842519.685}, 0,0,0,0, {0,0,0,0,0}}, -281416969.95067, -245782664.730374, 284697809.84667, 320332115.066966},
{{3, 0, 3, {-111.5,38.3333333333,39.0166666667,40.65,1640419.948,6561679.79}, 0,0,0,0, {0,0,0,0,0}}, -299820220.76226, -269235441.863424, 303101060.65826, 333685839.557096},
{{3, 0, 3, {-111.5,40.3333333333,40.7166666667,41.7833333333,1640419.948,3280839.895}, 0,0,0,0, {0,0,0,0,0}}, -313479418.366583, -287610480.882755, 316760258.262583, 342629195.746411},
{{3, 0, 3, {-120.5,41.6666666667,42.3333333333,44,4921259.843,0}, 0,0,0,0, {0,0,0,0,0}}, -329872743.533369, -311905915.324464, 339715263.219369, 357682091.428273},
{{3, 0, 3, {-120.5,43.6666666667,44.3333333333,46,8202099.738,0}, 0,0,0,0, {0,0,0,0,0}}, -348623368.682272, -335442185.295993, 365027568.158272, 378208751.544552},
{{3, 0, 3, {-81,31.8333333333,32.5,34.8333333333,2000000,0}, 0,0,0,0, {0,0,0,0,0}}, -248789436.724623, -218682485.302253, 252789436.724623, 282896388.146993},
{{3, 0, 3, {-84.3666666667,41.5,42.1,43.6666666667,13123359.58,0}, 0,0,0,0, {0,0,0,0,0}}, -318674512.717618, -308729738.1419, 344921231.877618, 354866006.453336},
{{3, 0, 3, {-84.3666666667,43.3166666667,44.1833333333,45.7,19685039.37,0}, 0,0,0,0, {0,0,0,0,0}}, -334588341.234808, -332680007.139814, 373958419.974808, 375866754.069803},
{{3, 0, 3, {-87,44.7833333333,45.4833333333,47.0833333333,26246719.16,0}, 0,0,0,0, {0,0,0,0,0}}, -343541891.912548, -349200540.720143, 396035330.232548, 390376681.424953},
{{3, 0, 7, {-100,39.8333333333,40,43,500000,0}, 0,0,0,0, {0,0,0,0,0}}, -96293653.747449, -89392122.913416, 97293653.747449, 104195184.581482},
{{3, 0, 7, {-100,43.8333333333,44.4166666667,45.6833333333,600000,0}, 0,0,0,0, {0,0,0,0,0}}, -107757768.605122, -101845373.546917, 108957768.605122, 114870163.663327},
{{3, 0, 7, {-100.3333333333,29.6666666667,30.1166666667,31.8833333333,700000,3000000}, 0,0,0,0, {0,0,0,0,0}}, -70389655.9882633, -57319094.8848422, 71789655.9882633, 84860217.0916844},
{{3, 0, 7, {-100.3333333333,42.3333333333,42.8333333333,44.4,600000,0}, 0,0,0,0, {0,0,0,0,0}}, -102916158.881298, -96669936.9429582, 104116158.881298, 110362380.819638},
{{3, 0, 7, {-100.5,45.6666666667,46.1833333333,47.4833333333,600000,0}, 0,0,0,0, {0,0,0,0,0}}, -114111552.091083, -108589212.496103, 115311552.091083, 120833891.686064},
{{3, 0, 7, {-100.5,47,47.4333333333,48.7333333333,600000,0}, 0,0,0,0, {0,0,0,0,0}}, -118782512.590452, -113525792.131232, 119982512.590452, 125239233.049672},
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -