Suppose you want to run your own copy of the Dynamic Scene Generator. What do you need to do?
Get the code from CVS.
All of the code for the DSG lives in SIG's CVS repository, with the server code separated from the interface code. You probably want to start with the interface code, which is under src/scenes/graphics-server. If you're running from a Linux shell, I recommend you do this as follows:
cd ~/public_html
(NOTE: make this directory first if you don't have it yet)
mkdir dsg
cd dsg
cvs checkout -P src/scenes/graphics-server
mv src/scenes/graphics-server/* .
rm -r src
(and reply "y" to all the remove questions)
The DSG server code is a skandha4 module. If you're modifying that, you'll need to get your own copy of the skandha4 source tree from src/skandha4. Within there, the server code will be under lab/xdada/lsp.
Customize the DSG.
Inside src/scenes/graphics-server/cgi-bin lives a sample configuration file, called conf.pl.sample. Make a copy of this file, called conf.pl, and edit it to specify where you want to install your personal version of the DSG.
There's one critical piece of information that isn't in this file: namely, which set of models to use. That bit is stored in the top-level skandha4 file xdada-server.lsp. If you are running your own copy of skandha4, then just change that file in your local copy. Otherwise, you'll need to create your own copy of xdada-server.lsp, tweak it, and modify $SG_CONF{skandha_file} to point to it. (Personally, I recommend using the skull models while you're experimenting, because they load much faster than the thorax models.)
Put the interface scripts in a web-accessible place.
To run the interfaces in cgi-bin, they need to be accessible to your web browser. Either copy them from cgi-bin to the directory in conf.pl:$SG_CONF{cgi_dir}, or add a symbolic link from your own cgi-bin dir to the DSG's cgi-bin dir.
Create output directories.
There are a few directories that the DSG uses for saving results. Someday it should create them on its own, but at the moment it doesn't. Therefore you need to make sure that the following dirs exist in $SG_CONF{root_dir}, and also make sure that group www-data has write access to them:
These directories need to be in a web-accessible place. If you used the sample commands in Step #1, then you're fine. If you checked out a copy into some other place, you'll need to create a symbolic link from your personal web directory to this dir. (For example, ~hinshaw/public_html/dada links to ~hinshaw/src/scenes/graphics-server.)
Start up the DSG server.
Okay, at this point you should be ready to run the DSG server itself. There are two ways to do this. Method #1 is to move into the top-level DSG dir and run:
cgi-bin/startme
This loads the configuration info from conf.pl, and then fires up the script startme-body. If you run into problems, try running startme-body directly to get a better idea of where things are dying. (And if you run startme-body directly, you'll need to change the config vars at the top by hand.)
Method #2 is to start the DSG server directly from the web. For example, if I had the DSG server installed in ~hinshaw/public_html/dsg, then going to this URL:
http://sig.biostr.washington.edu/~hinshaw/cgi-bin/dsg/startme.cgi
will start the DSG server running on sig. (Substitute a different host to run on a different machine.) For personal testing, I usually use Method #1. But if I'm starting up a server that I want to run for a while, I'll use Method #2.
Run the web interface.
If the server started properly, you should now be able to talk to it. Load one of the interfaces (e.g. builder.cgi) in your web browser and see how it works!
Return to the DSG project page.