Control Running Sandbox - maphew/SARndbox GitHub Wiki

Create the named pipe (below) then:

Using

$ echo "waterAttenuation 0.99" > ~/src/SARndbox-1.6/share/SARndbox-1.6/Control.fifo

Commands

waterSpeed <speed> Sets the water simulation time scale factor to <speed>, a value larger than or equal to zero.

waterMaxSteps <maxNumSteps> Sets the maximum number of water simulation steps per frame to <maxNumSteps>, an integer larger than or equal to zero.

waterAttenuation <attenuation> Sets the water velocity attenuation to <attenuation>, a value larger than zero and smaller than or equal to one.

colorMap <color map name> Loads a new color map from a file named <color map name>

About Named Pipes

A feature introduced in SARndbox v1.6

First, you create a pipe somewhere in the file system. A good place would be the SARndbox resource directory, ~/src/SARndbox-1.6/share/SARndbox-1.6 in the default installation. The pipe can have any name. To create one:

$ cd ~/src/SARndbox-1.6/share/SARndbox-1.6
$ mkfifo Control.fifo

Then, you tell SARndbox the control pipe’s name via the -cp command line parameter:

$ cd ~/src/SARndbox-1.6
$ ./bin/SARndbox <usual parameters> -cp ~/src/SARndbox-1.6/share/SARndbox-1.6/Control.fifo

Once the sandbox is running, you can control it by writing commands to the named pipe. For example,

$ echo "waterAttenuation 0.99" > ~/src/SARndbox-1.6/share/SARndbox-1.6/Control.fifo

will immediately change the water velocity attenuation value to 0.99, which might work well for “simulating” lava.

Error from terminal: Cannot read height color map ~/etc/SARndbox-1.6/xxx-HeightColorMap.cpt due to exception IO::StandardFile: Unable to open file ~/etc/SARndbox-1.6/xxx-HeightColorMap.cpt for reading due to error 2. It turns out that home path expansion, ~ –> /home/username, doesn’t work and that a full path is necessary.


adapted from http://lakeviz.org/forums/topic/minor-software-update/

⚠️ **GitHub.com Fallback** ⚠️