Skip to main content Link Menu Expand (external link) Document Search Copy Copied
render2D

render2D

Shortcuts:

Renders a 2D image by evaluating the input field for each pixel.

The input field can return either vec4 which is used as RGBA, or a float, which is copied to all 4 channels. The input field can use either 2D coordinates, or 1D, in which case it only uses the X axis and renders the same result for each vertical line of pixels.

Parameters

  • Resolution:
  • Pixel Format:
    • Use Input:
    • 8-bit fixed (RGBA):
    • sRGB 8-bit fixed (RGBA):
    • 16-bit float (RGBA):
    • 32-bit float (RGBA):
    • _separator_:
    • 10-bit RGB, 2-bit Alpha, fixed (RGBA):
    • 16-bit fixed (RGBA):
    • 11-bit float (RGB), Positive Values Only:
    • 16-bit float (RGB):
    • 32-bit float (RGB):
    • 8-bit fixed (Mono):
    • 16-bit fixed (Mono):
    • 16-bit float (Mono):
    • 32-bit float (Mono):
    • 8-bit fixed (RG):
    • 16-bit fixed (RG):
    • 16-bit float (RG):
    • 32-bit float (RG):
    • 8-bit fixed (A):
    • 16-bit fixed (A):
    • 16-bit float (A):
    • 32-bit float (A):
    • 8-bit fixed (Mono+Alpha):
    • 16-bit fixed (Mono+Alpha):
    • 16-bit float (Mono+Alpha):
    • 32-bit float (Mono+Alpha):
  • Alignment: How coordinates are positioned within the render frame.
    • Center: Places 0,0 in the center of the frame.
    • Legacy: Old default behavior. Note that when used, `Scaling` is ignored. When in doubt, don't use this.
    • Bottom Left: Places 0,0 at the bottom left of the frame.
  • Scaling: How coordinates are scaled within the render frame.
    • Fill: Stretches coordinates so both axes are -0.5 on one side and 0.5 on the other.
    • Fit Inside: Uses the smaller of the two dimensions of the frame resolution to put -0.5..0.5 on that axis, and whatever the equivalent is on the other axis so that the scaling remains uniform.
    • Fit Outside: Equivalent to `Fit Inside` but uses the larger of the two dimensions.
  • UV Map: UV Map that is used to pick the uV coordinates used for each pixel. If this is provided, the `Alignment` and `Scaling` not used.
  • Time Reference Operator:
  • Shader Builder Config:
  • Zoom:
  • Offset:
  • Customize Shader Config:
  • Enable UV Output:
  • Enable Normal Output:
  • Enable Debug Output:
  • Enable Custom Output 1:
  • Enable Custom Output 2:

Inputs

  • definition_in: (optional)
    • Coordinate Types: float vec2
    • Context Types: Context
    • Return Types: float vec4 Sdf