Page MenuHome

Eevee: Transparent material black parts
Closed, ArchivedPublic

Description

System Information
Operating system: Ubuntu 18.04.2
Graphics card: AMD RX 580

Blender Version
Broken: 2.80.71, e78770039397, 2019-05-20

Short description of error
I have this mesh with some transparent parts, in Eevee with Alpha Hashed as Blend Mode i get these weird black parts in the distance.
Same result with Alpha Clip, for the Alpha Blend it gets all blown out.


Simplified blend

Details

Type
Bug

Event Timeline

Marco (nacioss) renamed this task from Transparent material black parts to Eevee: Transparent material black parts.May 22 2019, 12:16 AM

same problem here, black spots at the long distance


Simplified Version, 90% of Nodes Removed

Clément Foucault (fclem) closed this task as Archived.May 23 2019, 4:57 PM

TL,DR: Well this is a float precision issue. the view range is really high and using multiple mesh layers close to each other makes the rendering bogus.

Workarounds:

  • use other blend modes.
  • use more reasonable clipping values.
  • Make the planes much more distant from each others.

Technical explanation:

  • The alpha hash blend modes operate in 2 passes. One pass that only write depth when the alpha is above the noise threshold, and one pass to write the color.
  • The mix node does a premultiplication of the radiance of each incomming BRDF and unpremult before the output. This makes the totally transparent regions totally black (in radiance).
  • The issue when there is depth fighting is that the 2nd layer is writting this black radiance on top of the previous layer because the depth test is still true (because both layers shares the same depth).

This could be solved by bypassing the depth prepass for theses objects but then we loose the benefits of the alpha hashed technique. I plan to introduce such feature (exclude from depth prepass) but for 2.80 it is not possible.

Thank you a lot for all the info Clement ;) you are doing an amazing job.