ThinGridData: avoid clones
This commit is contained in:
@@ -148,7 +148,7 @@ impl Model {
|
||||
}
|
||||
|
||||
fn save_image_data(&mut self) {
|
||||
let grids = ThinGridData::new_from_grid_vec(self.population_grids.clone());
|
||||
let grids = ThinGridData::new_from_grid_vec(&self.population_grids);
|
||||
let img_data = ImgData::new(grids, self.palette);
|
||||
self.img_data_vec.push((self.iteration + 1, img_data));
|
||||
let size: usize = std::mem::size_of_val(&self.img_data_vec);
|
||||
|
||||
Reference in New Issue
Block a user