Import Geant4 0.1.0 source tree
This commit is contained in:
@@ -5,8 +5,8 @@
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: G4OpenInventor.hh,v 2.3 1998/12/08 09:51:33 barrand Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
// $Id: G4OpenInventor.hh,v 1.4 1999/05/10 15:38:53 johna Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
//
|
||||
// Guy Barrand 26 Mar 1998.
|
||||
// OpenInventor graphics system factory.
|
||||
@@ -23,10 +23,11 @@ class G4VInteractorManager;
|
||||
class G4OpenInventor: public G4VGraphicsSystem {
|
||||
public:
|
||||
G4OpenInventor(const G4String,const G4String,G4VGraphicsSystem::Functionality);
|
||||
G4VScene* CreateScene(const G4String& name = "");
|
||||
G4VView* CreateView(G4VScene&,const G4String& name = "");
|
||||
virtual ~G4OpenInventor();
|
||||
G4VViewer* CreateViewer(G4VSceneHandler&,const G4String& name = "");
|
||||
void SetInteractorManager(G4VInteractorManager*);
|
||||
G4VInteractorManager* GetInteractorManager();
|
||||
G4VSceneHandler* CreateSceneHandler (const G4String& name);
|
||||
void InitHEPVis();
|
||||
private:
|
||||
G4VInteractorManager* interactorManager;
|
||||
|
||||
@@ -1,38 +0,0 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: G4OpenInventorScene.icc,v 2.1 1998/08/07 12:50:09 barrand Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
//
|
||||
// J Kallenbach 27th Aug 1996
|
||||
// OpenInventor scene - creates OpenInventor Display lists.
|
||||
// 26th January 1998 - added base class callbacks. John Allison.
|
||||
|
||||
inline G4int G4OpenInventorScene::GetSceneCount () {
|
||||
return fSceneCount;
|
||||
}
|
||||
|
||||
inline void G4OpenInventorScene::AddThis (const G4Sphere& sphere) {
|
||||
G4VScene::AddThis (sphere);
|
||||
}
|
||||
|
||||
inline void G4OpenInventorScene::AddThis (const G4Para& para) {
|
||||
G4VScene::AddThis (para);
|
||||
}
|
||||
|
||||
inline void G4OpenInventorScene::AddThis (const G4Torus& torus) {
|
||||
G4VScene::AddThis (torus);
|
||||
}
|
||||
|
||||
inline void G4OpenInventorScene::AddThis (const G4VSolid& vsolid) {
|
||||
G4VScene::AddThis (vsolid);
|
||||
}
|
||||
|
||||
inline void G4OpenInventorScene::AddPrimitive (const G4Polymarker& polymarker) {
|
||||
G4VScene::AddPrimitive (polymarker);
|
||||
}
|
||||
+15
-12
@@ -5,38 +5,38 @@
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: G4OpenInventorScene.hh,v 2.4 1998/12/04 13:16:36 barrand Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
// $Id: G4OpenInventorSceneHandler.hh,v 1.3 1999/05/12 14:00:44 barrand Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
//
|
||||
//
|
||||
// J Kallenbach 27th Aug 1996
|
||||
// OpenInventor scene - creates OpenInventor Display lists.
|
||||
// OpenInventor scene handler - creates OpenInventor Display lists.
|
||||
// 20 dec 1996 jck Add HEPVis primitives - trd, box, etc.
|
||||
|
||||
#ifndef G4OPENINVENTORSCENE_HH
|
||||
#define G4OPENINVENTORSCENE_HH
|
||||
#ifndef G4OPENINVENTORSCENEHANDLER_HH
|
||||
#define G4OPENINVENTORSCENEHANDLER_HH
|
||||
|
||||
#ifdef G4VIS_BUILD_OI_DRIVER
|
||||
|
||||
#include <rw/tvhdict.h>
|
||||
#include <rw/tphdict.h>
|
||||
|
||||
#include "G4VScene.hh"
|
||||
#include "G4VSceneHandler.hh"
|
||||
|
||||
class G4OpenInventor;
|
||||
class SoSeparator;
|
||||
|
||||
// Base class for various OpenInventorScene classes.
|
||||
class G4OpenInventorScene: public G4VScene {
|
||||
class G4OpenInventorSceneHandler: public G4VSceneHandler {
|
||||
|
||||
friend class G4OpenInventorView;
|
||||
friend class G4OpenInventorViewer;
|
||||
|
||||
public:
|
||||
typedef unsigned long G4VSolidPointer;
|
||||
typedef const G4VPhysicalVolume* G4VPhysicalVolumePointer;
|
||||
typedef SoSeparator* SoSeparatorPointer;
|
||||
G4OpenInventorScene (G4OpenInventor& system, const G4String& name = "");
|
||||
~G4OpenInventorScene ();
|
||||
G4OpenInventorSceneHandler (G4OpenInventor& system, const G4String& name = "");
|
||||
virtual ~G4OpenInventorSceneHandler ();
|
||||
void AddPrimitive (const G4Polyline& line);
|
||||
void AddPrimitive (const G4Text&);
|
||||
void AddPrimitive (const G4Circle&);
|
||||
@@ -54,7 +54,7 @@ public:
|
||||
void AddThis (const G4Trd & Trd);
|
||||
void AddThis (const G4Trap & Trap);
|
||||
|
||||
// Base class callbacks defined in G4OpenInventorScene.icc
|
||||
// Base class callbacks defined in G4OpenInventorSceneHandler.icc
|
||||
void AddThis (const G4Sphere&);
|
||||
void AddThis (const G4Para&);
|
||||
void AddThis (const G4Torus&);
|
||||
@@ -69,6 +69,7 @@ public:
|
||||
|
||||
private:
|
||||
void ClearStore ();
|
||||
void ClearTransientStore ();
|
||||
void RequestPrimitives (const G4VSolid& solid);
|
||||
static G4int fSceneIdCount; // static counter for OpenInventor scenes.
|
||||
static G4int fSceneCount; // No. of extanct scenes.
|
||||
@@ -81,10 +82,12 @@ private:
|
||||
RWTValHashDictionary<G4VSolidPointer, G4int> fSolidDictionary;
|
||||
RWTValHashDictionary<G4VPhysicalVolumePointer, SoSeparatorPointer> SeparatorSet;
|
||||
SoSeparator *root;
|
||||
SoSeparator *staticRoot;
|
||||
SoSeparator *transientRoot;
|
||||
SoSeparator *currentSeparator;
|
||||
};
|
||||
|
||||
#include "G4OpenInventorScene.icc"
|
||||
#include "G4OpenInventorSceneHandler.icc"
|
||||
|
||||
#endif
|
||||
|
||||
@@ -0,0 +1,38 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: G4OpenInventorSceneHandler.icc,v 1.1 1999/01/09 16:25:11 allison Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
//
|
||||
//
|
||||
// J Kallenbach 27th Aug 1996
|
||||
// OpenInventor scene - creates OpenInventor Display lists.
|
||||
// 26th January 1998 - added base class callbacks. John Allison.
|
||||
|
||||
inline G4int G4OpenInventorSceneHandler::GetSceneCount () {
|
||||
return fSceneCount;
|
||||
}
|
||||
|
||||
inline void G4OpenInventorSceneHandler::AddThis (const G4Sphere& sphere) {
|
||||
G4VSceneHandler::AddThis (sphere);
|
||||
}
|
||||
|
||||
inline void G4OpenInventorSceneHandler::AddThis (const G4Para& para) {
|
||||
G4VSceneHandler::AddThis (para);
|
||||
}
|
||||
|
||||
inline void G4OpenInventorSceneHandler::AddThis (const G4Torus& torus) {
|
||||
G4VSceneHandler::AddThis (torus);
|
||||
}
|
||||
|
||||
inline void G4OpenInventorSceneHandler::AddThis (const G4VSolid& vsolid) {
|
||||
G4VSceneHandler::AddThis (vsolid);
|
||||
}
|
||||
|
||||
inline void G4OpenInventorSceneHandler::AddPrimitive (const G4Polymarker& polymarker) {
|
||||
G4VSceneHandler::AddPrimitive (polymarker);
|
||||
}
|
||||
@@ -5,8 +5,8 @@
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: G4OpenInventorTransform3D.hh,v 2.1 1998/09/10 12:56:52 barrand Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
// $Id: G4OpenInventorTransform3D.hh,v 1.2 1999/01/09 16:25:11 allison Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
//
|
||||
//
|
||||
// jck 17 Dec 1996
|
||||
|
||||
@@ -1,67 +0,0 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: G4OpenInventorView.hh,v 2.3 1998/11/06 13:42:41 allison Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
//
|
||||
//
|
||||
// Jeff Kallenbach 01 Aug 1996
|
||||
// OpenInventor view - opens window, hard copy, etc.
|
||||
|
||||
#ifndef G4OPENINVENTORVIEW_HH
|
||||
#define G4OPENINVENTORVIEW_HH
|
||||
|
||||
#ifdef G4VIS_BUILD_OI_DRIVER
|
||||
|
||||
#include <rw/tvordvec.h>
|
||||
|
||||
#include <Inventor/Xt/SoXt.h>
|
||||
#include <Inventor/Xt/SoXtComponent.h>
|
||||
#include <Inventor/nodes/SoSelection.h>
|
||||
|
||||
#include "G4VView.hh"
|
||||
|
||||
class G4OpenInventorScene;
|
||||
class G4VInteractorManager;
|
||||
|
||||
//
|
||||
// Base class for various OpenInventorView classes.
|
||||
//
|
||||
class G4OpenInventorView: public G4VView {
|
||||
|
||||
public:
|
||||
G4OpenInventorView (G4OpenInventorScene& scene,
|
||||
const G4String& name = "");
|
||||
~G4OpenInventorView ();
|
||||
void DrawView ();
|
||||
void ShowView ();
|
||||
G4bool GetOIVisualFound () const;
|
||||
|
||||
private:
|
||||
void ClearView ();
|
||||
void FinishView ();
|
||||
void SetView ();
|
||||
void KernelVisitDecision ();
|
||||
|
||||
G4OpenInventorScene& fScene; // Graphics Scene for this view.
|
||||
G4bool OIvisualfound;
|
||||
|
||||
Widget G4OIShell;
|
||||
SoXtComponent* G4OIViewer; // The Inventor Viewer
|
||||
SoSelection* G4OISelection;
|
||||
G4VInteractorManager* interactorManager;
|
||||
};
|
||||
|
||||
inline G4bool G4OpenInventorView::GetOIVisualFound () const {
|
||||
return OIvisualfound;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
@@ -0,0 +1,61 @@
|
||||
// This code implementation is the intellectual property of
|
||||
// the RD44 GEANT4 collaboration.
|
||||
//
|
||||
// By copying, distributing or modifying the Program (or any work
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: G4OpenInventorViewer.hh,v 1.4 1999/05/12 14:00:45 barrand Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
//
|
||||
//
|
||||
// Jeff Kallenbach 01 Aug 1996
|
||||
// OpenInventor viewer - opens window, hard copy, etc.
|
||||
|
||||
#ifndef G4OPENINVENTORVIEWER_HH
|
||||
#define G4OPENINVENTORVIEWER_HH
|
||||
|
||||
#ifdef G4VIS_BUILD_OI_DRIVER
|
||||
|
||||
#include <rw/tvordvec.h>
|
||||
|
||||
#include <Inventor/Xt/SoXt.h>
|
||||
|
||||
#include "G4VViewer.hh"
|
||||
|
||||
class SoXtComponent;
|
||||
class SoSelection;
|
||||
class SoWindow;
|
||||
class G4OpenInventorSceneHandler;
|
||||
class G4VInteractorManager;
|
||||
|
||||
//
|
||||
// Base class for various OpenInventorView classes.
|
||||
//
|
||||
class G4OpenInventorViewer: public G4VViewer {
|
||||
|
||||
public:
|
||||
G4OpenInventorViewer (G4OpenInventorSceneHandler& scene,
|
||||
const G4String& name = "");
|
||||
virtual ~G4OpenInventorViewer ();
|
||||
void DrawView ();
|
||||
void ShowView ();
|
||||
private:
|
||||
void ClearView ();
|
||||
void FinishView ();
|
||||
void SetView ();
|
||||
void KernelVisitDecision ();
|
||||
|
||||
G4OpenInventorSceneHandler& fSceneHandler; // Graphics Scene for this view.
|
||||
Widget fShell;
|
||||
SoWindow* fWindow;
|
||||
SoXtComponent* fViewer; // The Inventor Viewer
|
||||
SoSelection* fSelection;
|
||||
G4VInteractorManager* fInteractorManager;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
@@ -5,8 +5,8 @@
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: G4OpenInventorWin32.hh,v 2.0 1998/07/02 16:47:25 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
// $Id: G4OpenInventorWin32.hh,v 1.3 1999/05/10 15:38:57 johna Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
//
|
||||
// OpenInventor graphics system factory.
|
||||
|
||||
@@ -20,6 +20,7 @@
|
||||
class G4OpenInventorWin32: public G4OpenInventor {
|
||||
public:
|
||||
G4OpenInventorWin32 ();
|
||||
virtual ~G4OpenInventorWin32 ();
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
@@ -5,8 +5,8 @@
|
||||
// based on the Program) you indicate your acceptance of this statement,
|
||||
// and all its terms.
|
||||
//
|
||||
// $Id: G4OpenInventorX.hh,v 2.0 1998/07/02 16:47:27 gunter Exp $
|
||||
// GEANT4 tag $Name: geant4-00 $
|
||||
// $Id: G4OpenInventorX.hh,v 1.3 1999/05/10 15:38:58 johna Exp $
|
||||
// GEANT4 tag $Name: geant4-00-01 $
|
||||
//
|
||||
//
|
||||
// Andrew Walkden 27th March 1996
|
||||
@@ -22,6 +22,7 @@
|
||||
class G4OpenInventorX: public G4OpenInventor {
|
||||
public:
|
||||
G4OpenInventorX ();
|
||||
virtual ~G4OpenInventorX ();
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user