Loading individual chunks by loading and unloading them for each use allows for a significant drop in memory usage.
For instance, this is the memory profile from the main branch:
With an initial buffer allocation for the image, a subsequent ramp-up to load the entire terrain, and a final buffer allocation for the sub-canvas.
The new behavior skips the loading phase, and the initial buffer allocation:
Both those profiles were calculated on the same world of size ~ 6000x6000.
To accomodate such changes, the entire merging code has been revamped. From there, tiling and file caching will be straightforward to implement.
Loading individual chunks by loading and unloading them for each use allows for a significant drop in memory usage. For instance, this is the memory profile from the main branch:
With an initial buffer allocation for the image, a subsequent ramp-up to load the entire terrain, and a final buffer allocation for the sub-canvas.
The new behavior skips the loading phase, and the initial buffer allocation:
Both those profiles were calculated on the same world of size ~ 6000x6000.
To accomodate such changes, the entire merging code has been revamped. From there, tiling and file caching will be straightforward to implement.