lambert
Shading that incorporates ambient and diffuse properties only.
Declaration
static let lambert: SCNMaterial.LightingModelDiscussion
This shading model is based on Lambert’s Law of diffuse reflectance, calculating the color of a point on a surface with the following formula:
color = ambient * al + diffuse * max(0, dot(N, L))The ambient and diffuse terms refer to the material’s properties. The other terms are as follows:
alThe sum of all ambient lights in the scene (a color).
NThe surface normal vector at the point being shaded, as supplied by the geometry’s vertex data, interpolated between vertices, and possibly modified by the material’s normal property.
LThe (normalized) vector from the point being shaded to the light source.