Fix physical_bounds shadowing in wgpu render
This commit is contained in:
parent
7526d73ad3
commit
7c54bdef10
1 changed files with 6 additions and 3 deletions
|
|
@ -280,13 +280,16 @@ impl Renderer {
|
||||||
let scale = Transformation::scale(scale_factor);
|
let scale = Transformation::scale(scale_factor);
|
||||||
|
|
||||||
for layer in self.layers.iter() {
|
for layer in self.layers.iter() {
|
||||||
let Some(scissor_rect) = physical_bounds
|
let Some(physical_bounds) =
|
||||||
.intersection(&(layer.bounds * scale_factor))
|
physical_bounds.intersection(&(layer.bounds * scale_factor))
|
||||||
.and_then(Rectangle::snap)
|
|
||||||
else {
|
else {
|
||||||
continue;
|
continue;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
let Some(scissor_rect) = physical_bounds.snap() else {
|
||||||
|
continue;
|
||||||
|
};
|
||||||
|
|
||||||
if !layer.quads.is_empty() {
|
if !layer.quads.is_empty() {
|
||||||
engine.quad_pipeline.render(
|
engine.quad_pipeline.render(
|
||||||
quad_layer,
|
quad_layer,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue