Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

[glass] Fix custom image padding to maintain aspect ratio #7648

Merged
merged 1 commit into from
Jan 7, 2025

Conversation

rmheuer
Copy link
Contributor

@rmheuer rmheuer commented Jan 6, 2025

My previous change from #7214 caused custom Field2d images to be slightly squished vertically, this fixes the padding so the image keeps the same aspect ratio.

Before:
Screenshot from 2025-01-06 17-55-40
After:
Screenshot from 2025-01-06 17-56-56

@rmheuer rmheuer requested a review from a team as a code owner January 6, 2025 23:59
@github-actions github-actions bot added the component: glass Glass app and backend label Jan 6, 2025
@PeterJohnson
Copy link
Member

Just a note that you can get the field boundary by loading the json file instead of the raw image.

@PeterJohnson PeterJohnson merged commit 8e459a4 into wpilibsuite:main Jan 7, 2025
45 checks passed
@rmheuer rmheuer deleted the field2d_aspect_ratio_fix branch January 7, 2025 13:36
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
component: glass Glass app and backend
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants