ericwa/ericw-tools

Translucency support

Opened this issue · 2 comments

This isn't an issue, but a feature request.

Would be cool if the tools could support some kind of translucency system (for stuff like plants, fabric, basically anything opaque but thin enough to still less light pass through).
The code is basically already there I feel with "alpha" which already does this, would just need a separate key that does the same thing but just not apply the transparency.

Some bonus features:

  • a toggle to tint the lighting with the texture ("alpha" already does this, but you don't always want it);
  • a new color translucency key to manually control how the light going through will be tinted.

I know translucency is kind of a misnomer for this, but it's how it's most often called, not sure if there's a better name, light transmission maybe?

4LT commented

Yes, "Transmission" is the term for what you're describing in computer graphics literature. There is already specular transmission in the tools, I think, via texture projection. I believe what you're describing would be diffuse transmission, where light penetrating a surface would scatter on the opposite side, as well as lighting the back face.

Basically what's described here w/ the BTDF: https://en.wikipedia.org/wiki/Bidirectional_scattering_distribution_function

This was discussed in the Discord, and I think it might already exist as _light_alpha or something. Need to double-check.