Threshold

Function

This function will cut off channels at a certain value, turning everything below that cutoff to zero. Each channel can have its own separate cutoff. By using the crush parameter, you can boost everything above that value 1.

 

Parameters
Type
Defaults
Function
red,green,blue,alpha
float
0 Anything below this value goes to black.
crush
int
0 If this is 1, everything above the cutoff values goes to 1.


Synopsis

image Threshold( 
  image In,
  float red,
  float green,
  float blue,
  float alpha,
  int crush
 );


Script

image = Threshold( 
  In,
  red,
  green,
  blue,
  alpha,
  crush
 );
       

Command Line

shake -threshold red green blue alpha crush