# RaycasterSettings class

Namespace: [Grasshopper2.Imaging.Raycasting](https://developer.rhino3d.com/api/gh2/namespace/grasshopper2.imaging.raycasting.md) · Assembly: [Grasshopper2](https://developer.rhino3d.com/api/gh2/assembly/grasshopper2.md)

```cs
public sealed class RaycasterSettings
```

Class for collecting all properties needed during a raycasting process.

## Constructors

- [RaycasterSettings](https://developer.rhino3d.com/api/gh2/type/grasshopper2.imaging.raycasting.raycastersettings/ctor.md): Create new Raycasting settings.

## Properties

- [Longevity](https://developer.rhino3d.com/api/gh2/type/grasshopper2.imaging.raycasting.raycastersettings/longevity.md): Gets or sets the minimum amount of sampling iterations required after a measurable change before a pixel can be considered fixed.
- [MaximumSamples](https://developer.rhino3d.com/api/gh2/type/grasshopper2.imaging.raycasting.raycastersettings/maximumsamples.md): Gets or sets the maximum samples per pixel. 32 to 64 yield high quality anti-aliasing, but for noisy shaders or thin geometry (anything generating moire patterns) higher values may be called for. 1000 samples is usually overkill, but up to 5000 samples are allowed per pixel.
- [MinimumSamples](https://developer.rhino3d.com/api/gh2/type/grasshopper2.imaging.raycasting.raycastersettings/minimumsamples.md): Gets or sets the minimum samples per pixel.
- [PassCompleted](https://developer.rhino3d.com/api/gh2/type/grasshopper2.imaging.raycasting.raycastersettings/passcompleted.md): Gets or sets the delegate to be called when a new sampling pass completes. This property may be set only once.
- [ProcessCompleted](https://developer.rhino3d.com/api/gh2/type/grasshopper2.imaging.raycasting.raycastersettings/processcompleted.md): Gets or sets the delegate to be called when the total raycasting process completes. This property may be set only once.
- [SubsamplingResolutions](https://developer.rhino3d.com/api/gh2/type/grasshopper2.imaging.raycasting.raycastersettings/subsamplingresolutions.md): Gets or sets the coarse samples to compute prior to the actual progressive raycasting process.
- [Vitality](https://developer.rhino3d.com/api/gh2/type/grasshopper2.imaging.raycasting.raycastersettings/vitality.md): Gets or sets the threshold below which the accumulated difference between the prior and assigned colour of a pixel is considered 'unchanging'. Pixels that chance insufficiently over various iterations will be moved from the live to the dead list and no longer evaluated. 1e-4 may work for images with very low noise levels, 1e-6 will keep pixels alive longer for higher quality results.
