IShapeRasterizer

Description

interface Tinman.Terrain.Shapes.IShapeRasterizer
<T in ref : ISampleBufferBase>

Extended by

ShapeRasterizer abstract

Base interface for classes that rasterize vector shapes.

Public / Methods

Range

2 overloads


public method Range1 → ()

returns → RangeD

The distance value range.

Returns the distance value range that will be used by shape rasterizers.


public method Range2 → (1)

target in : T

[not-null]
The target sample buffer.

returns → RangeD

The distance value range for the given sample buffer.

Returns the distance value range that will be used by shape rasterizers.

Rasterize


public method Rasterize → (5)

target in : T

[not-null]
The target sample buffer.

bounds opt : Box2D = default(Box2D)

The bounds of the target distance buffer, in the coordinate system of the shape:
Box2D.X1 and Box2D.Y1 refer to the top-left corner of the top-left sample in target in, and Box2D.X2 and Box2D.Y2 refer to the bottom-right corner of the bottom-right sample. When target in has PixelCoverage.PixelIsPoint coverage (see coverage opt), the top-left and bottom-right corners coincide.
Passing IShape.Bounds to this parameter will render the whole shape. If bounds opt is empty (see Box2D.IsEmpty), the shape bounds will be used.

scale opt : float64 = 1

Optional scale factor to apply to distance values.

coverage opt : PixelCoverage = PixelCoverage.PixelIsArea

The coverage semantic of the samples if target in.

face opt : CubemapFace = CubemapFace.None

The cubemap face. This is only relevant for cubemap shapes (see IShapeInfo.IsCubemap).

returns → bool

true if target in has been updated with rasterized samples, false if bounds opt did not intersect the shape.

Rasterizes this shape.

Public / Attributes

Factory


public attribute Factory → (get)

value : IShapeRasterizerFactory<T>

[not-null]
The factory.

The factory that has created this shape rasterizer.

HasInterior


public attribute HasInterior → (get)

value : bool

true if this rasterizer produces interior samples,
false if all interior samples are empty.

Does this rasterizer compute samples for distances that are less than RangeD.Start of Range?