Skip to content
This repository has been archived by the owner on Jul 10, 2023. It is now read-only.

Float math in alpha calculation causes some punch-through textures to… #1235

Merged
merged 2 commits into from Aug 21, 2018

Conversation

flyinghead
Copy link
Contributor

… have alpha noise.

@skmp
Copy link
Owner

skmp commented Jul 23, 2018

@skmp
Copy link
Owner

skmp commented Jul 23, 2018

I think in general, we should be using 256 as 1.0 not 255

@flyinghead
Copy link
Contributor Author

flyinghead commented Jul 23, 2018

Isn't GL going to saturate to 1.0 for a value of 255 in an 8-bit channel? If that's the case then we should do the same.
I think the issue here is that we were using float math with >, which gives different results than integer math.

@AbandonedCart
Copy link
Contributor

The added changes can be added later. As it stands now, there are some serious issues with alpha.

@AbandonedCart AbandonedCart merged commit 62837f4 into master Aug 21, 2018
@flyinghead flyinghead deleted the fh/alpha-pt-rounding-fix branch August 21, 2018 06:29
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants