~/src/SARndbox-2.3/etc/SARndbox-2.3/BoxLayout.txt ~/src/SARndbox-2.3/etc/SARndbox-2.3/HeightColorMap.cpt ~/src/SARndbox-2.3/etc/SARndbox-2.3/ProjectorMatrix.dat ~/src/SARndbox-2.3/etc/SARndbox-2.3/SARndbox.cfg
(-0.0302053, -0.0164072, 0.999409), -100.1997 //水平面(海水準)のパラメータ(鉛直ベクトルと深さ) ( -28.4518, -36.6135, -99.2554) //sandboxの四隅(左下) ( 36.3453, -36.2071, -100.039) //sandboxの四隅(右下) ( -28.321, 35.1049, -102.783) //sandboxの四隅(左上) ( 36.313, 34.6932, -99.9503) //sandboxの四隅(右下)
~/src/SARndbox-2.3/bin/CalibrateProjector //投影のキャリブレーション(ProjectorMatrix.datファイルの作成) ~/src/SARndbox-2.3/bin/SARndbox //本体
~/src/SARndbox-2.3/bin/CalibrateProjector -s <width> <height> //投影のキャリブレーション(プロジェクターの解像度入力 円盤を使う) ~/src/SARndbox-2.3/bin/SARndbox -uhm -fpv -ws 0.5 25 -wts 200 100 //
This needs to be a real computer; the AR Sandbox does not work from inside a virtual machine. Install vendor-supplied drivers for the Nvidia graphics card. Open the Control Center, select “Driver Manager,” wait for the panel to show up and the list of available drivers to be populated, and then select the recommended Nvidia binary driver and press “Apply Changes.” Then wait until the change is complete (might take a while), and reboot your computer.
Open a terminal window and enter precisely the following commands (if in doubt, cut & paste directly from this web page, one line at a time). ~ is shorthand for the user’s home directory:
cd ~ wget http://idav.ucdavis.edu/~okreylos/ResDev/Vrui/Build-Ubuntu.sh bash Build-Ubuntu.sh
The script run in the last command will ask you for your user’s password to install prerequisite libraries, and then build the Vrui VR toolkit. That will take a little while and produce lots of output, and at the end you’ll be greeted by a spinning globe in a window. Close that window and go back to the same terminal as before.
cd ~/src wget http://idav.ucdavis.edu/~okreylos/ResDev/Kinect/Kinect-3.2.tar.gz tar xfz Kinect-3.2.tar.gz cd Kinect-3.2 make sudo make install sudo make installudevrules ls /usr/local/bin
Check that the list of names printed by the last command contains KinectUtil and RawKinectViewer.
cd ~/src wget http://idav.ucdavis.edu/~okreylos/ResDev/SARndbox/SARndbox-2.3.tar.gz tar xfz SARndbox-2.3.tar.gz cd SARndbox-2.3 make ls ./bin
Check that the list of names printed by the last command contains CalibrateProjector and SARndbox. The AR Sandbox calibration utility and main application are now in ~/src/SARndbox-2.3/bin.
sudo /usr/local/bin/KinectUtil getCalib 0
This might ask you for your password again; if so, enter it to continue.
Use RawKinectViewer to guide you during alignment. To start it, run in a terminal window:
cd ~/src/SARndbox-2.3 RawKinectViewer -compress 0
cd ~/src/SARndbox-2.3 pluma etc/SARndbox-2.3/BoxLayout.txt &
The ampersand at the end of the second command will keep the terminal window usable while the text editor is running. Now enter the base plane equation as described in the video. To copy text from a terminal window, highlight the desired text with the mouse, and then either right-click into the terminal window and select “Copy” from the pop-up menu that appears, or press Shift-Ctrl-c. To paste into the text editor, use the “Edit” menu, or press Ctrl-v.
The quickest way to copy&paste text from any window into any other window is:
In the newly-released Kinect-3.2 package, this can be done inside RawKinectViewer as well by following the instructions in this video, starting at 4:10. Make sure to measure the box corners in the order lower-left, lower-right, upper-left, upper-right. After you have copied the box corner positions into the text editor as described in the video, save the file (via the “File” menu or by pressing Ctrl-s), and quit from the text editor (via the “File” menu or by pressing Ctrl-q).
Align your projector such that its image fills the interior of your sandbox. You can use the calibration grid drawn by Vrui’s XBackground utility as a guide. In a terminal, run: XBackground After the window showing the calibration grid appears, press the “f” key to toggle it into full-screen mode. Ensure that the window really covers the entire screen, i.e., that there are no title bar, desktop panel, or other decorations left.
Calibrate the Kinect camera and the projector with respect to each other by running the CalibrateProjector utility:
cd ~/src/SARndbox-2.3 ./bin/CalibrateProjector -s <width> <height>
where <width> <height> are the width and height of your projector’s image in pixels. For example, for an XGA projector like the recommended BenQ, the command would be:
./bin/CalibrateProjector -s 1024 768
Very important: switch CalibrateProjector’s window to full-screen mode by pressing F11 before proceeding. Then follow the instructions in this video, starting at 10:10.
cd ~/src/SARndbox-2.3 ./bin/SARndbox -uhm -fpv
Switch SARndbox’s window to full-screen mode by pressing F11, or the calibration created in the previous step will not line up.