Closed zhujianyang closed 3 years ago
I'd check that each tile source works individually first.
For multiple tile sources, if you want to overlay them you'll need two QuadImageLoaders. Set the baseDrawPriority to kMaplyImageLayerDrawPriorityDefault in the first. Set the baseDrawPriority to kMaplyImageLayerDrawPriorityDefault+1 in the second. This should interleave the image sources.
Oh and set drawPriorityPerLevel to 2 for both of them.
thanks ,it works,but the effect is not I wanted,is there something wrong with the setting? MaplyRemoteTileInfoNew *tileInfo = [[MaplyRemoteTileInfoNew alloc] initWithBaseURL:@"http://t0.tianditu.gov.cn/img_w/wmts?service=wmts&request=gettile&version=1.0.0&layer=img&format=tiles&tilematrixset=w&tk=eedb4905054fb3095d74ca98d7b7a584&tilecol={y}&tilerow={x}&tilematrix={z}" minZoom:1 maxZoom:5]; tileInfo.cacheDir = [NSString stringWithFormat:@"%@/daytexture-2017-09-26/", cacheDir];
tileInfo.cacheDir = thisCacheDir;
// Describes what the file covers and how deep
MaplySamplingParams *sampleParams = [[MaplySamplingParams alloc] init];
sampleParams.coordSys = [[MaplySphericalMercator alloc] initWebStandard];
sampleParams.coverPoles = true;
sampleParams.edgeMatching = true;
sampleParams.minZoom = tileInfo.minZoom;
sampleParams.maxZoom = tileInfo.maxZoom;
sampleParams.singleLevel = YES;
imageLoader = [[MaplyQuadImageLoader alloc] initWithParams:sampleParams tileInfo:tileInfo viewC:theViewC]; imageLoader.baseDrawPriority = kMaplyImageLayerDrawPriorityDefault;
due to the cache?or something?
or need censium?
hello,whirlyglobe team. version:2.6.5 when i use 2.6.5 to build app.I'm having some trouble。
WhirlyGlobeViewController globeViewC = nil; MaplyViewController mapViewC = nil; if ([theViewC isKindOfClass:[WhirlyGlobeViewController class]]) globeViewC = (WhirlyGlobeViewController )theViewC; else mapViewC = (MaplyViewController )theViewC;
MaplyRemoteTileInfoNew *tileInfo = [[MaplyRemoteTileInfoNew alloc] initWithBaseURL:@"http://t0.tianditu.gov.cn/img_w/wmts?service=wmts&request=gettile&version=1.0.0&layer=img&style=default&tilematrixset=w&format=tiles&tilematrix={z}&tilerow={x}&tilecol={y}&tk=21acecb607e8c575b1668c600606da16" minZoom:0 maxZoom:5];
tileInfo.cacheDir = thisCacheDir;
imageLoader.baseDrawPriority = kMaplyImageLayerDrawPriorityDefault;
if (globeViewC != nil) { globeViewC.height = 0.8; [globeViewC animateToPosition:MaplyCoordinateMakeWithDegrees(-122.4192,37.7793) time:1.0]; } else { mapViewC.height = 1.0; [mapViewC animateToPosition:MaplyCoordinateMakeWithDegrees(-122.4192,37.7793) time:1.0]; }
the first URL is Spherical Mercator projection,Image reproduction.the next URL is Mercator projection Image annotation i can not Get the desired effect is the URL wrong?