1attraction(6x)                XScreenSaver manual               attraction(6x)
2
3
4

NAME

6       attraction - interactions of opposing forces
7

SYNOPSIS

9       attraction  [-display  host:display.screen] [-foreground color] [-back‐
10       ground color] [-window] [-root]  [-mono]  [-install]  [-visual  visual]
11       [-points  int]  [-threshold  int]  [-mode  balls  |  lines | polygons |
12       splines | filled-splines | tails ] [-size int] [-segments int]  [-delay
13       usecs]  [-color-shift  int]  [-radius  int] [-vx int] [-vy int] [-glow]
14       [-noglow] [-orbit] [-viscosity  float]  [-mouse]  [-no-mouse]  [-mouse-
15       size]  [-walls]  [-nowalls] [-maxspeed] [-nomaxspeed] [-correct-bounce]
16       [-fast-bounce] [-fps]
17

DESCRIPTION

19       The attraction program has several visually different modes  of  opera‐
20       tion,  all  of  which are based on the interactions of a set of control
21       points which attract each other up to  a  certain  distance,  and  then
22       begin to repel each other.  The attraction/repulsion is proportional to
23       the distance between any two particles.
24

OPTIONS

26       attraction accepts the following options:
27
28       -window Draw on a newly-created window.  This is the default.
29
30       -root   Draw on the root window.
31
32       -mono   If on a color display, pretend we're on a monochrome display.
33
34       -install
35               Install a private colormap for the window.
36
37       -visual visual
38               Specify which visual to use.  Legal values are the  name  of  a
39               visual  class,  or the id number (decimal or hex) of a specific
40               visual.
41
42       -points integer
43               How many control points should be used, or 0 to select the num‐
44               ber randomly.  Default 0.  Between 3 and 15 works best.
45
46       -threshold integer
47               The  distance  (in  pixels)  from  each  particle  at which the
48               attractive force becomes repulsive.  Default 100.
49
50       -mode balls | lines | polygons | tails | splines | filled-splines
51               In balls mode (the default) the control  points  are  drawn  as
52               filled  circles.   The  larger the circle, the more massive the
53               particle.
54
55               In lines mode, the control points  are  connected  by  straight
56               lines; the effect is something like qix.
57
58               In  polygons mode, the control points are connected by straight
59               lines, and filled in.  This is most interesting in color.
60
61               In splines mode, a closed spline is interpolated from the  con‐
62               trol points.
63
64               In  filled-splines  mode,  the splines are filled in instead of
65               being outlines.  This is most interesting in color.
66
67               In tails mode, the path which each particle  follows  is  indi‐
68               cated  by  a worm-like trail, whose length is controlled by the
69               segments parameter.
70
71       -size integer
72               The size of the balls in pixels, or 0, meaning  to  select  the
73               sizes  randomly  (the default.)  If this is specified, then all
74               balls will be the same size.  This option has an effect in  all
75               modes, since the ``size'' of the balls controls their mass.
76
77       -segments integer
78               If in lines or polygons mode, how many sets of line segments or
79               polygons should be drawn. Default 500.  This has no  effect  in
80               balls  mode.   If  segments is 0, then no segments will ever be
81               erased (this is only useful in color.)
82
83       -delay microseconds
84               How much of a delay should be introduced between steps  of  the
85               animation.  Default 10000, or about 0.01 seconds.
86
87       -color-shift int
88               If  on a color display, the color of the line segments or poly‐
89               gons will cycle through the color map.  This specifies how many
90               lines  will  be  drawn  before  a new color is chosen.  (When a
91               small number of colors are  available,  increasing  this  value
92               will  yield  smoother  transitions.)   Default  3.  This has no
93               effect in balls mode.
94
95       -radius The size in pixels of the circle on which the points  are  ini‐
96               tially  positioned.   The  default is slightly smaller than the
97               size of the window.
98
99       -glow   This is consulted only in balls mode.  If  this  is  specified,
100               then  the  saturation  of  the  colors  of the points will vary
101               according to their current acceleration.  This has  the  effect
102               that  the  balls  flare brighter when they are reacting to each
103               other most strongly.
104
105               In glow mode, all of the balls will be drawn the same  (random)
106               color,  modulo  the  saturation  shifts.  In non-glow mode, the
107               balls will each be drawn in a random color that doesn't change.
108
109       -noglow Don't do ``glowing.''  This is the default.
110
111       -vx pixels
112
113       -vy pixels
114               Initial velocity of the balls.  This has no  effect  in  -orbit
115               mode.
116
117       -orbit  Make the initial force on each ball be tangential to the circle
118               on which they are initially placed, with the right velocity  to
119               hold  them  in orbit about each other.  After a while, roundoff
120               errors will cause the orbit to decay.
121
122       -vmult float
123               In orbit mode, the initial velocity of the balls is  multiplied
124               by  this;  a number less than 1 will make the balls pull closer
125               together, and a larger number will make them move  apart.   The
126               default is 0.9, meaning a slight inward pull.
127
128       -viscosity float
129               This sets the viscosity of the hypothetical fluid through which
130               the control points move; the default is 1,  meaning  no  resis‐
131               tance.   Values  higher than 1 aren't interesting; lower values
132               cause less motion.
133
134               One interesting thing to try is
135               attraction -viscosity 0.8 -points 75 \
136                 -mouse -geometry =500x500
137               Give it a few seconds to settle down into a stable  clump,  and
138               then move the mouse through it to make "waves".
139
140       -mouse  This  will cause the mouse to be considered a control point; it
141               will not be drawn, but it will influence the other  points,  so
142               you can wave the mouse and influence the images being created.
143
144       -no-mouse
145               Turns off -mouse.
146
147       -mouse-size integer
148               In -mouse mode, this sets the mass of the mouse (analogously to
149               the -size parameter.)
150
151       -nowalls
152               This will cause the balls to continue on past the edge  of  the
153               screen  or  window.   They  will still be kept track of and can
154               come back.
155
156       -walls  This will cause the balls to bounce when they get to  the  edge
157               of the screen or window.  This is the default behavior.
158
159       -maxspeed
160               Imposes  a  maximum  speed  (default).  If a ball ends up going
161               faster than this, it will be treated as though  there  were  .9
162               viscosity  until  it  is  under the limit. This stops the balls
163               from continually accelerating (which they have  a  tendency  to
164               do), but also causes balls moving very fast to tend to clump in
165               the lower right corner.
166
167       -nomaxspeed
168               If this is specified, no maximum speed is set for the balls.
169
170       -fast-bounce
171               Uses the old, simple bouncing algorithm (default).  This simply
172               moves  any  ball  that  is  out  of  bounds  back to a wall and
173               reverses its velocity.  This works fine  for  most  cases,  but
174               under some circumstances, the simplification can lead to annoy‐
175               ing effects.
176
177       -correct-bounce
178               Uses a more intelligent bouncing algorithm.  This method  actu‐
179               ally  reflects  the  balls  off the walls until they are within
180               bounds.  This can be slow if balls are bouncing  a  whole  lot,
181               perhaps because of -nomaxspeed.
182
183       -graphmode none | x | y | both | speed
184               For "x", "y", and "both", displays the given velocities of each
185               ball as a bar graph in the  same  window  as  the  balls.   For
186               "speed",  displays  the  total  speed of each ball.  Default is
187               "none".
188
189       -fps    Display the current frame rate and CPU load.
190

ENVIRONMENT

192       DISPLAY to get the default host and display number.
193
194       XENVIRONMENT
195               to get the name of a resource file that  overrides  the  global
196               resources stored in the RESOURCE_MANAGER property.
197

SEE ALSO

199       X(1), xscreensaver(1)
200
202       Copyright  ©  1992,  1993,  1997 by Jamie Zawinski.  Permission to use,
203       copy, modify, distribute, and sell this software and its  documentation
204       for  any purpose is hereby granted without fee, provided that the above
205       copyright notice appear in all copies  and  that  both  that  copyright
206       notice  and  this permission notice appear in supporting documentation.
207       No representations are made about the suitability of this software  for
208       any  purpose.   It  is provided "as is" without express or implied war‐
209       ranty.
210

AUTHOR

212       Jamie Zawinski <jwz@jwz.org>, 13-aug-92.
213
214       Viscosity and mouse support by Philip Edward Cutone, III.
215
216       Walls, speed limit options, new bouncing, graphs, and tail mode fix  by
217       Matthew Strait. 31 March 2001
218
219
220
221X Version 11               5.15-3.fc14 (18-Oct-2011)            attraction(6x)
Impressum