Geant4で利用するVisualization Driverを追加する。
Geant4のビジュアライゼーションにはOpenGL、DAWN、RayTracerなど様々なものが利用できる。
8.3. The Visualization Drivers
多くのサイトでこのビジュアライゼーションを利用したければ
Idle> /vis/open OGL
とせよと紹介されているのだがそもそもGeantを動かしたときの利用可能リストに載っていない事がある。
You have successfully registered the following graphics systems.
Current available graphics systems are:
ASCIITree (ATree)
DAWNFILE (DAWNFILE)
G4HepRep (HepRepXML)
G4HepRepFile (HepRepFile)
RayTracer (RayTracer)
VRML1FILE (VRML1FILE)
VRML2FILE (VRML2FILE)
gMocrenFile (gMocrenFile)
次のようになって欲しい
You have successfully registered the following graphics systems.
Current available graphics systems are:
ASCIITree (ATree)
DAWNFILE (DAWNFILE)
G4HepRep (HepRepXML)
G4HepRepFile (HepRepFile)
OpenGLImmediateX (OGLI, OGLIX)
OpenGLStoredX (OGL, OGLS, OGLSX)
RayTracer (RayTracer)
VRML1FILE (VRML1FILE)
VRML2FILE (VRML2FILE)
gMocrenFile (gMocrenFile)
これは環境変数が設定されていないのが原因で例えばOpenGLを加えたければ
export G4VIS_USE_OPENGLX=1
を任意の場所で設定してからmakeし直せば動作する。
このような環境変数の一覧は、 3. GNUMake System: Makefiles and Environment Variables に載っており。
描画関連は次のようになっている。
Visualization specific
The most relevant flags for visualization graphics drivers are just listed here. A description of these variables is given also in section 2. of this User's Guide.
- $G4VIS_BUILD_OPENGLX_DRIVER
- Specifies to build kernel library for visualization including the OpenGL driver with X11 extension. It requires
$OGLHOME
set (path to OpenGL installation). - $G4VIS_USE_OPENGLX
- Specifies to use OpenGL graphics with X11 extension in the application to be built.
- $G4VIS_BUILD_OPENGLXM_DRIVER
- Specifies to build kernel library for visualization including the OpenGL driver with XM extension. It requires
$OGLHOME
set (path to OpenGL installation). - $G4VIS_USE_OPENGLXM
- Specifies to use OpenGL graphics with XM extension in the application to be built.
- G4VIS_BUILD_OPENGLQT_DRIVER
- Specifies to build kernel library for visualization including the OpenGL driver with Qt extension. It requires
$QTHOME
set to specify the path where Qt libraries and headers are installed. - G4VIS_USE_OPENGLQT
- Specifies to use OpenGL graphics with Qt extension in the application to be built.
- $G4VIS_BUILD_OI_DRIVER
- Specifies to build kernel library for visualization including the OpenInventor driver. It requires
$OIHOME
set (paths to theOpenInventor
installation). - $G4VIS_USE_OI
- Specifies to use OpenInventor graphics in the application to be built.
- $G4VIS_BUILD_OIX_DRIVER
- Specifies to build the driver for the free X11 version of OpenInventor.
- $G4VIS_USE_OIX
- Specifies to use the free X11 version of OpenInventor.
- $G4VIS_BUILD_RAYTRACERX_DRIVER
- Specifies to build kernel library for visualization including the Ray-Tracer driver with X11 extension. It requires
X11
installed in the system. - $G4VIS_USE_RAYTRACERX
- Specifies to use the X11 version of the Ray-Tracer driver.
- $G4VIS_BUILD_OIWIN32_DRIVER
- Specifies to build the driver for the free X11 version of OpenInventor on Windows systems.
- $G4VIS_USE_OIWIN32
- Specifies to use the free X11 version of OpenInventor on Windows systems.
- $G4VIS_BUILD_DAWN_DRIVER
- Specifies to build kernel library for visualization including the driver for DAWN.
- $G4VIS_USE_DAWN
- Specifies to use DAWN as a possible graphics renderer in the application to be built.
- $G4DAWN_HOST_NAME
- To specify the hostname for use with the DAWN-network driver.
- $G4VIS_NONE
- If specified, no visualization drivers will be built or used.