Hello,
I'm encoutering a OutOfMemory exception when calling Map.DrawStaticLayers(bmp, GeographyUnit.Meter) for specifics areas.
Actually, my program generates pictures for the cache system, the bitmaps objects are correctly disposed, and the program never exceeds 120 Mb in Memory, but a OutOfMemoryException is thrown. The exception comes always for the same part of the map.
Here is the call stack :
bei ThinkGeo.MapSuite.Core.Layer.Draw(GeoCanvas canvas, Collection`1 labelsInAllLayers)
bei ThinkGeo.MapSuite.Core.MapEngine.x2a77eb6032362d14(Layer xa1d467ddfe47b178, Object x65e9a9c6c5e41d97)
bei ThinkGeo.MapSuite.Core.MapEngine.x68ddaa28fe467d0a(IEnumerable`1 xbc8a920bd17eefdf, Bitmap xe10299f210688dae, GeographyUnit x23bf990a35721448, Boolean xa872403da055b02a)
bei ThinkGeo.MapSuite.Core.MapEngine.DrawStaticLayers(Bitmap gdiPlusBitmap, GeographyUnit mapUnit)
bei GisCacheGenerationTool.Window1.GenerateTileSquare(Int32 level, Int32 number, Int32 x, Int32 y, Size packSquareSize, Size boundingBoxSize, Int32 scaleId) in C:\projects\Kuba50\Implementation\Components\Src\GisCacheGenerationTool\GisCacheGenerationTool\Window1.xaml.cs:Zeile 310.
Here are some watchs from the used envronnement :
Map.StaticLayers (all layers are open)
Count = 25
[0]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[1]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[2]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[3]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[4]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[5]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[6]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[7]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[8]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[9]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[10]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[11]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[12]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[13]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[14]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[15]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[16]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[17]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[18]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[19]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[20]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[21]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[22]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[23]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
[24]: {ThinkGeo.MapSuite.Core.GeoTiffRasterLayer}
Map.CurrentExtent
{829995.080935478,302615.353243947,859293.954696049,273316.479483257}
base {ThinkGeo.MapSuite.Core.AreaBaseShape}: {829995.080935478,302615.353243947,859293.954696049,273316.479483257}
Height: 29298.873760690098
LowerLeftPoint: {829995.080935478,273316.479483257,0}
LowerRightPoint: {859293.954696049,273316.479483257,0}
UpperLeftPoint: {829995.080935478,302615.353243947,0}
UpperRightPoint: {859293.954696049,302615.353243947,0}
Width: 29298.873760570888
Did I miss something ?
Thanks,
Guillaume