Index of trembling
Contents
List of Anonymous functions
List of structures
List of constants
List of variables
List of functions
List of operators
List of Anonymous functions
List of structures
List of constants
List of variables
magneticPoints
pair[] magneticPoints;
Array of magnetic points.
When a point is magnetized, a trembled path will pass though P if the original path passes through P.
When trembling is enabled with the routine 'startTrembling' all the drawn points is added to this array.
For convenience, one can magnetize an arbitrary number of points with the routine 'magnetize'.<look href="#magnetize(...point[])"><look href="#startTrembling(real,real,real,real,bool">
[
Browse code]
trembleAngle
real trembleAngle=4, trembleFrequency=0.5, trembleRandom=2;
Variables used by the routine 'tremble'.
[
Browse code]
List of functions
attract(pair,path,real)
real atime(pair m, path g, real fuzz=trembleFuzz())
Return the time of the nearest point of 'm' which is on the path g.
'fuzz' is the argument 'fuzz' of 'intersect'.
[
Browse code]
addnode(path,real)
path addnode(path g, real t)
Add a node to 'g' at point(g,t).
[
Browse code]
addnodes(path,int)
path addnodes(path g, int n)
Add 'n' nodes between each node of 'g'.
[
Browse code]
tremble(path,real,real,real,real)
path tremble(path g,
real angle=trembleAngle,
real frequency=trembleFrequency,
real random=trembleRandom,
real fuzz=trembleFuzz())
Return g as it was handwriting.
The postcontrols and precontrols of the nodes of g will be rotated
by an angle proportional to 'angle' (in degrees).
If frequency < 1, floor(1/frequency) nodes will be added to g to increase the
control points.
If frequency >= 1, one point for floor(frequency) will be used to deform the path.
'random' controls the randomized coefficient which will be multiplied 'angle'.
random is 0 means don't use randomized coefficient;
More 'random' is hight more the coefficient is hight and the trembling seems randomized.
[
Browse code]
magnetize(...pair[])
void magnetize(...pair[] P)
Magnetize the points P.
When a point is magnetized, a trembled path will pass though P if the original path passes through P.
[
Browse code]
magnetize(...triangle[])
startTrembling(real,real,real,real,bool
void startTrembling(real angle=trembleAngle,
real frequency=trembleFrequency,
real random=trembleRandom,
real fuzz=trembleFuzz(),
bool magnetizePoints=true)
Calling this routine all drawn paths will be trembled with the givens parameters.Look at
tremble(path,real,real,real,real)
If 'magnetizePoints' is true, most dotted points are automatically magnetized.
[
Browse code]
List of operators