BBMOD_LensFlare

A constructor defined in BBMOD_LensFlare.gml

new BBMOD_LensFlare([_tint[, _position[, _range[, _falloff[, _depthThreshold[, _direction[, _angleInner[, _angleOuter]]]]]]]])

Description

A collection of BBMOD_LensFlareElements that together define a single lens flare instance.

Arguments

Name Type Description
_tint Struct.BBMOD_Color, Undefined The color to multiply lens flare elements' color by. Defaults to BBMOD_C_WHITE if undefined.
_position Struct.BBMOD_Vec3, Undefined The position in the world or undefined, in which case the property BBMOD_LensFlare.Direction is used instead. Defaults to undefined.
_range Real The maximum distance at which is the lens flare visible. Used only in case BBMOD_LensFlare.Position is not undefined. Defaults to infinity.
_falloff Real A multiplier for BBMOD_LensFlare.Range used to compute the distance from the camera at which the lens flare starts fading away. Use values in range 0..1. Defaults to 0.8 (the lens flare starts fading away at 80% of the Range property).
_depthThreshold Real The maximum allowed difference between the flare's depth and the depth in the depth buffer. When larger, the lens flare is not drawn. Defaults to 1.
_direction Struct.BBMOD_Vec3, Undefined The source light's direction or undefined (default).
_angleInner Real, Undefined The inner cone angle in degrees (for lens flares produced by spot lights) or undefined (default).
_angleOuter Real, Undefined The outer cone angle in degrees (for lens flares produced by spot lights) or undefined (default).

Properties

Name Description
AngleInner The inner cone angle in degrees (for lens flares produced by spot lights) or undefined (default).
AngleOuter The outer cone angle in degrees (for lens flares produced by spot lights) or undefined (default).
DepthThreshold The maximum allowed difference between the flare's depth and the depth in the depth buffer. When larger, the lens flare is not drawn. Default value is 1.
Direction The source light's direction or undefined (default).
Falloff A multiplier for BBMOD_LensFlare.Range used to compute the distance from the camera at which the lens flare starts fading away. Use values in range 0..1. Default value is 0.8 (the lens flare starts fading away at 80% of the Range property).
Position The position in the world or undefined, in which case the property BBMOD_LensFlare.Direction is used instead. Default value is undefined.
Range The maximum distance at which is the lens flare visible. Used only in case BBMOD_LensFlare.Position is not undefined. Default value is infinity.
Tint The color to multiply lens flare elements' color by. Default value is BBMOD_C_WHITE.

Methods

Name Description
add_element Adds an element to the lens flare.
add_ghosts A utility function for adding multiple ghosts.
draw Draws the lens flare.
get_elements Retrieves a read-only array of all elements of the lens flare.

See also

BBMOD_LensFlareEffect, BBMOD_LensFlareElement, bbmod_lens_flare_add

Do you find this page helpful?

Copyright © 2024, BlueBurn. Built on April 26, 2024 using GMDoc.