Skip to content

Commit

Permalink
Avoid configure on empty surface
Browse files Browse the repository at this point in the history
  • Loading branch information
fornwall committed Jun 15, 2023
1 parent fa17d0b commit 01d8c38
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -457,7 +457,6 @@ impl Computer {
impl<'a> State<'a> {
async fn new(window: Window) -> State<'a> {
let size = window.inner_size();
log::info!("size = {:?}", size);
let instance = wgpu::Instance::new(wgpu::InstanceDescriptor::default());
let surface = unsafe { instance.create_surface(&window).unwrap() };

Expand Down Expand Up @@ -516,8 +515,6 @@ impl<'a> State<'a> {
view_formats: vec![],
};

surface.configure(&device, &config);

let cells_width = 256;

let size_array = [cells_width as u32, cells_width as u32];
Expand Down

0 comments on commit 01d8c38

Please sign in to comment.