ge

True when a is greater than or equal to b.

ge(a: Val, b: Val): Expr

Import math from shaders/std and use math.ge.

Parameters

NameTypeNotes
aVal
bVal

Example

const rightHalf = select(ge(uv.member('x'), 0.5), 1, 0)

See also

  • gt — True when a is greater than b.
  • lt — True when a is less than b.
  • le — True when a is less than or equal to b.
  • select — ifTrue when the condition holds, otherwise ifFalse.

Used by

CarbonFiber