Discrepancy in treatment of alpha in texture?

Started by Anindo Ghosh, April 15, 2022, 04:17:58 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Anindo Ghosh

Hi,

An issue with rendering material with an alpha, in proximity to a clear material:

To illustrate the problem, I have this opaque plastic rounded cylinder single-color object, then a clear Glass (Solid) sheet, then a "sticker" rectangle textured with "Diffuse" containing a bird illustration used for both diffusion and alpha. The Opacity Map Mode is set to Alpha, and I have verified that the portion outside the bird that should be transparent, is a proper flat empty area with no smattering of non-zero pixels.

Yet, there is a faint outline of the shape of the sticker rectangle, affecting the light incident through the glass sheet into the opaque plastic underneath. The close-up render shows this behavior even more clearly.

I have tried replacing the Diffuse with everything from Paint to Glass to Glass Solid, and pretty much every other material. I have also tried moving the "sticker" visual to a label rather than directly applying it as a texture map on the material. The problem persists.

I desperately and urgently need some kind of solution to this, as my current project requires accurate rendering of such illustrations printed onto transparent and tinted materials, with an opaque material underneath. The color shift (lighter color in the "sticker" area) caused by the mishandling of the alpha is ruining the intended renders. The actual printed sticker does not have any rectangular clear portion, just the printing in the exact irregular outline shape of each illustration.

The KSP package is attached, if someone would be nice enough to play around with it to find me a solution.

Thanks!

TGS808

I tried several variations to overcome your issue. The only one I came up with that works is to change your Glass Solid material to a Glass Basic (and turn refractive on). The end result looks nearly identical to your original setup (though without the soft drop shadow behind the bird) but the problem outline is no longer visible. Also, it clears up a lot faster than the solid so you shouldn't need 10,000 samples.

If you must use the solid glass, you could try applying the bird label directly on to the solid glass material instead of putting it on a separate piece of geometry. Doing that also gets rid of the unwanted outline around the bird while not really changing the overall look of your setup.

Anindo Ghosh

@TGS8078: Thanks for this.

I am stuck with the solid glass - in the actual product shots, I will need to use Dielectric, possibly. The soft shadow is essential to the desired look.

For most of the work, your suggestion of using the image as a label is excellent, and I'll switch to it. For some specific situations such as where we need to animate the image position, I won't be able to use the label option, so I will continue to explore other avenues. Other than that, I'll go with solid glass and your solution.

The 10k samples are for a different reason - For the actual product being rendered, there is also a stack of dielectrics and multilayer optics, and increasing the noise reduction blend kills details in those parts of the image.

Thank you!

TGS808

Quote from: Anindo Ghosh on April 16, 2022, 12:54:10 PM
@TGS808: Thanks for this.
The soft shadow is essential to the desired look.

I figured that was the case. I just couldn't find another way to keep it. Glad I was able to help a little. Hope you get it all worked out.

theAVator

Why the need for the extra square glass sheet? Why not just apply your sticker to the back of the sculped glass piece?

Anindo Ghosh

@theAVator:
QuoteWhy the need for the extra square glass sheet? Why not just apply your sticker to the back of the sculped glass piece?

Around 10 different colors of the glass piece, and a growing number of different artworks for the sticker: These are set up as Material Ways, such that every combination of glass piece color and sticker image (as well as the underlying cylindrical enclosure with its own half dozen colors) can be bulk rendered. The only way I know to do that is to put the stickers on a multimaterial, and the glass colors as another multimaterial.

I can't seem to find a way to implement "Material Ways" bulk renders with a hierarchy of multimaterial and "multi-label" in Keyshot 10.2. If you know of such a way, that would solve a lot of problems for me.

Thanks.