\chapter{Results}\label{ch6}

In order to test the Sandstorm particle system, a sample application was created.
The sample application was created using the Dust Framework for the creation of a scene to work with.
The terrain that was used in the scene was of a desert area outside of Yuma, Arizona.
The object that was used in the scene was a blackhawk helicopter, that was not accurate to real world specifications.
A simple control scheme for the helicopter was used, where the wand could be tilted toward the user to increase the throttle and away from the user to decrease the throttle of the helicopter.

A basic vector field was used in this sample application.
Considering that Sandstorm is not a vector field interaction model, where vector fields are calculated according to scientific models, a single vector field was used.
In order to create a dynamic test of the Sandstorm particle system, a simple helicopter-vector field interaction model was created.
This interaction model was nothing more than as the throttle of the helicopter was increased, the amount, life time, and rate of the particles increased.
On the other side, as the throttle of the helicopter was decreased, the amount, life time, and rate of the particles was decreased.
Also as the distance of the helicopter and the ground passed a predetermined point, the amount, life time, and rate of the particle, was also decreased.

The system that this test was run on has the following hardware specifications:
\begin{itemize}\item A multi-cored shared memory machine, with four quad-core chips\end{itemize}
\begin{itemize}\item 48 GBs of RAM\end{itemize}
\begin{itemize}\item Running Ubuntu 7.10 Linux\end{itemize}
\begin{itemize}\item A Nvidia Quadroplex, housing a G80 chipset\end{itemize}
This system was responsible for powering a four-walled active stereo virtual reality CAVE system.

This test was designed to test two major aspects of Sandstorm: the ability of the particles to follow a vector field, and the ability to be run in a multi-contextual environment.
During the course of development of this test it was determined that VRUI could not be used as a VR library for this test on the machine that it was suppose to run on.
The reason for this is that VRUI was not designed to run on a shared memory machine. Instead of creating a multi-contextual environment where general attributes can be passed to separate contexts, VRUI creates a multi-thread environment where each thread has its own set of non-shared variables.
VRUI was abandoned for FreeVR, because of its ability to run on shared memory systems.
Luckily, the Dust Framework had a FreeVR version.

Once Sandstorm was intergrated into the FreeVR, the sample application was run in the CAVE system described above.
Figure~\ref{fig:multicon2} is a picture of Sandstorm running in a CAVE.
Sandstorm was tested for three things: the ability to run in a multi-contextual environment, the ability of particles to follow a vector field, and frame rate.
Sandstorm's ability to run in a multi-contextual environment and the ability for the particles to stay consistent between screens can be seen in Figure~\ref{fig:multicon2}.
In this figure, a yellow line separates two of the screens to which Sandstorm is displaying.
As you can see, in the figures, particles are consistent between the two screens or contexts.
During the test, Sandstorm was responsible for rendering and updating 300,000 particles, well above the required amount specified in Chapter 4.
Sandstorm rendered and updated the particles at 15-20 FPS while standing in the middle of the particle system, and at about 65 FPS while standing a good distance back for the particle system.
While the vector field that was used for this test was not one that was an actual helicopter downdraft vector field, the particles still followed the vector field as prescribed, see Figure~\ref{fig:result2}.
\begin{figure}[h]
    \begin{center}
        \includegraphics[width=12cm]{images/multicon2.png}
    \end{center}
    \caption{An another example of multi-contextualism.}
    \label{fig:multicon2}
\end{figure}

\begin{figure}[h]
    \begin{center}
        \includegraphics[width=140mm]{images/Result2.png}
    \end{center}
    \caption{An example of particles following a vector field.}
    \label{fig:result2}
\end{figure}

Another example of the particles' ability to follow a vector field can be seen in Figure ~\ref{fig:torando}, which is a vector field created to simulate a tornado.
At the center of the image you can use a dense funnel of particles, and as the particles increase in height they start to fall back down to the ground.

\begin{figure}[h]
    \begin{center}
        \includegraphics[width=140mm]{images/tornado.png}
    \end{center}
    \caption{Another example of particles following a vector field.}
    \label{fig:torando}
\end{figure}

Another attribute of Sandstorm that was tested during the running of the sample application was the dynamic attributes of Sandstorm.
This can be seen by the changing rate of emission and changing max life time of the particles as the throttle of a helicopter changed.

