Repacking textures with bleed ring.#85
Merged
HeDo88TH merged 2 commits intoOpenDroneMap:masterfrom Oct 12, 2025
Merged
Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR implements texture bleeding/padding functionality to prevent rendering "cracks" that occur when zooming out from repacked textures. The implementation adds a 2-pixel bleed ring around each texture chart during the repacking process.
- Adds a 2px bleed ring around textures during repacking to prevent visual artifacts
- Refactors UV coordinate calculations and UDIM tile handling for better precision
- Introduces a new
BuildPaddedBlockmethod that creates padded texture charts by duplicating edge pixels
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Collaborator
|
Looks go to me 🚀 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds a 2px bleed ring around textures when repacking.
This removes "cracks" which can occur when zooming out.
Currently it is fixed to 2px, but it makes sense to increase it for larger textures with the formula similar to this:
width<2^10 => 0
width > 2^10 => 2^(log2(width)-10)
e.g:
512x512 => 0px
1024x1024 =>2px
2048x2048 => 4px
etc.
This is implementation of #4 and probabbly fixes #38