Skip to content

Fix geometry clip bounds for infinite rectangles#3291

Open
varphone wants to merge 1 commit intoiced-rs:masterfrom
varphone:fix/geometry-infinite-clip
Open

Fix geometry clip bounds for infinite rectangles#3291
varphone wants to merge 1 commit intoiced-rs:masterfrom
varphone:fix/geometry-infinite-clip

Conversation

@varphone
Copy link

This fixes the geometry example rendering issue on native Linux by preserving infinite clip bounds through the transformation and mesh preparation pipeline.

What changed:

  • Keep Rectangle::INFINITE unchanged when applying a transformation.
  • Skip snap/translation logic for infinite mesh clip bounds in iced_wgpu.

Why:

  • The geometry example uses an infinite clip region for its custom mesh.
  • Previously, the clip bounds could become NaN during transformation/snap calculation, which caused the mesh to be clipped away and the window to appear blank.

Validation:

  • cargo check -p geometry passes
  • cargo r -p geometry now produces finite clip bounds and renders through wgpu

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant