Renderer · interface
GiResources
Everything the three levels need, gathered so a per-ray call takes one object.
Explained in Hello world.
interface GiResourcesimport type { GiResources } from '@driftengine/core';Properties
| Name | Type | Description |
|---|---|---|
eyereadonly | ReadonlyVec3 | |
projectreadonly | (x: number, y: number, z: number, uv: Float32Array) => boolean | |
sceneDistancereadonly | (u: number, v: number) => number | How far the eye is from whatever the frame drew, and Infinity where it drew nothing. |
screenRadiancereadonly | (u: number, v: number, out: Float32Array) => void | The radiance the frame holds at a screen position. |
fieldreadonly | GlobalField | |
fieldRadiancereadonly | (x: number, y: number, z: number, out: Float32Array) => void | The radiance at a world point the field trace arrived at. |
gridreadonly | ProbeGrid | |
visibilityreadonly | ProbeVisibility | null | Null is the off switch, and it lands on the grid's own blend. See probeVolume.ts. |
probeValuesreadonly | Float32Array | probeChannels floats a probe, layer-major. |
probeChannelsreadonly | number | |
screenMarchreadonlyoptional | ScreenSpaceMarch | |
fieldMarchreadonlyoptional | FieldMarch |