Brush
Description
- Derived from
-
Disposable abstract
IBrush - Extended by
-
CompositeBrushOne abstract
CompositeBrushTwo abstract
Abstract base class for IBrush implementations.
Public / Constructors
InputCopy
A fixed input brush that copies the samples in the given buffer into PaintingBuffer.Samples.
InputImage
A fixed input brush that copies image pixels into a layer of PaintingBuffer.Samples.
- IOException
-
If an I/O error has occurred while reading the image metadata.
- ValidatingException
-
If validation of the resulting IImageReader has failed, for example because of an unsupported file format feature.
- GeorefException
-
If the image contains unsupported geo-referencing metadata and geo opt is
true
.
InputUniform
A flexible input brush that fills the output layers with the given uniform sample value.
MaskRadial
A fixed mask brush that creates a radial coverage mask.
The center sample has full coverage, the border samples have zero coverage. The coverage of the samples in-between is computed like this:
half = size / 2 value = max(0, half - length(x - half, y - half)) / half coverage = pow(value, power)
If power opt is 0
, the following formula is used:
coverage = smoothstep(value)
where smoothstep
is implemented via Maths.SmootherStep1.
Protected / Methods
DoComputeSamples
Computes the output samples of this brush.
This method is called by IBrush.ComputeSamples, after all arguments have been validated and buffer in has been prepared to contain the given heightmap passing layers in.
The PaintingBuffer.SamplesDirty methods will be called on buffer in passing layers in, after this method has returned.
- IOException
-
If an I/O error has occurred.
- GeorefException
-
If the available geo-reference information is incomplete or malformed and brush samples must be projected to resp. from another coordinate system.