ThinkGeo.com    |     Documentation    |     Premium Support

White lines between tiles




Hi,



Our map has the following 10 zoom levels:


            zoomScales.Add(24000000.0);
            zoomScales.Add(8000000.0);
            zoomScales.Add(3000000.0);
            zoomScales.Add(1000000.0);
            zoomScales.Add(500000.0);
            zoomScales.Add(250000.0);
            zoomScales.Add(125000.0);
            zoomScales.Add(64000.0);
            zoomScales.Add(32000.0);
            zoomScales.Add(16000.0);



I’ve generated tiles for the
first seven zooms and the map control uses them, but in same cases the map shows
white lines between tiles (please review the attached screenshot). If I turn
off tile using, the white lines are not shown.


 Do you have any idea what
could cause this?


 Another may be related issue
is that the tile folder for large scales (8-10) have names with a lot of
decimals:


15999.9999999985 for 16000
scale, 32000.0000000012 for 32000 scale, 64000.0000000024 for 64000 scale.


 So far these folder names do not affect
anything. I just thought may be it has also something to do with the tiles
position calculation and white lines between tiles.


 Do you know how to fix this?



Thank you for your help,

Gene








Hi Gene, 
  
 Is this issue about the RasterLayer. If so, please try to reference the version 9.0.181.0 or later which includes this fix. If not, could you please tell us what the layer is used in the application? 
  
 Thanks, 
 Peter

Hi Peter, 



Thank you for your reply. 



This build is not available yet.  



This could be a raster layer issue.  



Should this build fix the tiles display issue or tile folders name issue or both? 



Do I need to recreate tiles?



Thanks, 

Gene

Hi Gene, 
  
 I’m unable to reproduce the issue about the folders name. How did you create the tiles? I created the tiles by the tools which can be download from our wiki wiki.thinkgeo.com/wiki/map_suite_services_edition_all_samples#tile_cache_generator. Could you please attach the code or demo here if something is misunderstood? 
  
 Thanks, 
 Peter

Hi Peter, 



I use a Tile Generator tool which I’ve created based on the ThinkGeo sample. I’ve updated the zoom scale set, also the layers source is from our customized OsmWorldMapKitLayer class with three Geotiff layers. ThinkGeo WPF map control sometime displays maps with white lines between tiles. 



The ThinkGeo WPF map control creates folders with decimal numbers dynamically for the large scale zooms (8 - 10). These folders are not created using the tile generator. 



I’ve downloaded the build v.9.0.181.0 and changed references in my projects today, but I still see white lines between tiles and this is a critical issue. 



What issues should solve the build v.9.0.181.0? 

Do I need to recreate tiles with the new build? 



Thanks, Gene

Hi Gene,



Sorry for that I went the wrong direction about this issue. The v 9.0.181.0 or later fixed the issue about the “White line between tiles” of MrSidRasterLayer not about the GeoTiffRasterLayer. But I was still unable to reproduce the two issues (folder name contains decimals and the white line between tiles). Here as the following are a video of our test result and the sample, please check them out. If I misunderstood something please modify the sample to reproduce the issue and post it back to me.



Please make sure that if the white lines are drawn in the original tiles which are generated by the tools.



Screenshot: screencast.com/t/AMByDVFvg 



Thanks,

Peter

GeoTiffCustomZoomLevelSet.zip (746 KB)



Hi Peter,



I don’t think this is a raster layer issue. I think this is a map control tiles placement issue.



The attached picture has two screenshots of the same map/extent/scale using tiles and without using tiles in Baja California, Mexico (Zoom Level 4, Scale: 1,000,000).



The white lines between tiles are only shown in the “use tiles” mode (Overlay.TileCache is set). So far, I can only see the white lines on Zoom Level 4, Scale: 1,000,000 and not everywhere.



Can you reproduce this scenario?



Thanks,

Gene

Hi Gene, 
  
 Sorry that I was unable to reproduce this issue, could you please attach a sample here? A piece of data would be better. 
  
 Thanks, 
 Peter

Hi Gene,

I did some tests and was still unable to recreate this issue. There are some things need to make confirmation from you.

  1. Which version do you reference in your application(9.0.281.0)? The screenshot you appended here before, on the left side it shows the result uses the TileCahce and the other side shows the result doesn’t use the TileCache, all right? If so, I guess maybe the tiles which generated by the tools are incorrect. In the case, you need to recreate the tiles by referencing the DLLs which the application references.

  2. Do you use projection in your application?

  3. What kind of layers are used in your application?

Thanks,
Peter

Hi Peter,

1. Which version do you reference in your application(9.0.281.0)?

We use the version 9.0.150.0 in our application release and I also tested v. 9.0.181.0.

2. The screenshot you appended here before, on the left side it shows the result uses the TileCahce and the other side shows the result doesn’t use the TileCache, all right? If so, I guess maybe the tiles which generated by the tools are incorrect. In the case, you need to recreate the tiles by referencing the DLLs which the application references.

I’ve retested this issues today:
• White line locations are not consistent. They depend on the computer display resolution and the map zoom and extent. Sometime I cannot reproduce them on the same computer/zoom/extent if I restart the application.
• Map could have white lines between tiles even if tiles are dynamically generated by the same application. So this is not a Tiles Generator tool issue.

Today I’ve found white lines around Hawaii on zoom levels 7 and 8. Zoom 7 has pre-generated tiles, but Zoom 8 does not. I’ve deleted the Zoom 8 tile folder and was able to reproduce the issue after tiles were created by application. Please review the attach image.

3*. Do you use projection in your application?*

Yes, our map uses GeographyUnit.Meter and SQLite features are in the Mercator projection.
I think this bug could be specific to our Map Control scale set and to the TileType.SingleTile mode.
This is our Map Control scale set:
zoomScales.Add(24000000.0);
zoomScales.Add(8000000.0);
zoomScales.Add(3000000.0);
zoomScales.Add(1000000.0);
zoomScales.Add(500000.0);
zoomScales.Add(250000.0);
zoomScales.Add(125000.0);
zoomScales.Add(64000.0);
zoomScales.Add(32000.0);
zoomScales.Add(16000.0);
I’m not sure if it is related to this issue but, in this configuration, the application creates the following folders name for zoom levels 8 to 10:
64000.0000000011 for scale 64000 (zoom level 8),
31999.9999999986 for scale 32000 (zoom level 9),
15999.9999999993 for scale 16000 (zoom level 10)
These folder names have exact scale value in the TileType.MultipleTile mode.

I hope this information helps. Please let me know if you need more details.

Thanks,
Gene

Hi Gene,

Thanks for the further information, it helps so much. I’ve recreated your issue by the following code:

wpfMap1.MapUnit = GeographyUnit.Meter;
wpfMap1.ZoomLevelSet = GetCustomZoomLevelSet();
OsmWorldMapKitLayer worldLayer = new OsmWorldMapKitLayer(connectionString, OsmWorldMapKitDatabaseType.Sqlite);

LayerOverlay staticOverlay = new LayerOverlay();
GeoTiffRasterLayer tiffRasterLayer = new GeoTiffRasterLayer(path);
staticOverlay.Layers.Add("TiffRasterLayer", tiffRasterLayer);

staticOverlay.Layers.Add("WorldLayer", worldLayer);
wpfMap1.Overlays.Add(staticOverlay);

Please set the DrawingQuality property of GeoTiffRasterLayer as below(I do test with version 9.0.181.0 and it works well):

GeoTiffRasterLayer tiffRasterLayer = new GeoTiffRasterLayer(“path”) { DrawingQuality = staticOverlay.DrawingQuality };

The screenshot shows the differences.

Please remember to clear the TileCache.

Any questions please let me know.

Thanks,
Peter

Hi Peter,

I’ve tested your solution in our application with ThinkGeo WPF Map Control v. 9.0.150.0 and unfortunately it does not work.
Our map only uses Geo Tiff layers on zoom levels 1 to 4. I’ve also tried to set DrawingQuality = layerOverlay.DrawingQuality for each OsmWorldMapKitLayer but it did not help. I’ve cleaned tiles for Zoom 7 and 8 and I still see white lines between tiles on these zooms.

Do you think it could work in the version 9.0.181.0?

Thanks,
Gene

Hi Gene,

I am so sorry to hear it does not work with you. I tested my sample with 9.0.181.0 and 9.0.153.0(I didn’t get the 9.0.150.0, so I took the closer one of it) and all of them worked well. I doubt that whether the issue I recreated is the same as you met. I want to confirm somethings from you.

  1. Is the code I appended before familiar with yours?
  2. Does the TiffRasterLayer apply projection? The code maybe like:
    tiffRasterLayer.ImageSource.Projection = proj;
  3. What’s the resolution on your side?

In order to find out the issue you met, could you please provide us a sample with the tiff data?

Thanks,
Peter

Hi Peter,

1. Is the code I appended before familiar with yours?

Yes, my code is similar to your.

2. Does the TiffRasterLayer apply projection? The code maybe like:
tiffRasterLayer.ImageSource.Projection = proj;

The TiffRasterLayer image source is already projected. Today I’ve updated the code to set the ImageSource Projection but it does not help.

I still don’t understand why you are focused on the TiffRasterLayer settings if the map does not use tiff layers on zooms with white lines between tiles and white lines are not shown when tiles do not exist for the same extent/zoom.

3. What’s the resolution on your side?

This issue can be reproduced on different computers with different resolutions. My computer has default/recommended 1280x1024 resolution.

It will be a difficult task to provide you with a code sample, but our application is installed on one of ThinkGeo computers.

We can arrange a meeting to connect to my computer and review and debug my code remotely.

Thanks,
Gene

Hi Gene,

I can’t recreate this issue any more after setting the DrawingQuality property as I mentioned before.

Here attached is the sample. If something different with yours, please change it and send it back. Could you please tell me whose computer your application installed on? Thus I can communicate with he on this issue.

WhiteLinesBetweenTiles.zip (2.8 MB)

Thanks,
Peter

Hi Peter,

As I’ve mentioned in a previous post, I think this bug could be specific to our Map Control scale set and to the TileType.SingleTile mode.

Your code uses the default MultipleTile mode. Today I’ve tested my code in the MultipleTile mode and I could not reproduce the white line issue. Please try TileType.SingleTile to reproduce the issue.

Also I’ve mentioned that the tile folder names have exact scale value in the TileType.MultipleTile mode and have 10 decimal numbers like 31999.9999999986 for scale 32000 (zoom level 9) in the SingleTile mode.

Thanks,
Gene

Hi Gene,

Sorry for the misunderstood here before. These issues(White lines and the folder names) have been fixed and will be available in the version 9.0.308.0 or later.

Any questions please let me know.

NOTE: Please remember to set the DrawingQuality property of TiffRasterLayer as mentioned before.

Thanks,
Peter

Thank you Peter,

I’ll test the v 9.0.308.0 when it is available.

Does it mean you have been able to reproduce the issue or it was a known issue?

Thanks,
Gene

Hi Gene,

Yes, I had recreated the issue with SingleTile mode. Please get the version 9.0.308.0 and have a try again.

Sorry for any inconvenience.

Thanks,
Peter

Hi Gene,

The Development version 9.0.308.0 has been available, please get it from Product Center and have a try again.

NOTE: Please remember to clear the tile caches.

Thanks,
Peter