LensFlareEffectDesc
The LensFlareEffectDesc class is a Descriptor that generates the lens flare effect. It simulates the effect of light from the sun or moon reflecting off the camera lens.
Properties
Section titled “Properties”visible
Section titled “visible”Type: boolean | undefined
Description: Controls the visibility of the effect descriptor.
Default: true
intensity
Section titled “intensity”Type: number | undefined
Description: Specifies the intensity of the lens flare effect.
Default: 0.005
Example:
{ lensFlare: { intensity: 1.5, }}Usage Examples
Section titled “Usage Examples”Enabling lens flare with default effects
Section titled “Enabling lens flare with default effects”import ThreeView from "@navaramap/three";import { DefaultPlugin } from "@navaramap/three_default_plugin";
const view = new ThreeView();const plugin = new DefaultPlugin();view.addPlugin(plugin);await view.init();
// Add default photorealistic objects (includes LensFlareEffectDesc)const defaultLayers = plugin.addDefaultPhotorealScene();
// Enable lens flare and set its intensitydefaultLayers.lensFlare.update({ visible: true, lensFlare: { intensity: 0.005, },});