Revert "minedmap: store region list in BTreeSet"

This reverts commit b53d34da3d.

With the change of the mipmapper data structure, we need a conversion
step anyways, so we can keep using the Vec before mipmapping.
This commit is contained in:
Matthias Schiffer 2023-07-02 22:19:35 +02:00
parent b63a18ad6f
commit f9fc9efe8d
Signed by: neocturne
GPG key ID: 16EF3F64CB201D9C
4 changed files with 10 additions and 12 deletions

View file

@ -1,5 +1,3 @@
use std::collections::BTreeSet;
use anyhow::{Context, Result};
use minedmap::{io::fs, types::*};
@ -100,11 +98,11 @@ impl<'a> TileMipmapper<'a> {
})
}
pub fn run(self, tiles: BTreeSet<TileCoords>) -> Result<Vec<TileCoordMap>> {
pub fn run(self, tiles: &[TileCoords]) -> Result<Vec<TileCoordMap>> {
let mut tile_stack = {
let mut tile_map = TileCoordMap::default();
for TileCoords { x, z } in tiles {
for &TileCoords { x, z } in tiles {
tile_map.0.entry(z).or_default().insert(x);
}