Table Of Contents

Introduction

The "Lens Distortion" lens shader allows the rendered image to be distorted via a "UV Map" image.

Due to their lens geometry, real-life cameras tend to distort the captured images. If the user needs to add CG elements to real-life (distorted) camera footage, the CG elements will also have to be distorted.

UV Maps can be generated in programs like Nuke and have the characteristic green/red gradient look.


An example UV Map 

How To Use

You can enable lens distortion via the "Redshift Lens Distortion" lens shader as shown below.


On the camera's Lens Shaders tab, click "Add" and, from the list that appears, select Redshift Lens Distortion




On the camera's Redshift properties, click the checkerboard icon next to "Lens Shaders". Then from the list that appears, select RedshiftLensDistortion




In the "Rendering" menu, click "Effects". On the "Environment and Effects" window, go to the "Effects" tab. Click "Add" and, from the list that appears, select "Redshift Lens Distortion"



To Lens Distortion effect is available via the Redshift Camera tag. If the camera doesn't have one already, one can be created by right-clicking on the camera object and selecting the Redshift Camera tag from the Redshift Tags sub-menu.


The settings for this effect are under the Distortion tab of the Redshift Camera tag


The Lens Distortion effect is available using the custom camera properties that can be added as spare parameters by selecting the camera node and clicking  the CamParms icon in the Redshift toolbar.


The  Lens Distortion effect is available inside the RedshiftRenderSettings node, Camera, Lens Distortion tab.



Once the Lens Distortion lens shader is created, all you have to do is set the distortion image (UV Map) and render.

Lens Distortion Examples

Below are several examples of different lens distortions, each with their appropriate UV distortion maps and an example output image.



Neutral UV Distortion ImageUV Grid ResultImage Result




UV Distortion ImageUV Grid ResultImage Result




UV Distortion ImageUV Grid ResultImage Result





UV Distortion ImageUV Grid ResultImage Result