Renderer · interface
ReflectiveSurfaceOptions
What a ReflectiveSurface is made with: its box, which way the surfaces inside it face, and how
much and how far they reflect. Every number but the box has a default; see each field.
Explained in Hello world.
interface ReflectiveSurfaceOptions extends DecalBoximport type { ReflectiveSurfaceOptions } from '@driftengine/core';Properties
| Name | Type | Description |
|---|---|---|
strengthreadonlyoptional | number | How much of what the ray finds lands on the surface, 0 to 1: one share over the box, or with
fresnel the surface's reflectance head-on. |
fresnelreadonlyoptional | boolean | Whether strength is the surface's reflectance head-on, F0, rather than one share over the
box. Each pixel then returns F0 · A + B of what its ray finds, the split-sum environment BRDF
at its own view and roughness — Karis's fit, the one the lit stage reflects its environment
by — so a floor returns more toward the horizon than underfoot, and the share follows the
camera as a physically based renderer weighs its reflections. False by default, the one
share as before.MoreWhat it gives up: the pass has no material buffer, so the roughness and F0 are the box's, not each pixel's, and nothing occludes the reflection where the lit stage's ambient occlusion would. A floor of one material is what it is for. |
roughnessreadonlyoptional | number | The surface's roughness, 0 to 1, that fresnel weighs by. 0, a polished surface, if absent. |
reachMreadonlyoptional | number | How far a ray may travel, world metres. |
thicknessMreadonlyoptional | number | How deep a depth sample is treated as being. See ScreenSpaceMarch.thicknessM. |
stepsreadonlyoptional | number | How many samples along a ray. |
facingCosreadonlyoptional | number | How far from facing the box's own axis a surface may be turned and still reflect. |
tintreadonlyoptional | ReadonlyVec3 | What the reflection is multiplied by, for a tinted mirror. |