## Controllers reference ben-o

Posts: 121
Joined: 11 Jun 2012, 10:41

### Controllers reference

Hi!

Here is a list of every controller and an explanation about what they do. If you're unsure about a specific block, come check it out!

If an explanation is unclear or you need more information about a block or its use, don't hesitate to ask in the Brush Making forum. ben-o

Posts: 121
Joined: 11 Jun 2012, 10:41

### Re: Controllers reference

Stroke parameters

Pressure:
Returns the tablet's pen pressure.
Nears 0 when no pressure is applied and goes to 1 at full pressure.

Speed
Returns the stroke's speed.
Attaining a speed of 1 requires a very fast movement so you may want to multiply it by for example 5 to get a easier effect.

Time
Time elapsed since the start of the stroke.
It goes above 1 very quickly so you might need to divide it by 10 or 20 for direct time driven use. Is a good input for sinus or noise.

Length
Length of the stroke. Just like the time it attains 1 very quickly. Also a good input for sinus or noise.

Tilt
The altitude of the tablet's pen inclination.
Returns 1 when the pen is perpendicular from the tablet's surface and nears 0 when it is tilted very close to the surface.

Azimuth
The direction in which the tablet's pen is tilted, in degrees.
0 is when the pen is oriented towards the top of the tablet. Most common use is to divide it by 360 to obtain a 0 to 1 value.

Direction
The direction of the stroke in degrees.
0 is going towards the left of the document. Like the azimuth, you will most of the time want to divide it by 360. For example, to make a shape follow the direction of the stroke, divide direction by 360, plug it in the rotation parameter and set the brush rotation from 0 to 360.

Canvas PosX and Canvas PosY
Current position on the document, in pixels, from the top left corner.

Canvas PosX [0..1] and Canvas PosY [0..1]
Current position on the document, normalized, from the top left corner.
X returns 0 on the left of the document and 1 on the right, Y 0 at the top and 1 at the bottom.

View PosX and View PosY
Current position in Black Ink's drawing viewport, in pixels, from the top left corner.

View PosX [0..1] and View PosY [0..1]
Current position in Black Ink's drawing viewport, normalized, from the top left corner. ben-o

Posts: 121
Joined: 11 Jun 2012, 10:41

### Re: Controllers reference

Math f(x)

Ease Cubic
Simple ease function to smooth the ends of a value.

Ease Power
Power function.
The value is multiplied by itself a number of times defined in the block's parameters. The result is a value staying closer to zero unless it nears 1. Useful with pressure to gain more control over low pressures and keep the highest values for when really pressing intentionally on the tablet.

Sinus
Returns a wave effect from an input: the value regularly goes up and down between -1 and 1.
The block's parameters are predefined to return a result between 0 and 1, for easier use. Time or Length are good inputs because they both have constantly increasing values.

Abs
Returns the absolute value of the input. -0.5 returns 0.5, 0.5 returns 0.5.

Floor
Returns the nearest lower integer. 0.5 returns 0, 1.5 returns 1, 2.5 returns 2..

Frac
Returns the fractional value of the input. 0.5 returns 0.5, 1.5 returns 0.5, 2.5 returns 0.5..

Exp
Exponential function.

Log
Logarithmic function. ben-o

Posts: 121
Joined: 11 Jun 2012, 10:41

### Re: Controllers reference

Operators

Adds input A and input B

Sub
Subtracts input B to input A.
Useful to invert values: plug the input value in B and set A to 1. For example a pressure in opacity will make the shape more opaque when you press harder and 1-Pressure will do the opposite, making it more opaque when you press less.

Mul
Multiplies input A and input B.
Very easy operation to use: for example, multiplying a value by the pressure will at low pressure multiply by a number closer to 0, making it smaller. At full pressure it will multiply by 1, not changing it.

Div
Divides input A by input B.

Mod
Modulo. remainder of the division of input A by input B.
In more practical terms, it allows to repeat a value from zero to a defined limit. For example length with a modulo at 0.5 will go up as usual but when it attains 0.5, will restart from 0.

Step
Returns 0 if input A is inferior to B, 1 if superior.
In other terms, the B value is used to choose whether the A input is converted to a 0 or a 1. For example: If B is set to 0.5, 0.1 returns 0, 0.4 returns 0, 0.6 returns 1, 0.9 returns 1. ben-o

Posts: 121
Joined: 11 Jun 2012, 10:41

### Re: Controllers reference

Signals

Smooth
Smooth the input value by factor.

Random
Creates a random value between 0 and 1. has no input.

Noise Smooth
Generate a smooth noise from the input value. Time or length are often used for most common regular results.

Noise Cell
Generate a square noise from the input value.The value jumps from one result to another without interpolation. ben-o

Posts: 121
Joined: 11 Jun 2012, 10:41

### Re: Controllers reference

Mixing

Mix
Blends input A and input B by the factor input.
When the factor value goes towards 0 the result tends to be the value given in A and when going towards 1, the one in B. A factor of 0.5 is the average of the two inputs.

Min
Returns the lowest value between input A and input B.

Max
Returns the highest value between input A and input B.

Clamp
Limits input value to min and max.
Every value below min become the min and every value above max becomes the max. Note that once plugged in the final output, the parameters only consider values between 0 and 1 so there's no need to clamp before use. 