Example #1
0
        private static void RegisterGdal()
        {
            if (!gdalInitialized)
            {
                Gdal.AllRegister(); //register gdal drivers

                var maxGdalCacheSize = Gdal.GetCacheMax();
                log.DebugFormat("Adding max GDAL cache size to GC memory pressure: {0}", maxGdalCacheSize);
                GC.AddMemoryPressure(maxGdalCacheSize);
                gdalInitialized = true;
            }
        }