SMAAWeightsMaterial
Extends:
Implements:
Subpixel Morphological Antialiasing.
This material computes weights for detected edges.
Constructor Summary
Public Constructor | ||
public |
constructor(texelSize: Vector2, resolution: Vector2) Constructs a new SMAA weights material. |
Member Summary
Public Members | ||
public get |
areaTexture: Texture The area lookup texture. |
|
public set |
|
|
public get |
Indicates whether corner detection is enabled. |
|
public set |
|
|
public get |
Specifies how much sharp corners will be rounded. |
|
public set |
|
|
public get |
Indicates whether diagonal pattern detection is enabled. |
|
public set |
|
|
public get |
The maximum steps performed in the diagonal pattern searches, at each side of the pixel. |
|
public set |
|
|
public set |
inputBuffer: Texture The input buffer. |
|
public |
|
|
public get |
The maximum amount of steps performed in the horizontal/vertical pattern searches, at each side of the pixel. |
|
public set |
|
|
public get |
searchTexture: Texture The search lookup texture. |
|
public set |
|
Method Summary
Public Methods | ||
public |
this method was deprecated. Use cornerDetection instead.
Indicates whether corner rounding is enabled. |
|
public |
this method was deprecated. Use diagonalDetection instead.
Indicates whether diagonal pattern detection is enabled. |
|
public |
setCornerRounding(value: Number) this method was deprecated. Use cornerRounding instead.
Specifies how much sharp corners will be rounded. |
|
public |
setCornerRoundingEnabled(value: Boolean) this method was deprecated. Use cornerDetection instead.
Enables or disables corner rounding. |
|
public |
setDiagonalDetectionEnabled(value: Boolean) this method was deprecated. Use diagonalDetection instead.
Enables or disables diagonal pattern detection. |
|
public |
setDiagonalSearchSteps(value: Number) this method was deprecated. Use diagonalSearchSteps instead.
Specifies the maximum steps performed in the diagonal pattern searches, at each side of the pixel. |
|
public |
setInputBuffer(value: Texture) this method was deprecated. Use inputBuffer instead.
Sets the input buffer. |
|
public |
setLookupTextures(search: Texture, area: Texture) this method was deprecated. Use searchTexture and areaTexture instead.
Sets the search and area lookup textures. |
|
public |
setOrthogonalSearchSteps(value: Number) this method was deprecated. Use orthogonalSearchSteps instead.
Sets the maximum amount of steps performed in the horizontal/vertical pattern searches, at each side of the pixel. |
|
public |
Sets the size of this object. |
Public Constructors
public constructor(texelSize: Vector2, resolution: Vector2) source
Constructs a new SMAA weights material.
Params:
Name | Type | Attribute | Description |
texelSize | Vector2 |
|
The absolute screen texel size. |
resolution | Vector2 |
|
The resolution. |
Public Members
public set areaTexture source
public set cornerDetection source
public get cornerRounding: Number source
Specifies how much sharp corners will be rounded. Range: [0, 100].
public set cornerRounding source
public get diagonalDetection: Boolean source
Indicates whether diagonal pattern detection is enabled.
public set diagonalDetection source
public get diagonalSearchSteps: Number source
The maximum steps performed in the diagonal pattern searches, at each side of the pixel. This search jumps one pixel at a time. Range: [0, 20].
On high-end machines this search is cheap (between 0.8x and 0.9x slower for 16 steps), but it can have a significant impact on older machines.
public set diagonalSearchSteps source
public get orthogonalSearchSteps: Number source
The maximum amount of steps performed in the horizontal/vertical pattern searches, at each side of the pixel. Range: [0, 112].
In number of pixels, it's actually the double. So the maximum line length perfectly handled by, for example 16, is 64 (perfectly means that longer lines won't look as good, but are still antialiased).
public set orthogonalSearchSteps source
public set searchTexture source
Public Methods
public isCornerRoundingEnabled(): Boolean source
Indicates whether corner rounding is enabled.
public isDiagonalDetectionEnabled(): Boolean source
Indicates whether diagonal pattern detection is enabled.
public setCornerRounding(value: Number) source
Specifies how much sharp corners will be rounded.
Params:
Name | Type | Attribute | Description |
value | Number | The corner rounding amount. Range: [0, 100]. |
public setCornerRoundingEnabled(value: Boolean) source
Enables or disables corner rounding.
Params:
Name | Type | Attribute | Description |
value | Boolean | Whether corner rounding should be enabled. |
public setDiagonalDetectionEnabled(value: Boolean) source
Enables or disables diagonal pattern detection.
Params:
Name | Type | Attribute | Description |
value | Boolean | Whether diagonal pattern detection should be enabled. |
public setDiagonalSearchSteps(value: Number) source
Specifies the maximum steps performed in the diagonal pattern searches, at each side of the pixel.
Params:
Name | Type | Attribute | Description |
value | Number | The search steps. Range: [0, 20]. |
public setInputBuffer(value: Texture) source
Sets the input buffer.
Params:
Name | Type | Attribute | Description |
value | Texture | The input buffer. |
public setLookupTextures(search: Texture, area: Texture) source
Sets the search and area lookup textures.
Params:
Name | Type | Attribute | Description |
search | Texture | The search lookup texture. |
|
area | Texture | The area lookup texture. |
public setOrthogonalSearchSteps(value: Number) source
Sets the maximum amount of steps performed in the horizontal/vertical pattern searches, at each side of the pixel.
Params:
Name | Type | Attribute | Description |
value | Number | The search steps. Range: [0, 112]. |