Skip to content

fix: Incorrect bounding box for sprites with non-default Center#3228

Open
w0wca7a wants to merge 1 commit into
stride3d:masterfrom
w0wca7a:fix/transp_sprite
Open

fix: Incorrect bounding box for sprites with non-default Center#3228
w0wca7a wants to merge 1 commit into
stride3d:masterfrom
w0wca7a:fix/transp_sprite

Conversation

@w0wca7a

@w0wca7a w0wca7a commented Jun 20, 2026

Copy link
Copy Markdown
Contributor

PR Details

When a sprite's pivot is offset from the geometric center of the texture (e.g. anchoring the sprite to its bottom edge so it sits on the ground), the sprite is rendered visually shifted relative to the entity's position — but the bounding box used for frustum culling stays centered on the entity itself.

Related Issue

fixes: #3227

Types of changes

  • Docs change / refactoring / dependency upgrade
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist

  • My change requires a change to the documentation.
  • I have added tests to cover my changes.
  • All new and existing tests passed.
  • I have built and run the editor to try this change out.

Fix incorrect bounding box for sprites with non-default Center
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.

Sprite disappears with non standard Center

1 participant