AR_Sandbox/install のバックアップ(No.26)



This page holds complete, step-by-step installation and set-up instructions for the AR Sandbox software, starting from a blank desktop PC with an Nvidia GeForce graphics processing unit (GPU). These instructions are based on the current version of the Linux Mint operating system. Due to increasing weirdness in recent versions of Mac OS X (starting with version 10.7), we can no longer recommend Mac computers and Mac OS X to drive AR Sandbox installations.

These instructions are up-to-date with the following software versions:

目次  

ソフトのインストール  

1.最新バージョンのLinux Mint (64-bit, MATEデスクトップ版) をまっさらなPCにインストールします.  

2.Nvidia製のグラフィックカードを使うためにベンダーのドライバーをインストールします.  

3.Vrui VR toolkitをインストールしてビルドします.  

cd ~
wget http://idav.ucdavis.edu/~okreylos/ResDev/Vrui/Build-Ubuntu.sh
bash Build-Ubuntu.sh

4.Kinect 3D video packageをインストールします.  

cd ~/src
wget http://idav.ucdavis.edu/~okreylos/ResDev/Kinect/Kinect-3.7.tar.gz
tar xfz Kinect-3.7.tar.gz
cd Kinect-3.7
make
sudo make install
sudo make installudevrules
ls /usr/local/bin

5.AR Sandboxのソフト本体をインストールします.  

cd ~/src
wget http://idav.ucdavis.edu/~okreylos/ResDev/SARndbox/SARndbox-2.6.tar.gz
tar xfz SARndbox-2.6.tar.gz
cd SARndbox-2.6
make
ls ./bin

システムの統合・キャリブレーション  

6.第一世代のKinectデバイスを接続して,そのファームウェアから機器固有の調整パラメータをダウンロードします.  

sudo /usr/local/bin/KinectUtil getCalib 0

7.全画面表示のキーボード・ショートカットの登録  

8.Kinectの向きを調整して,カメラの視界がサンドボックスの内側をカバーするようにします.  

cd ~/src/SARndbox-2.6
RawKinectViewer -compress 0

9.サンドボックスの底面を算出します.  

cd ~/src/SARndbox-2.6
pluma etc/SARndbox-2.6/BoxLayout.txt &

【巧みの技: 】テキストを異なるウィンドウ間ですばやくコピペする方法

  1. : コピー元の画面のテキストをマウスで反転させます
  2. : コピー先の画面にマウスを移動させてペーストしたい箇所で中ボタンをクリックします.

10.砂の表面の3次元的広がりを計測します.  

BoxLayout.txt の例(ここで設定するのは2〜5行目です)

(-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の四隅(右下)

11.プロジェクタの投影がサンドボックス内に収まるように本体の向きを調整します.  

XBackground

12.Kinectカメラとプロジェクタの相互関係を調整します.  

cd ~/src/SARndbox-2.6
./bin/CalibrateProjector -s <width> <height>
./bin/CalibrateProjector -s 1024 768

ARSandboxの起動  

13.いよいよメインのAR Sandboxアプリの起動です.  

cd ~/src/SARndbox-2.6
./bin/SARndbox -uhm -fpv

プリセットの作成など  

14.プリセット用のディレクトリの作成  

/.config/Vrui-<version>/Applications

15.CalibrateProjectorプログラム用の設定ファイル  

xed ~/.config/Vrui-4.6/Applications/CalibrateProjector.cfg
section Vrui
   section Desktop
       section Window
           # Force the application's window to full-screen mode:
           windowFullscreen true
       endsection
       
       section Tools
           section DefaultTools
               # Bind a tie point capture tool to the "1" and "2" keys:
               section CalibrationTool
                   toolClass CaptureTool
                   bindings ((Mouse, 1, 2))
               endsection
           endsection
       endsection
   endsection
endsection

(上のテキストをコピペしてエディタに貼り付けてください.)

16.SARndbox用の設定ファイル  

xed ~/.config/Vrui-4.6/Applications/SARndbox.cfg
section Vrui
   section Desktop
       # Disable the screen saver:
       inhibitScreenSaver true
       
       section MouseAdapter
           # Hide the mouse cursor after 5 seconds of inactivity:
           mouseIdleTimeout 5.0
       endsection
       
       section Window
           # Force the application's window to full-screen mode:
           windowFullscreen true
       endsection
       
       section Tools
           section DefaultTools
               # Bind a global rain/dry tool to the "1" and "2" keys:
               section WaterTool
                   toolClass GlobalWaterTool
                   bindings ((Mouse, 1, 2))
               endsection
           endsection
       endsection
   endsection
endsection

17.AR Sandboxを起動するデスクトップアイコンの作成  

xed ~/src/SARndbox-2.6/RunSARndbox.sh
#!/bin/bash

# Enter SARndbox directory:
cd ~/src/SARndbox-2.6

# Run SARndbox with proper command line arguments:
./bin/SARndbox -uhm -fpv
chmod a+x ~/src/SARndbox-2.6/RunSARndbox.sh
xed ~/Desktop/RunSARndbox.desktop
#!/usr/bin/env xdg-open
[Desktop Entry]
Version=1.0
Type=Application
Terminal=false
Icon=mate-panel-launcher
Icon[en_US]=
Name[en_US]=
Exec=/home/<username>/src/SARndbox-2.6/RunSARndbox.sh
Comment[en_US]=
Name=Start the AR Sandbox
Comment=
chmod a+x ~/Desktop/RunSARndbox.desktop

18.起動/ログイン時にARSandboxも起動する  

PCを起動したときに自動的にAR Sandboxも起動するようにするには,

19.複数のモニターを使う場合  

xrandr | grep connected
DVI-I-0 disconnected primary (normal left inverted right x axis y axis)
DVI-I-1 connected 2560x1600+0+0 (normal left inverted right x axis y axis) 641mm x 401mm
HDMI-0 disconnected (normal left inverted right x axis y axis)
DP-0 disconnected (normal left inverted right x axis y axis)
DVI-D-0 connected 1600x1200+2560+0 (normal left inverted right x axis y axis) 367mm x 275mm
DP-1 disconnected (normal left inverted right x axis y axis)
xed ~/.config/Vrui-4.6/Applications/CalibrateProjector.cfg
xed ~/.config/Vrui-4.6/Applications/SARndbox.cfg
       section Window
           ...
           # Open the window on a specific video output port:
           outputName <port name>
           ...
       endsection
xrandr --output DVI-I-1 --auto --primary --output HDMI-0 --auto --right-of DVI-I-1
xrandr --output DVI-I-1 --auto --primary --output HDMI-0 --off

20.AR Sandboxの第2画面表示  

xed ~/.config/Vrui-4.6/Applications/SARndbox.cfg
section Vrui
   section Desktop
       # Open a second window:
       windowNames += (Window2)
       ...
   endsection
endsection
section Vrui
   section Desktop
       ...
       section Window
           ...
       endsection
       
       section Window2
           viewerName Viewer
           screenName Screen
           windowType Mono
           
           # Open the window on a specific video output port:
           outputName <port name>
           
           # Open the window to full-screen mode:
           windowSize (800, 600)
           windowFullscreen true
       endsection
       ...
   endsection
endsection
xed ~/src/SARndbox-2.6/RunSARndbox.sh
./bin/SARndbox -uhm -fpv
./bin/SARndbox -uhm -fpv -wi 1 -rws
xed ~/src/SARndbox-2.6/RunSARndbox.sh
./bin/SARndbox -uhm -fpv -wi 1 -rws -loadView SavedViewpoint0001.view


トップ   新規 一覧 単語検索 最終更新   ヘルプ   最終更新のRSS