Repository navigation
Introduce environment-image and environment-intensity - #392
Conversation
a5694ff to
9caac99
Compare
|
Are non-reflective materials and surfaces affected by this attribute? "Reflection" suggests the attribute only affects a certain type of material, i.e. things that are partially or entirely reflective (mirrors, car paint, TVs that are turned off). Does this attribute affect matte paint materials? |
|
The equation is the same for all materials. |
|
The literal definition of "reflection" is:
If an opaque, dielectric (non-metallic) surface is lit at all, does it not follow that it is "reflecting" light (even if that reflection is not recognizable as a mirrored image of the environment due to diffusion)? |
|
FYI names have been changed from |
This change proposes the introduction of two new user-configurable attribute/properties:
environment-imageandenvironment-intensity. Highlights of the change include:@polymer/[email protected]to[email protected]environment-imageattribute to control the environment map without affecting the background image or colorenvironment-intensityattribute to control the intensity of whatever environment map happens to be usedExamples
environment-intensityoscillating0.0-6.0environment-imageonlybackground-imageonlyName rationale
Terms like environment map and IBL are commonly used to refer to the color information used to approximate the light emitted from physical surfaces in 3D scenes. However, these terms are not as meaningful to folks who do not have a graphics background. In the case of a mirror, puddle or other highly reflective surface, a word that very quickly comes to mind to describe the color information is "reflection." As skybox is the "background", so IBL is the "reflection."After a lot of good internal team discussion and some questionable science, the attribute names have been changed to
environment-imageandenvironment-intensityrespectively. One colleague, when faced with the choice between "reflection" and "environment," responded:Fundamentally speaking, reflectivity is a property of individual materials, and environment is a more technically accurate term.
Additional comments
This change is larger than I initially anticipated. I began to refactor environment map generation, and then quickly ran up against failing tests because I was not accommodating for #76 properly in some cases. So, rather than further spread the #76 disease, I decided to upgrade us to the latest
lit-elementso that we could benefit from the fix introduced a while back. This prompted additional changes that were difficult to tweeze apart from the original proposal due to the need to make tests pass.Fixes #122
Fixes #76