MCPcopy Create free account
hub / github.com/Rust-GPU/rust-cuda / resize

Method resize

examples/cuda/cpu/path_tracer/src/cpu/mod.rs:70–75  ·  view source on GitHub ↗
(&mut self, dimensions: Vec2<usize>)

Source from the content-addressed store, hash-verified

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) {

Callers 1

process_eventMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected