rectangleSdf

rectangleSdf

sdf2d
rectangleSdf
RayTK
v0.42

SDF for a 2D rectangle.

Parameters

Name Description Regular Handling Read-Only Handling
Translate

Moves the center of the rectangle.

Runtime Baked
Scale

The size of the rectangle on the x and y axes.

Runtime Baked
UV Mode Semi-Baked Semi-Baked
  • XY Normalized:
  • XY Fit to Outside:

Inputs

  • Scale Field: (optional)
    • Coordinate Types: vec2
    • Context Types: Context MaterialContext CameraContext LightContext RayContext ParticleContext VertexContext PixelContext
    • Return Types: float vec4
  • Translate Field: (optional)
    • Coordinate Types: vec2
    • Context Types: Context MaterialContext CameraContext LightContext RayContext ParticleContext VertexContext PixelContext
    • Return Types: vec4
    • Supports Variables From Inputs: scaleField