THE OVERALL STRUCTURE OF SFA
All of the source code for SFA is place in one of the two directories:
rewrite
ui
REWRITE
The rewrite directory contains the files which handle
the data structures, input files, and data management. Here is a
listing of the files contained in the rewrite directory and their purpose:
AlphaMap.C
Contains the functions that initialize
alpha maps, read previously generated alpha maps from a file, write the
alpha maps to a file, and set alpha maps to a data dimension.
CCache.C
This file handles the contour
caching by organizing a caching structure based on position to efficiently
find glyphs near a 2D contouring plate in order to calculate the contour
lines.
ColorMap.C
Similar to AlphaMap.C, this file contains the functions
that initialize, read from a file, and write to a file the color maps,
as well as, set the color maps to a data dimension.
Contour.C
Creates
a contour panel to visualize the Xsize attribute coupled with density .
As the plate moves through the volume, the luminance of the plate changes
to reflect the Xsize and density of glyphs at the plate location.
ContourList.C
Contains
the functions that generate the dials and menu lists that control the contour
panel.
DataSet.C
One
of the primary files in the rewrite directory, this file contains the functions
that will manage the datasets (i.e. set the dimensions to mappings, pullout
key information from the datataset, and translate the data to values that
are used by the draw routine), as well as, build 3D textures, step
through data, and create caches that will sort the data based on their
scale(Xsize).
DataSetList.C
The
functions in this file insert, remove, and find datasets from a list that
stores the datasets that are loaded into SFA. There are also functions
that handle the subsetting, contouring, and stepping of the datatsets.
DataSetNode.H
This file defines a container
class that facillitates storing DataSets in the DataSetList
Defines.H
Simply contains many of the #defines
for the number of display dimensions, indices to the elements of the PackedGlyph
structure, error codes, glyph shapes, and constants for 3D texturing. These
values are used throughout SFA.
FileHandler.H
Currently, FileHandler.H does
not serve a specific purpose.
FileIO.C
This
file contains the functions that read the setfiles from either a separate
files or the internet. Setfiles are meta data files containg the files
where the actual data can be found, what they are supposed to be mapped
to, and other information concerning the structure of the data (length,
name, time steps, etc.). There are functions that then create the
datasets to be used by SFA from the information obtained by the setfiles.
There are also functions that will create setfiles from datasets are already
stored with in SFA.
GlobalScale. C
Defines a class which stores global
scaling information. This is used when multiple datasets are loaded
concurrently, and we want everything to fall within the same coordinate
system(s).
Interface.C
Contains the callback functions
for the dials and menus that available in the two-handed interaction version
of SFA.
MappingNode.C
The functions that map the actual
data variables to the glyph attributes (shape, color, position, etc.)
NoMR.C
Defines the class used to replace
MR functionality when SFA has been compiled without MR.
PackedGlyph.C
Contains the data structure of
a glyph and it's attributes that is then used to draw the glyph. A function
is also present that will sort the glyphs based on "size" and insert them
into an array.
Rules.make
This file contains the settings needed upon compilation (i.e. Fanatic and
trackers support) as well as the libraries and compilation flags necessary.
StaticObject.C
Implements static objects in the
scene. The eventual goal is to have a pseudo-scenegraph available
to put in arbitrarily complex objects into the scene, such as spacecraft
models. Initially, it will only
support scaled sphere geometry to represent astronomically
sized objects (eg: earth, moon, sun), but will be extensible to support
more complex models in the future.
StaticObjectList.C
Manages static objects in a scene.
This class handles loading, creation, and management of the static objects,
which are instances of SFAStaticObject (StaticObject.[CH]).
String.C
Contains the function implementation
for the String class. This class, however, is currently not being used.
StringSFA.C
Contains the function implementation
for the StringSFA class that is currently being used in SFA.
Subset.C
Handles the graphical interaction
routines used in subsetting with MR and with the mouse.
TexFont.C
This C++ class manages the textured
fonts that appear in SFA.
main.C
This program, which is not used
when SFA is run, is a test program that initializes the network daemons,
reads new datasets, deletes the datasets, and writes a metafile that it
prints out.
UI
The ui directory
contains the files that generate the user interface, as well as, the main
draw routines that are used in SFA. In addition, the executable for SFA
is located here as well. Here is a listing of the main files located in
the ui directory and their purpose:
Dial.C
This file contains the draw routines
for the sundial menus that are used in conjunction with MR.
Draw.C
One of the main files in SFA,
this file contains the majority of draw routines for generating the glyphs,
the bounding box, and handling stereo viewing. In addition, mouse interaction
is handled here as is the drawing of vectors.
Form.C
This file, generated by BXPro,
contains the code for the drawing of the interface and the menus and widgets
contained within the interface. Inside the designated user code blocks,
code has been added that define the callbacks for the widgets in the interface.
Labels.C
Contains the functions that generate
the labels used to indicate the postition of the bat(cursor) within the
bounding box.
Led.C
Currently, this file has not been
integrated into SFA.
LedController.C
Currently, this file has not been
integrated into SFA.
NetThread.C
These functions handle the opening
of socket connections in order to read data from external agents.
SQuadrics.C
These functions are used to generate
the superellipsoid glyphs.
SelectionCubic.C
Generates a cubic with which the
user can perform subsetting with.
SelectionObject.C
Handles the cubic and sphere classes
that can be used for subsetting.
SelectionSphere.C
Generates a sphere with which
the user can perform subsetting with.
SfaControlButtons.C
This file, generated by BXPro,
contains the callbacks for the control buttons (OK, RESET, and APPLY) that
are used throughout SFA.
Shapes.C
Currently
written in C, this files contains the draw routines for many of the interpolated
shapes (i. e. tetrahedron-to-cube, tetrahedron-to-octahedron, octahedron-to-cube,
turbulated cube, etc.).
Slider.C
Implements a fairly simple slider control
which is controlled by the trackers.
TextureFactory.H
This class has multiple accessors
which take a filename of a 2D texture and return a pointer to the loaded
2D texture. This will make adding future textures to SFA extremely
simple.
UIComponent.C
Base
class for all C++/Motif UI components.
Vector_noise.C
Vector functions that are used
in the Shapes.C file.
Xfun.C
Auxillary
functions to convert an array string to an array of compund strings and
free an XmStringTable widget in XMotif.
Form.ucb*, app-defaults, bXsave.uil, default.txf,
defs-C.H, interface.uil, main-C.C, outfile
Files created by BXPro. interface.uil
is the file that is to be opened in BXPro when modifications need to be
made.
sfa-ui*
The main SFA executable.
sfa-ui.H
Contains many of the #defines
used throughout SFA and links in some of the files in the rewrite directory.
trackball.c
Implementation of a virtual trackball
that is, currently, not integrated into SFA.
vect.c
Various
functions to support operations on vectors that are used throughout SFA.
Christopher J. Morris --5/25/00