Skip to content

Commit

Permalink
Revert "Attempt to fix scissor_rect validation error"
Browse files Browse the repository at this point in the history
This reverts commit 656dc35.
  • Loading branch information
hecrj committed Jun 9, 2021
1 parent 5224cc7 commit 56f673d
Showing 1 changed file with 1 addition and 10 deletions.
11 changes: 1 addition & 10 deletions wgpu/src/backend.rs
Original file line number Diff line number Diff line change
Expand Up @@ -110,16 +110,7 @@ impl Backend {
target_width: u32,
target_height: u32,
) {
let target_bounds = iced_graphics::Rectangle::with_size(
iced_graphics::Size::new(target_width as f32, target_height as f32),
);
let mut bounds_float = layer.bounds * scale_factor;
bounds_float.width =
bounds_float.width.min(target_width as f32 - bounds_float.x);
bounds_float.height = bounds_float
.height
.min(target_height as f32 - bounds_float.y);
let bounds = bounds_float.snap();
let bounds = (layer.bounds * scale_factor).snap();

if !layer.quads.is_empty() {
self.quad_pipeline.draw(
Expand Down

0 comments on commit 56f673d

Please sign in to comment.