| The Free Site | vBuddy - make friends, share photos, blogs, have fun | Cheap Web Hosting - starting at $5 |
A Numerical Utility Displaying Ellipsoid Solids
Description, Sources, sample Data files, and History.
Don Herbison-Evans
donherbisonevans@yahoo.com
Central Queensland University
Bundaberg.
(revised 3 January 2010)
**************************************************************
Beryl: a NUDES ballerina, in 3D, as a
Hybrid Wallpaper Autostereogram.
Click here to see her Fouette-en-tournant
**************************************************************
DESCRIPTION
NUDES allows a user to manipulate a set of ellipsoids for which various actions can be performed, each distributed over specified sets of frames. Groups of ellipsoids may be linked togther to form figures. NUDES scripts are written in a formal language which allows the definition of the figures and their required actions.
The language allows the whole scene or individual figures can be translated and rotated. The figures can also be bent at any joint, thus allowing articulation. The whole scene, single figures, or individual ellipsoids can be scaled in size along each of the axes separately. Additionally an ellipsoid can be scaled in size thus moving all the other ellipsoids connected to it except for those connected through a nominated joint. The scene or a figure can be positioned so that the lowest point just touches the ground.
All variables are global. The spacing of items is free, providing there is at least one space between items. Data may be documented by inserting text between an * and the end of a line. Various levels of echoing and diagnostics can be produced.
The frame numbers must be integers in the range 0 to 32767. The earliest frame number is assumed to be 0, and is notional only, and that frame is not drawn. Where more than one action occurs between a given pair of frames, they are performed in the order in which the respective commands are presented.
Sequences of actions can be defined and called as subroutines. Frame numbers in subroutines are only internal and purely relative, with actual numbers supplied in the call.
Units :- the frame is 1000 units wide: the height depends on the output device. Angles are in degrees measured anticlockwise about a rotation axis looking from the origin toward plus infinity along that axis.
x axis: left to right.
y axis: up.
z axis: away from observer.
Keywords may be abbreviated arbitrarily provided no ambiguity results. Keywords may not be used for names.
The NUDES suite was developed using public finance, and so the source codes are hereby made freely publicly available. The programs are all in C or C++.
PC WINDOWS USERS
Three dimensional interactive animation can be obtained
using the program
lintel.cpp
The binary is at lintel.exe
which also needs the graphics library
glut32.dll.
The animation can have the scene rotated, shifted and
scaled interactively, and the speed can be varied or stopped,
and run forward or backward.
The interactive commands are single keyboard characters:
a - animate: default (opp. of 'i')
b - if frozen, go back one frame else run backwards (opp. of 'f')
c - continue through restart at full rate (opp. of 'p')
d - shift down 1% (opp. of 'u')
f - if frozen, show next forward frame else run forwards (opp.of 'b')
g - grow scene by 10% (opp. of 's')
h - show these instructions
i - freeze (opp. of 'a')
j - double the number of polygons per sphere {opp. of 'k')
k - halve the number of polygons per sphere {opp. of 'j')
l - shift scene left 1% (opp. of 'r')
n - display of frame numbers (opp. of 'o')
o - do not display frame numbers (opp. of 'n')
p - pause on first and last frames: default (opp. of 'c')
q - quit
r - shift scene right 1% (opp. of 'l')
s - shrink scene by 10% (opp. of 'g')
t - shift scene away by 10 (opp. of 'T')
u - shift up 1% (opp. of 'd')
v - shift away (opp. of 'w')
w - shift nearer (opp. of 'v')
x - rotate 3 degrees about x (left - right) axis (opp. of '1')
y - rotate 3 degrees about y (vertical) axis (opp. of '2')
z - rotate 3 degrees about z (front - back) axis (opp. of '3')
0 - reset parameters to default values and freeze at start
- - delay more between frames
= - delay less between frames
UNIX / X-WINDOWS USERS
The source codes need to be compiled to give binaries with
names that are the roots of their source code file names
(eg
nudes.c
should be compiled to give a binary: nudes).
The programs are assumed to lie in a directory named /home/don/bin .
For your own use, change the variable 'home' of nudes.c
The main driving program is nudes, and it is called with various parameters specifying the file of NUDES script to be interpreted, what output format is required, and what other options are wanted.
If nudes is called with no parameters, it tries to print out the instructions contained in the initial comments block of its own source code, which assumed to be in a directory "src.nudes" of the directory with absolute path specified in the "home" variable. The contents of this variable should be edited to correspond with the path where it will be stored.
A number of the programs in the NUDES suite have been arranged to do this because the initial comment block in each program describes its use, the meaning of the various calling parameters, the input and output formats, and any peculiarities it has.
The programs can all be called separately, and the intermediate files are all eyeball readable. This makes for flexibility and ease of debugging, at the price of demands on the computer system used: some of the intermediate files can get very large, and the processing time can become very long, especially if the NUDES script uses many ellipsoids. So BEWARE: use the -l and -b options to view just one then a few frames before embarking on the production of a full length animation. The -e option also allows the abbreviation of the computations, at the expense of jerkiness in the resulting animation.
To compile the the programs, I use one of the following:
cxd: compile on DEC Microvax II
cxi: compile on
SGI Workstation
cxl: compile under Linux
cxm: compile on a MIPS
cxs: compile on a SUN
Various output image formats can be produced :-
wireframe
outline drawings (hidden lines removed)
grey scale shaded images
coloured shaded images
anaglyph stereo images
The output frames may be requested gif or compressed 'ppm' format.
Animated sequences can be shown by generating an mpeg file (default).
Thus a simple script for generating an animated mpeg of a
fouette-en-tournant
in colour with shadows using Unix/X-Windows is :
To show generate the 16th frame as an outline (hidden lines omitted) drawing with no shadows in gif format, do:
The programs composing the NUDES suite are: -
Associated files -
George (the NUDES gorilla) and Kenneth (the NUDES kangaroo) at play.
***********************************************************
SOME NUDES DATA SCRIPTS

Frank and Gloria, a NUDES ballroom couple,
dancing the
Merrilyn (a
New Vogue sequence dance)
*************************************
NUDES INPUT SYNTAX
(nudesscript) = (declarations) (movements) (stop)
where (declarations) =
(declaration)
(declarations)
where (declaration) =
debug (integer)
speed (multiplier)
view (framestart) (framestop)
figure (figurename) (ellipsoidcount) (ellipsoidnamelist)
ellips (ellipsoidname) (xvalue) (yvalue) (zvalue)
joint (jointname) (ellipsoidname) (xvalue) (yvalue) (zvalue)
(ellipsoidname) (xvalue) (yvalue) (zvalue)
limit (jointname) (xvalue) (yvalue) (zvalue)
variab (variablecount) (variablenamelist)
subrou (subroutinename)
endsub (subroutinename)
where (movements) =
(movement)
(movements)
where (movement) =
call (framestart) (framestop) (sname)
repeat (framestart) (framestop) (action)
linear (framestart) (framestop) (action)
quadra (framestart) (framestop) (action)
accele (framestart) (framestop) (action)
decele (framestart) (framestop) (action)
cubic (framestart) (framestop) (action)
where (action) =
debug (level)
call (sname)
colour (ename) (redvalue) (greenvalue) (bluevalue)
textur (ename) (iname) (xoffset) (yoffset)
grofig (fname) (ename) (xfactor) (yfactor) (zfactor)
groell (ename) (xfactor) (yfactor) (zfactor)
grojnt (ename) (jname) (xfactor) (yfactor) (zfactor)
movjnt (jname) (ename) (x) (y) (z)
moveto (fname) (ename) (x) (y) (z)
moveby (fname) (referenceellipsoid) (x) (y) (z)
ground (fname)
spinto (fname) (ename) (referenceellipsoid)
(colatitude) (longditude) (twist)
spinby (fname) (ename) (referenceellipsoid) (angle) (axis)
bendto (movingellipsoid) (jname) (referenceellipsoid)
(colatitude) (longditude) (twist)
bendby (movingellipsoid) (jname) (referenceellipsoid)
(angle) (axis)
flex (movingellipsoid) (jname) (angle)
rotate (movingellipsoid) (jname) (angle)
abduct (movingellipsoid) (jname) (angle)
drag (ename) (movingellipsoid) (jname)
(referenceellipsoid) (axis)
touch (mvell) (stillell) (movingellipsoid) (referenceellipsoid) (jname) (axis)
balanc (movingellipsoid) (jname) (referenceellipsoid) (axis)
detach (movingellipsoid) (jname) (fname)
attach (ename) (jname) (ename) (x) (y) (z)
set (variablename) (anything)
invert (variablename)
negate (variablename)
add (variablename) (x) (x)
subtra (variablename) (x) (x)
multip (variablename) (x) (x)
divide (variablename) (x) (x)
angles (ename) (referenceellipsoid)
(variablename) (variablename) (variablename)
centre (ename) (variablename) (variablename) (variablename)
axes (ename) (variablename) (variablename) (variablename)
linkx (jname) (variablename) (variablename) (variablename)
observe (angle) (angle) (angle)
place (x) (y) (z)
write (fname)
print (variablename)
where (ellipsoidnamelist) =
(ellipsoidname) (ellipsoidnamelist)
(ellipsoidname)
where (subroutinenamelist) =
(subroutinename) (subroutinenamelist)
(subroutinename)
where (variablenamelist) =
(variablename) (variablenamelist)
(variablename)
where (x),(y),(z),(angle),
(colatitude),(longditude),(twist),
(xfactor),(yfactor),(zfactor),
(redvalue),(greenvalue),(bluevalue),
(xoffset),(yoffset) =
(variablename)
(value)
where (framestart),(framestop) =
(positiveinteger)
where (positiveinteger) =
(digit)(positiveinteger)
(digit)
where (level),(multiplier) =
(integer)
where (integer) =
(positiveinteger)
-(positiveinteger)
where (value),(xvalue),(yvalue),(zvalue) =
(integer).(positiveinteger)
(integer)
where (fname) =
every
world
(figurename)
(variablename)
where (ename),(stillell),(mvell),
(movingellipsoid),(referenceellipsoid) =
world
(ellipsoidname)
(variablename)
where (iname) =
(imagename)
(variablename)
where (jname) =
(jointname)
(variablename)
where (sname) =
(subroutinename)
(variablename)
where (prefix) =
(non-space character)
where (oldfigurename),(newfigurename),
(figurename),(ellipsoidname),
(jointname),(subroutinename),
(variablename),(imagename) =
(up to 6 non-space characters)
where (axis) =
(variablename)
x
y
z
where (anything) =
(value)
(axis)
(ellipsoidname)
(jointname)
(figurename)
(subroutinename)
(variablename)
where (stop) =
stop
NUDES KEYWORD SEMANTICS
key no description
debug 22 - set debug parameter to given value
speed 30 - delete or interpolate extra frames
view 33 - set range of frames actually to be drawn
figure 1 - declare ellipsoids that compose given figure
ellips 2 - declare semi-axis lengths of given ellipsoid
joint 3 - declare position of given joint
limit 54 - declare angle limits on joint movements
variab 32 - declare names of variables
repeat 23 - do the given action at each frame in given range
linear 25 - generate action over given frames at constant rate
quadra 24 - generate given action accelerating then decelerating
to rest quadratically
cubic 46 - generate given action accelerating then decelerating
to rest cubically
accele 5 - generate action linearly accelerating from rest
decele 10 - generate action linearly decelerating to rest
linkx 49 - store coordinates of a joint
axes 48 - store semiaxis lengths of an ellipsoid
angles 36 - store the current orientation angles of an ellipsoid
centre 37 - store current coordinates of centre of an ellipsoid
subrou 6 - start a subroutine definition
end 29 - end of subroutine or main program
call 28 - call a subroutine
stop 16 - no more commands after this
colour 50 - colour the named ellipsoid the red, green,
blue coordinates given
textur 52 - map given image file onto ellipsoid named
print 51 - print value of given variable
ground 18 - make lowest point of given figure touch ground plane
grofig 11 - scale given figure about centre of given
ellipsoid, multiplying all parts of figure
by given factor
groell 34 - scale a single ellipsoid in size keeping all
joints fixed
grojnt 35 - scale a single ellipsoid in size keeping a
nominated joint of it fixed, and allowing its
centre, other joints and connected ellipsoids
to move appropriately
moveby 13 - move given figure by given amounts parallel to
the axes of given reference ellipsoid
moveto 27 - move given figure so that centre of given
ellipsoid is at given position
movjnt 56 - move a joint relative to the centre of an
ellipsoid
spinby 17 - spin given figure about centre of given ellipsoid,
rotating by given angle about given axis in given
reference ellipsoid
spinto 12 - spin given figure about centre of given ellipsoid,
rotating given ellipsoid to given angles relative
to axes in given reference ellipsoid
bendby 19 - bend figure by given angle about given axis in
given reference ellipsoid at given joint,
rotating the given moving ellipsoid and all
those joined to it
bendto 21 - bend figure at given joint, rotating given
ellipsoid to given angles relative to axes in
given reference ellipsoid
flex 38 - bend given joint about x axis
rotate 39 - bend given joint about y axis inwards
abduct 40 - bend given joint about z axis away from body
drag 53 - bend second (moving) ellipsoid at given joint about
its given axis so that first ellipsoid
touches the ground, while ensuring that the rest
of the figure is grounded also
touch 15 - make first ellipsoid touch the second ellipsoid
by bending the third ellipsoid at the given joint
about the given axis of the third ellipsoid.
abut 55 - make ellipsoid1 touch ellipsoid2 by moving its
figure parallel to given axis of ellipsoid3
balanc 7 - bend at given joint about given axis of reference
ellipsoid to balance the moving set of ellipsoids
with respect to y axis gravity
set 20 - set a value to a named variable
invert 31 - divide 1 by value
negate 41 - negate the value of a named variable
add 14 - add two variables or values to give a variable
subtra 42 - subtract second value from first to give a variable
multip 44 - multiply two values to give a variable
divide 43 - divide second value into first to give a variable
attach 8 - join 2 figures at the point on the second
ellipsoid which is shifted from its centre
by the given coordinates
detach 9 - break a figure into 2 at given joint, naming
the figure containing the given ellipsoid by
the given name, and keeping the old figure name
for the other part of the old figure
observ 26 - set eulerian angles of direction of observer
place 47 - set centre of view of observer
*************************************
NUDES HISTORY
21 Sep 2005 lintel27- able to run .n files also
17 Sep 2005 lintel26- drag limited to high ankle position
2 May 2005 drawel43- deleted input summary printout
26 Apr 2005 drawel42- adding compl
26 Apr 2005 drawel41- adding shadows
25 Apr 2005 complu- fix view command
25 Apr 2005 complt- fix final summary
24 Apr 2005 drawel40- correcting shading
24 Apr 2005 drawel39- compressing z axis
23 Apr 2005 drawel38- fixing place/observe error
20 Apr 2005 compls- change nels to ne
20 Apr 2005 drawel35- writing errors to standard output
8 Apr 2005 drawel35- debugging view transform
7 Apr 2005 drawel34- incorporating movement simulation (prfrm)
5 Apr 2005 drawel33- incorporating view transform (view)
4 Apr 2005 drawel32- scale about screen centre
3 Apr 2005 drawel31- input root of datafile name
28 Mar 2005 drawel30- improving vertical illumination
28 Mar 2005 drawel29- improving file name input
27 Mar 2005 drawel28- file name input
27 Mar 2005 drawel27- echoed commands
27 Mar 2005 drawel26- slowed pause, added 'v','w'
26 Mar 2005 drawel25- fixed shading
26 Mar 2005 drawel24- fixed visibility of frame numbers
22 Mar 2005 drawel23- fixed x and y rotations
22 Mar 2005 drawel- fixed z rotation and help
22 Mar 2005 drawel- show frame numbers
22 Mar 2005 drawel- fixed inter-frame delay
22 Mar 2005 drawel- fixed pausing on first and last frames
22 Mar 2005 drawel- added single frame forward and back
21 Mar 2005 drawel- added pause routine
19 Mar 2005 drawel- separate setels routine.
13 Mar 2005 drawel- translating to C++ for .NET
3 Apr 2005 complr- list statistics at end
1 Apr 2005 complq- read nudes filename root
29 Mar 2005 complp- rewritten in C++ for .NET 2003
12 Sep 2003 prfrm- error message contains frame number
10 Sep 2003 prfrm- touch using nested search
7 Sep 2003 compl- avoiding expanding the 0-1 frame period with -e option
24 Jul 2003 prfrm- extending drag search angle from 10 to 20 degrees
16 Jun 2003 prfrm- improving drag
6 Jun 2003 prfrm- debugging drag
10 Jan 2003 drawel12- fixing batch flag descriptions
5 Sep 2002 drawel- making x rotation inwards
5 Sep 2002 drawel- fixing single frame bug
16 Jan 2002 viewc- double precision throughout
22 Nov 2001 drawel- reporting when arrays limit animation length
28 Sep 2001 drawel- fixing shading to after rotation
23 Sep 2001 drawel- fixing delay routine
23 Sep 2001 drawel- delayed double buffer swap
21 Sep 2001 drawel- fixing CreateWindow bug
15 Aug 2001 drawel- start with trigonal bipyramids
1 Aug 2001 drawel- adding variable display slow
14 Jun 2001 drawel- fixing shading
7 Jun 2001 drawel- show frame numbers
24 May 2001 drawel- slowing up
24 May 2001 drawel- trying for animation
15 May 2001 drawel- trying to get shading right
3 May 2001 drawel- getting rotations in right order
2 May 2001 drawel- enabling hidden surface testing
24 Mar 2001 drawel- initsphere revised
7 Mar 2001 drawel- opengl routine names inserted
24 Jan 2001 drawel- interactive and flag options removed for simplicity.
17 Aug 2000 drawel- for gl on Viewsonic/Zondata machines.
23 Apr 1998 drawel- display slow
17 Apr 1998 drawel- t for translate in z, +/- for slow
23 Mar 1997 compl- debug information hidden more
18 Mar 1997 compl- optional warnings
17 Jul 1996 prfrm- print command to standard error output
7 Feb 1996 prfrm- clean up dotouch
3 Feb 1996 prfrm- clear floating exceptions
19 Aug 1994 prfrm- removed some goto's
13 Aug 1994 prfrm- cleaning up perfrm
21 Jul 1994 compl- fixed 'match' bug
29 Apr 1994 prfrm- cleaning up drag
28 Apr 1994 compl- variable subroutines permitted
22 Sep 1993 prfrm- cleaning up after detach fixed up
10 Sep 1993 drawel- accommodates joint information
10 Sep 1993 compl- documentation improved
16 Aug 1993 compl- movjnt added
2 Aug 1993 viewb- allows joint information
12 Mar 1993 compl- abut added
11 Mar 1993 compl- repeated subroutine calls allowed
4 Mar 1993 compl- keyword 'all' turned into 'every'
17 Feb 1993 prfrm- touch using Buckdale's algorithm
4 Feb 1993 prfrm- touch using scanning
28 Oct 1992 prfrm- joint limits added
15 Oct 1992 prfrm- viewing transformation separated (view)
12 Jun 1992 compl- drag added
17 Apr 1992 prfrm- touch fixed
26 Feb 1992 drawel- written : for Silicon Graphics Iris
12 Feb 1992 compl- allow cubic movements
29 Jul 1991 prfrm- print variable values nicely
24 Nov 1988 prfrm- more ellipsoids accommodated
7 Apr 1987 compl- translated to c, copy deleted
10 Dec 1986 prfrm- translated into c
29 Nov 1986 prfrm- write figure for Benesh interpreter
25 Nov 1986 compl- write a complete figure
17 Oct 1986 prfrm- texturing for ellipsoids
7 Oct 1986 compl- texture statement added
8 Mar 1986 compl- print statement added
21 Jul 1985 compl- ellipsoids declared on the fly
22 Jun 1985 prfrm- grofig scales about an ellipsoid (Peter Gummer)
14 Jun 1985 prfrm- spinto added (Peter Gummer)
15 Apr 1985 prfrm- setels simplified (Peter Gummer)
12 Apr 1985 compl- simplified subroutine join (Peter Gummer)
3 Apr 1985 compl- world added, refell for spinby,moveby (Peter Gummer)
3 Jan 1985 prfrm- attach, detach work properly (Peter Gummer)
23 May 1984 compl- change parsing order
7 May 1984 prfrm- multiply, subtract, divide, balance added
22 Dec 1983 compl- reduced number of constants in val
14 Dec 1983 compl- variable frame numbers
12 Dec 1983 prfrm- variable frame numbers
25 Nov 1983 prfrm- rotations stored as twist about axis
22 Nov 1983 prfrm- separate error message file
2 Nov 1983 compl- moved integer codes 11-19 to 21-29 (Danuta Kucharska)
15 Oct 1983 compl- added 'colour' action (Danuta Kucharska)
15 Oct 1983 compl- ellipsoid default colour to flesh (Danuta Kucharska)
16 Aug 1983 compl- work out range of frames
19 Apr 1983 prfrm- insert axes, link, fix detach, ground
16 Sep 1982 prfrm- ellipsoid names put in 1st frame
19 Jul 1982 prfrm- tolerance put in subroutine rotput
31 Mar 1982 compl- observe, all, par array stored
26 Mar 1982 prfrm- single precision version for speed
26 Mar 1982 nudes- move to Digital PDP11/34
8 Oct 1981 prfrm- make data structure of figure a list
2 Oct 1981 prfrm- add, attach, detach, flex, extend, etc. added
1 Oct 1981 compl- add,touch,attach,detach,flex,etc
28 Sep 1981 compl- declare variables to PMAX
16 Jul 1981 compl- to negate variables (Nora Neilands)
16 Jun 1981 compl- to store orientations and positions (Nora Neilands)
29 May 1980 compl- moved to 64KB PDP11: separate compile and perform
27 Jul 1979 nudes- groell, grojnt added
20 Feb 1979 nudes- subroutines added
1 Apr 1977 nudes- named constants introduced
17 Jan 1977 nudes- bends use arbitrary reference ellipsoid (Bruce McNair)
4 Jun 1976 nudes- made interpretive
10 May 1976 nudes- input translation separated from drawing
1 Apr 1975 nudes- frame numbers used in input language
1 Apr 1975 nudes- translated in to Fortran for IBM 7040
28 Oct 1974 nudes- to use optionally the plotter
24 Sep 1974 nudes- to verbalize the input language
11 Aug 1973 nudes- translated into Fortran for IBM 7040
11 Apr 1973 nudes- to allow more than one figure
1 Dec 1972 nudes- to remove hidden lines
11 Aug 1972 nudes- written in Algol for English Electric KDF9 (Don Herbison-Evans)
Frame 23 of jocke.n