[mapguide-commits] r9507 - in sandbox/jng/tiling_v2: Common/MapGuideCommon/MapLayer Server/src/UnitTesting
svn_mapguide at osgeo.org
svn_mapguide at osgeo.org
Tue May 21 07:58:50 PDT 2019
Author: jng
Date: 2019-05-21 07:58:50 -0700 (Tue, 21 May 2019)
New Revision: 9507
Modified:
sandbox/jng/tiling_v2/Common/MapGuideCommon/MapLayer/Map.cpp
sandbox/jng/tiling_v2/Server/src/UnitTesting/TestTileService.cpp
sandbox/jng/tiling_v2/Server/src/UnitTesting/TestTileService.h
Log:
Revert r9504. I am reminded why we throw when trying to create a MgMap linked to a XYZ tileset. Although the scale list is legit, the GETTILE operation will still use XYZ tile access semantics instead of MapGuide tile access semantics. Basically the MgMap that is created is not usable in our viewer offerings (AJAX/Fusion) out of the box and the amount of work required to make it happen is just impractical.
Modified: sandbox/jng/tiling_v2/Common/MapGuideCommon/MapLayer/Map.cpp
===================================================================
--- sandbox/jng/tiling_v2/Common/MapGuideCommon/MapLayer/Map.cpp 2019-05-21 13:35:55 UTC (rev 9506)
+++ sandbox/jng/tiling_v2/Common/MapGuideCommon/MapLayer/Map.cpp 2019-05-21 14:58:50 UTC (rev 9507)
@@ -852,31 +852,6 @@
}
}
}
- else if (storeParams->GetTileProvider() == MG_TILE_PROVIDER_XYZ)
- {
- //This scale list is the same scale list that client-side authoring tools like Maestro
- //generate so that WGS84.PseudoMeractor tiled maps can line up with external XYZ layers
- scales.push_back(591657550.5);
- scales.push_back(295828775.3);
- scales.push_back(147914387.6);
- scales.push_back(73957193.82);
- scales.push_back(36978596.91);
- scales.push_back(18489298.45);
- scales.push_back(9244649.227);
- scales.push_back(4622324.614);
- scales.push_back(2311162.307);
- scales.push_back(1155581.153);
- scales.push_back(577790.5767);
- scales.push_back(288895.2884);
- scales.push_back(144447.6442);
- scales.push_back(72223.82209);
- scales.push_back(36111.91104);
- scales.push_back(18055.95552);
- scales.push_back(9027.977761);
- scales.push_back(4513.98888);
- scales.push_back(2256.99444);
- scales.push_back(1128.49722);
- }
else if (strict)
{
MgStringCollection args;
Modified: sandbox/jng/tiling_v2/Server/src/UnitTesting/TestTileService.cpp
===================================================================
--- sandbox/jng/tiling_v2/Server/src/UnitTesting/TestTileService.cpp 2019-05-21 13:35:55 UTC (rev 9506)
+++ sandbox/jng/tiling_v2/Server/src/UnitTesting/TestTileService.cpp 2019-05-21 14:58:50 UTC (rev 9507)
@@ -1900,19 +1900,6 @@
}
}
-void TestTileService::TestCase_MgMap_CreateFromXYZTileSet()
-{
- // make a runtime map
- Ptr<MgResourceIdentifier> mdfres = new MgResourceIdentifier(L"Library://UnitTests/TileSets/XYZ.TileSetDefinition");
- MgMap* map = new MgMap(m_siteConnection);
- map->Create(mdfres, mdfres->GetName());
-
- Ptr<MgCoordinateSystemFactory> csFactory = new MgCoordinateSystemFactory();
- STRING csWkt = csFactory->ConvertCoordinateSystemCodeToWkt(L"WGS84.PseudoMercator");
- CPPUNIT_ASSERT(csWkt == map->GetMapSRS());
- CPPUNIT_ASSERT(20 == map->GetFiniteDisplayScaleCount());
-}
-
////////////////////////////////////////////////////////////////
/// Helpers
////////////////////////////////////////////////////////////////
Modified: sandbox/jng/tiling_v2/Server/src/UnitTesting/TestTileService.h
===================================================================
--- sandbox/jng/tiling_v2/Server/src/UnitTesting/TestTileService.h 2019-05-21 13:35:55 UTC (rev 9506)
+++ sandbox/jng/tiling_v2/Server/src/UnitTesting/TestTileService.h 2019-05-21 14:58:50 UTC (rev 9507)
@@ -25,7 +25,6 @@
CPPUNIT_TEST_SUITE(TestTileService);
CPPUNIT_TEST(TestStart); // This must be the very first unit test
- CPPUNIT_TEST(TestCase_MgMap_CreateFromXYZTileSet);
CPPUNIT_TEST(TestCase_GetMetatileSingle);
CPPUNIT_TEST(TestCase_GetMetatileXYZSingle);
@@ -59,7 +58,6 @@
void TestEnd();
void TestCase_GetTileProviders();
- void TestCase_MgMap_CreateFromXYZTileSet();
void TestCase_MgMap_Inline();
void TestCase_MgMap_Linked();
void TestCase_MgMap_LinkedSameCS();
More information about the mapguide-commits
mailing list