QuadTileSet quadTileSet = new QuadTileSet(((Element) rootElement.getChildren("ChildLayerSet").get(3)).getChild("QuadTileSet"), "");
assertEquals("Robben Island (0.5m)", quadTileSet.getName());
WWSource wwSource = new WWSource(quadTileSet);
// extent is not covered from QuadTileSet
WMTRenderJob renderJob1 = WMTRenderJob.createRenderJob(
new ReferencedEnvelope(1, 2, 48, 49, DefaultGeographicCRS.WGS84),
10000,
wwSource);
Map<String, Tile> tiles1 = wwSource.cutExtentIntoTiles(renderJob1,
50,
true, null, 1000);
assertEquals(true, tiles1.isEmpty());
// bounds of the QuadTileSet are inside the extent
WMTRenderJob renderJob2 = WMTRenderJob.createRenderJob(
new ReferencedEnvelope(18.34, 18.4, -33.85, -33.5, DefaultGeographicCRS.WGS84),
20000000,
wwSource);
Map<String, Tile> tiles2 = wwSource.cutExtentIntoTiles(renderJob2,
50,
true, null, 1000);
assertEquals(1, tiles2.size());
}