-
Notifications
You must be signed in to change notification settings - Fork 18
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
Glossy-diffuse slab description as a gloss layer is possibly confusing #141
Comments
This type of approach seems reasonable to me. It seems like "diffuse reflection" can be caused by a variety of different underlying mechanisms (e.g., microfacets, volumetric scattering, spongy internal structure, etc.) and from an artist's perspective it doesn't seem that important which one is happening. The important thing seems to be that there's some dielectric substance that exhibits specular reflection from its outer surface and diffuse reflection from below that. The overall vdiffuse reflection has some user-specified color, even though the underlying scattering events that lead to the diffuse distribution of light might have different colors. At a high-level, I feel like it's fine for the "roughness" to define the overall shape of the diffuse lobe without enforcing some low-level physical structure, but I see the problem of making the specification rigorous and clear. If we're using Oren–Nayar for the BRDF but we don't want to say the roughness parameter represents a literal microfacet roughness, maybe we could consider describing the effect of the roughness phenomenologically instead, for example describing it as "retroreflection" instead of "roughness". |
Given the current models, I still think it makes the most physical sense to model "glossy-diffuse" as a dielectric layer on top of an Oren-Nayar (i.e. Lambertian microfacet) base. But agreed it's a good idea to think about it more from the point of view of the end-goal of the artist, who wants ultimately to dial in a particular observed base color and highlight/lobe shape. For artistic purposes we can require that the What we could say for example is simply that we define the physical base albedo to be the value which makes the directional albedo of the coated base (at normal incidence say), equal the specified Note This seems appropriate to do for the base, though for the coat I think it still makes sense to allow for the physical darkening to be applied (though possibly optionally), as that is a kind of secondary, realistic physical effect that may or may not be wanted artistically (e.g. to simulate varnishes, wetness, etc.). While the color of the base should be something that is directly specified without any additional darkening happening. Then if implementations (hypothetically) did completely physically correct darkening due to bounces in the glossy layer, the reflection should perfectly match the desired In practice of course people will need to use some kind of approximation to get a tractable BRDF. In my notes posted on Slack I derived a formula for this in the case of a smooth coat (here "gloss") and Lambertian base: (where We could also just point out that in practice, the standard albedo-scaling (reciprocal or non-reciprocal) can also be considered a semi-reasonable approximation of this. For example for a Lambertian base it reduces at normal incidence to albedo Or alternatively, a better approximation (if doing non-reciprocal albedo scaling) would be to demand i.e. set the base albedo to (where Warning An issue with this whole approach though is that, as noted in the pasted snippet above, it doesn't make sense to ask for a color component As the Fresnel reflection from the gloss will not allow this. So perhaps one could instead have the desired base color be expressed as a lerp factor between Then e.g. in albedo-scaling approximation, so we require Which is what we currently assume in the suggested albedo scaling approximation for glossy-diffuse in the spec (i.e. equation 30 here, since we say that So maybe this is a reasonable way to get consistency between the artistic requirements and the physical model, i.e. say:
In other words, a black This is totally consistent with the resulting behavior one currently gets using albedo-scaling approximation, and could be considered a natural generalization of that to a more physically correct light transport model of the glossy-diffuse layer model. |
Closing this issue, which is now addressed in #165. |
This PR adds a detailed discussion to the spec of the coat darkening effect (incorporating the ideas discussed in #136 and #141), with: - introduction of a new `coat_darkening` parameter (defaulting to 1, the physically correct case). - a physical definition of how this parameter operates to reduce the darkening (via boosting of the base albedo) - a suggested practical implementation of the darkening factor for the base lobe, taking into account the IOR of the coat, and also the roughness of the base (based on the derivations and discussions linked elsewhere). - A suggested implementation of the darkening of colored coats at grazing angles due to longer path length in the absorbing medium.
We currently write in the spec:
This is the model we want to use physically, i.e. the slab is like the infinitely dense limit of the subsurface.
But then we say:
The reason we opted to describe glossy-diffuse as
layer(diffuse, gloss)
is then at least it's clear what the base color/roughness mean (i.e. the color and roughness of the Oren-Nayar base).If you want to think of it instead as a dense subsurface inside dielectric, it's really not clear what base color/roughness should mean for the properties of the subsurface (e.g. there is no more Oren-Nayar model going on, so what is the roughness doing -- something like "rough volume", but that's not standard). Also if we did that with base color being the volume albedo say, technically the scattering would cause a color shift, requiring remapping (like the actual subsurface, but in some infinite density limit).
With the existing description saturation should occur for this layer too, due to the bounces within it. (And the coat would just add further saturation). That's not completely unrealistic, since even in the volumetric model some saturation will happen due to TIR and multiple scattering.
So I actually don't know what the best way to describe it is. Possibly the existing description is the best option given the currently available models. We might want to say though that we assume some remapping is done so that the supplied base color appearance is produced in some sense. How to define that so it is not incoherent I'm not sure though.
The text was updated successfully, but these errors were encountered: