---
title: "Lens Effects Layer"
canonical: "https://documentation.chaos.com/space/VRAYUNREAL/116558081/Lens%20Effects%20Layer"
format: markdown
---
> Macro (rw-ui-expands-macro)
> 
> > Macro (rw-expand)
> 
> ||V-Ray Frame Buffer|| > **Layers**
> 
> ![image](media://53d65fb5-7b54-4795-9e18-1f227e31019c)



## **Lens FX controls**

---

**Opacity** – Controls the weight of the layer. A value of 0 means no effect and a value of 1.0 means full effect.

**Enable bloom/glare **–** **Enables the V-Ray Lens Effects.

**Size** – Specifies the size of the filter as percentage of the image's diagonal.

**Intensity **– Multiplier for the bloom/glare source bright pixels. Increasing the value can boost the effect by simulating up to 20 times brighter source. Values lower than 1 can be used to produce subtle bloom/glare from overbright sources.

**Bloom **– Controls the blend between bloom and glare. A value of 1 forces bloom to be applied to full extent and without any glare. A value of 0 removes the bloom completely and applies only glare. Values in-between blend the two effects proportionally.

**Threshold **– Sets a minimum value for the rendered pixels to be considered as lens effects source. The **Bloom/Glare effect** will be generated only regarding pixels with larger value than the specified threshold.

**Rotation **– Rotates the final result effect, regardless of this is a filter image or a procedurally created one. 

**Saturation** – When the value is set 0, the effects use the original hue of the bright pixels to create bloom and glare. Larger values intensify the hue set with the **Cold/Warm** option.

**Hardware Accelerated** – Enable to calculate lens effects on the GPU. When multiple devices are present, V-Ray will prioritize the best one available.

**Cold/Warm **– When enabled, the **Bloom/Glare effect **will be toned to cold hues. When disabled, the effects will receive warm hue. The hue shift requires **Saturation** values larger than 0.

**Interactive **– When enabled, the bloom/Glare effect will be automatically recalculated and applied after any V-Ray lens effects parameter change.

**Save Glare channel** – When enabled, writes the glare channel to a file when writing all channels.

**Update **– Manually forces the recalculation of the bloom/glare effects.



## **Aperture Shape**

---

Clicking the  button displays/hides the parameters of the rollout.

**Blades **– Enables the Blades effect.

**Sides **– Sets custom camera aperture blades number to be considered for the lens effects. This parameter directly controls the number of "rays" of the glare.

**Blades rotation **–** **Controls the rotation of the camera aperture and blades.

**Streak blur **– Determines the width of the angle at which glare rays spread. The larger the value, the wider the spread. If set to 0, rays are directional; if set to 1, glare rays spread out and completely blend together.

**Peripheral grating** – Enables grating along the sides of the aperture shape. 

**Density** – Controls the density of the grating effect in percent, where 100 is fully black.

**Length **– Controls the length of the grate lines.

**Zoom **– Controls the size of the halo around the lights.

**Slope **– Controls the direction of the lines.

**Strength **– Controls the strength of the blades effects.

**Occlusion **– When enabled it controls the aperture shape by occluding part of it.

**Symmetric **– Enables symmetric occlusion of the shape. When disabled, the occlusion appears only on one side of the shape.

**Percent **– Controls how much of the shape is occluded.

**Rotation **– Determines the position of the occlusion over the shape by rotation.

**Arc **– Controls the arc of the occlusion. A value of 0 sets a straight line, while a value of 100 makes an arc.



## **Lens Scratches**

---

**Lens scratches** – Enables the lens scratches effect.

**Symmetric **– When enabled creates symmetric pattern of the scratches. This option is available only when **Pattern** is **Random**.

**Pattern** – Specifies **Random**, **Stripes**, **Square** or **Hexagonal** type of pattern for the scratches.

**Streaks **– Specifies the number of streaks that are clustered together. If **Symmetric** is enabled, the streaks are stemming from one point with equal angles. If **Symmetric** is disabled, the streaks are scattered from random angles.

**Density **– Controls the density of the scratches effect in percent, where 100 is fully black.

**Length **– Controls the length of the scratches.

**Slope variance **– Randomizes the direction of the scratches.

**Width variance **– Randomizes the width of the scratches.

**Seed **– Specifies a seed parameter to introduce variance in the randomization.

**Zoom **– Controls the size of the pattern.

**Rotation** – Determines the position of the scratches by rotation.

**Strength **– Controls the strength of the effect.



## **Lens Dust**

---

**Lens dust **– Enables the lens dust effect.

**Pattern **– Specifies the **Random**, **Square** or **Hexagonal** type of pattern for the dust.

**Density **– Controls the density of the dust effect in percent, where 100 is fully black.

**Radius variance **– Specifies a variance in the radii of the dust dots. A value of 0 makes the dust dots uniform.

**Jitter **– Controls randomization of the position of the dots.

**Zoom **–  Controls the size of the dust dots.

**Rotation **– Determines the position of the dust dots by rotation.

**Strength **– Controls the strength of the effect.



## **Obstacle Image**

---

**Obstacle image** – When enabled, an obstacle image can be specified. You can use it to simulate various effects on the camera lens.

**Load Obstacle Image** – Loads an obstacle image.

**Browse** – Opens a browser to search for an obstacle image.

**Recent** – Shows a list of recently used obstacle images.

**Zoom **– Controls the size of the obstacle image. 

**Rotation **– Rotates the obstacle image. 

**Strength **– Controls the strength of the effect.



## **Filter Image**

---

Enabling this rollout disables the controls for the generated filter:

**Filter image** – Enables a filter image from the Filter generator tool to be used.

**Load Filter** – Specifies the path to a filter kernel. You can create filters using the Filter generator tool which comes with the V-Ray for 3ds Max installation.

**Browse** – Opens a browser to search for a filter image.

**Recent** – Shows a list of recently used filter images.



## **Aperture Preview**

---

The Aperture Preview panel is loaded by default, but can be minimized like the other Aperture groups. The aperture shape shows the result of the applied lens effects.



## **File Names of Saved Channels**

---

As expected, channels will keep their names as displayed in the VFB when saving them to a single *.vrimg* or *.exr* file (using the **V-Ray raw image file** option from the Frame buffer rollout or the **Save all image channels to single file** VFB button). The same channel names will be appended to the files when you use the VFB button **Save all image channels to separate files**.

However, using the **Save separate render channels** option from the Frame buffer rollout to save all layers as separate files will save the **effectsResult** channel to a file with the text *RGB_color* appended to its name, and the RGB channel as *origRGB* instead.

---


### **Example: Bloom / Glare**

---


### **Example: Intensity**

---


### **Example: Cold/Warm & Saturation**


---


### **Example: Obstacle Images**

**Size (constant) = 50**  
**Bloom (constant) = 0.5**