Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Improve shader definition for mod2x decals #188

Open
BenLubar opened this issue Aug 5, 2024 · 0 comments
Open

Improve shader definition for mod2x decals #188

BenLubar opened this issue Aug 5, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@BenLubar
Copy link

BenLubar commented Aug 5, 2024

Based on REDxEYE/SourceIO#287:

Currently, mod2x decals get materials that don't do anything special:

image

Which results in this in the render:
image

The proposed new material shader node graph for mod2x decals is this:

image

That is:

  • Change the texture color space to "non-color" to preserve 50% gray as 50% gray.
  • Add the color to itself (double it) so 50% gray becomes flat white.
  • Use the Transparent BSDF.

This results in a much nicer looking blood stain without a gray rectangle around it:
image

@BenLubar BenLubar added the bug Something isn't working label Aug 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant