Class BrownConradyLens
Lens that implements post processing distortion following the brown-conrady model.
Inherited Members
Namespace: Mechatronics.SensorSDK
Syntax
public class BrownConradyLens : LensComponent
Constructors
BrownConradyLens()
Constructs the lens stack and initializes default parameters.
Declaration
public BrownConradyLens()
Fields
focalLength
Focal length in millimeters, represents the distance between the aperture and the sensor.
Declaration
public float focalLength
Field Value
Type | Description |
---|---|
Single |
Remarks
Higher values will result in lower field of view.
renderHeight
The vertical resolution at which the scene is sampled.
Declaration
public int renderHeight
Field Value
Type | Description |
---|---|
Int32 |
Remarks
Higher values will lead to a higher quality output after the distortion, but at the cost of lower performance.
renderSensorSizeFactor
The multiplier applied to the sensor size before the scene is sampled.
Declaration
public float renderSensorSizeFactor
Field Value
Type | Description |
---|---|
Single |
Remarks
Higher values will lead to being able to have larger distortion, Higher values will require higher resolutions to avoid artifacts.
renderWidth
The horizontal resolution at which the scene is sampled.
Declaration
public int renderWidth
Field Value
Type | Description |
---|---|
Int32 |
Remarks
Higher values will lead to a higher quality output after the distortion, but at the cost of lower performance.
useRaytracing
Enable to use raytracing effects in the camera.
Declaration
public bool useRaytracing
Field Value
Type | Description |
---|---|
Boolean |
Methods
Activate(IPhotosensorArrayDescription)
Initializes the lens component.
Declaration
public override void Activate(IPhotosensorArrayDescription sensorDesc)
Parameters
Type | Name | Description |
---|---|---|
IPhotosensorArrayDescription | sensorDesc | Information define on the photosensor array node. |
Overrides
InternalPostSampling(CustomPassContext, in RenderTexture)
Runs after the sampling step, before returning the frame to the sensor. Can be used to do anything with the texture after the sampling is complete. For example: post processing.
Declaration
protected override RenderTexture InternalPostSampling(CustomPassContext ctx, in RenderTexture inputTexture)
Parameters
Type | Name | Description |
---|---|---|
CustomPassContext | ctx | CustomPassContext used to capture the sample. |
RenderTexture | inputTexture |
Returns
Type | Description |
---|---|
RenderTexture | A render texture with the post processing applied. If the return is null then the frame is assumed to be discarded. |