(&mut self, dimensions: Vec2<usize>)
| 68 | } |
| 69 | |
| 70 | pub fn resize(&mut self, dimensions: Vec2<usize>) { |
| 71 | self.accumulated_buffer |
| 72 | .resize(dimensions.product(), Vec3::zero()); |
| 73 | self.out_buffer.resize(dimensions.product(), Vec3::zero()); |
| 74 | self.viewport.bounds = dimensions; |
| 75 | } |
| 76 | |
| 77 | /// Swaps out a material at a specific index. |
| 78 | pub fn update_material(&mut self, idx: usize, new: MaterialKind) { |