triangleSdf2d
sdf2d
triangleSdf2d
RayTK
v0.42
SDF for a 2D triangle.
Parameters
Name | Description | Regular Handling | Read-Only Handling |
---|---|---|---|
Shape | Which type of triangle to produce. The types are defined by different sets of parameters. | Semi-Baked | Semi-Baked |
| |||
Radius | The distance from the center to each corner of the triangle. Used for equilateral triangles. | Runtime | Semi-Baked |
Height | The distance from the base of an iscosceles triangle to the opposite tip. | Runtime | Semi-Baked |
Width | The width of the base of an isosceles triangle. | Runtime | Semi-Baked |
Point 1 | The first corner position, for an arbitrary triangle. | Runtime | Baked |
Point 2 | The second corner position, for an arbitrary triangle. | Runtime | Baked |
Point 3 | The third corner position, for an arbitrary triangle. | Runtime | Baked |
Direction | Runtime | Baked | |
|
Inputs
-
Radius Field
: (optional)- Coordinate Types:
vec2
- Context Types:
Context
MaterialContext
CameraContext
LightContext
RayContext
ParticleContext
VertexContext
PixelContext
- Return Types:
float
- Coordinate Types:
-
Height/Width Field
: (optional)- Coordinate Types:
vec2
- Context Types:
Context
MaterialContext
CameraContext
LightContext
RayContext
ParticleContext
VertexContext
PixelContext
- Return Types:
float
- Supports Variables From Inputs:
radiusField
- Coordinate Types: