Back to Filament

BloomOptions

docs/android/dokka/filament-android/com.google.android.filament/-view/-bloom-options/index.md

1.75.05.6 KB
Original Source

//filament-android/com.google.android.filament/View/BloomOptions

BloomOptions

[main]
open class BloomOptions

Options to control the bloom effect

  • enabled: Enable or disable the bloom post-processing effect. Disabled by default.
  • levels: Number of successive blurs to achieve the blur effect, the minimum is 3 and the maximum is 12. This value together with resolution influences the spread of the blur effect. This value can be silently reduced to accommodate the original image size.
  • resolution: Resolution of bloom's minor axis. The minimum value is 2^levels and the the maximum is lower of the original resolution and 4096. This parameter is silently clamped to the minimum and maximum. It is highly recommended that this value be smaller than the target resolution after dynamic resolution is applied (horizontally and vertically).
  • strength: how much of the bloom is added to the original image. Between 0 and 1.
  • blendMode: Whether the bloom effect is purely additive (false) or mixed with the original image (true).
  • threshold: When enabled, a threshold at 1.0 is applied on the source image, this is useful for artistic reasons and is usually needed when a dirt texture is used.
  • dirt: A dirt/scratch/smudges texture (that can be RGB), which gets added to the bloom effect. Smudges are visible where bloom occurs. Threshold must be enabled for the dirt effect to work properly.
  • dirtStrength: Strength of the dirt texture.

Constructors

BloomOptions[main]
constructor()

Types

NameSummary
BlendMode[main]
enum BlendMode

Properties

NameSummary
blendMode[main]
open var blendMode: View.BloomOptions.BlendMode
how the bloom effect is applied
chromaticAberration[main]
open var chromaticAberration: Float
amount of chromatic aberration
dirt[main]
open var dirt: Texture
user provided dirt texture
dirtStrength[main]
open var dirtStrength: Float
strength of the dirt texture
enabled[main]
open var enabled: Boolean
enable or disable bloom
ghostCount[main]
open var ghostCount: Int
number of flare "ghosts"
ghostSpacing[main]
open var ghostSpacing: Float
spacing of the ghost in screen units [0, 1[
ghostThreshold[main]
open var ghostThreshold: Float
hdr threshold for the ghosts
haloRadius[main]
open var haloRadius: Float
radius of halo in vertical screen units [0, 0.
haloThickness[main]
open var haloThickness: Float
thickness of halo in vertical screen units, 0 to disable
haloThreshold[main]
open var haloThreshold: Float
hdr threshold for the halo
highlight[main]
open var highlight: Float
limit highlights to this value before bloom [10, +inf]
lensFlare[main]
open var lensFlare: Boolean
enable screen-space lens flare
levels[main]
open var levels: Int
number of blur levels (1 to 11)
quality[main]
open var quality: View.QualityLevel
Bloom quality level.
resolution[main]
open var resolution: Int
resolution of vertical axis (2^levels to 2048)
starburst[main]
open var starburst: Boolean
enable starburst effect on lens flare
strength[main]
open var strength: Float
bloom's strength between 0.0 and 1.
threshold[main]
open var threshold: Boolean
whether to threshold the source