Geant4  10.03.p01
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
G4HepRepViewer Class Reference

#include <G4HepRepViewer.hh>

Inheritance diagram for G4HepRepViewer:
Collaboration diagram for G4HepRepViewer:

Public Member Functions

 G4HepRepViewer (G4VSceneHandler &scene, const G4String &name="")
 
virtual ~G4HepRepViewer ()
 
void SetView ()
 
void ClearView ()
 
void DrawView ()
 
void ShowView ()
 
void FinishView ()
 
void reset ()
 
- Public Member Functions inherited from G4VViewer
 G4VViewer (G4VSceneHandler &, G4int id, const G4String &name="")
 
virtual ~G4VViewer ()
 
virtual void Initialise ()
 
virtual void ResetView ()
 
void RefreshView ()
 
std::vector< G4ThreeVectorComputeFlyThrough (G4Vector3D *)
 
const G4StringGetName () const
 
const G4StringGetShortName () const
 
void SetName (const G4String &)
 
G4int GetViewId () const
 
G4VSceneHandlerGetSceneHandler () const
 
const G4ViewParametersGetViewParameters () const
 
const G4ViewParametersGetDefaultViewParameters () const
 
virtual const std::vector
< G4ModelingParameters::VisAttributesModifier > * 
GetPrivateVisAttributesModifiers () const
 
void SetViewParameters (const G4ViewParameters &vp)
 
void SetDefaultViewParameters (const G4ViewParameters &vp)
 
const G4VisAttributesGetApplicableVisAttributes (const G4VisAttributes *) const
 
void SetNeedKernelVisit (G4bool need)
 
void NeedKernelVisit ()
 
void ProcessView ()
 

Additional Inherited Members

- Protected Member Functions inherited from G4VViewer
void SetTouchable (const std::vector< G4PhysicalVolumeModel::G4PhysicalVolumeNodeID > &fullPath)
 
void TouchableSetVisibility (const std::vector< G4PhysicalVolumeModel::G4PhysicalVolumeNodeID > &fullPath, G4bool visibility)
 
void TouchableSetColour (const std::vector< G4PhysicalVolumeModel::G4PhysicalVolumeNodeID > &fullPath, const G4Colour &)
 
- Protected Attributes inherited from G4VViewer
G4VSceneHandlerfSceneHandler
 
G4int fViewId
 
G4String fName
 
G4String fShortName
 
G4ViewParameters fVP
 
G4ViewParameters fDefaultVP
 
G4bool fNeedKernelVisit
 

Detailed Description

Author
Mark Donszelmann

Definition at line 42 of file G4HepRepViewer.hh.

Constructor & Destructor Documentation

G4HepRepViewer::G4HepRepViewer ( G4VSceneHandler scene,
const G4String name = "" 
)

Definition at line 49 of file G4HepRepViewer.cc.

50  : G4VViewer (sceneHandler, sceneHandler.IncrementViewCount(), name),
51  geometryIncluded(false) {
52 
53 #ifdef SDEBUG
54  cout << "G4HepRepViewer::G4HepRepViewer " << name << endl;
55 #endif
56 
57  // Make changes to view parameters for HepRep...
58  fVP.SetCulling(false);
59  fDefaultVP.SetCulling(false);
60 }
const XML_Char * name
Definition: expat.h:151
G4ViewParameters fDefaultVP
Definition: G4VViewer.hh:206
G4VViewer(G4VSceneHandler &, G4int id, const G4String &name="")
Definition: G4VViewer.cc:46
G4ViewParameters fVP
Definition: G4VViewer.hh:205
void SetCulling(G4bool)

Here is the call graph for this function:

G4HepRepViewer::~G4HepRepViewer ( )
virtual

Definition at line 64 of file G4HepRepViewer.cc.

64  {
65 #ifdef SDEBUG
66  cout << "G4HepRepViewer::~G4HepRepViewer" << endl;
67 #endif
68  G4HepRep* pHepRepSystem =
69  dynamic_cast<G4HepRep*>(GetSceneHandler()->GetGraphicsSystem());
70  if (pHepRepSystem) pHepRepSystem->removeViewer();
71 }
G4VGraphicsSystem * GetGraphicsSystem() const
void removeViewer()
Definition: G4HepRep.cc:84
G4VSceneHandler * GetSceneHandler() const

Here is the call graph for this function:

Member Function Documentation

void G4HepRepViewer::ClearView ( void  )
virtual

Implements G4VViewer.

Definition at line 74 of file G4HepRepViewer.cc.

74  {
75 #ifdef SDEBUG
76  cout << "G4HepRepViewer::ClearView" << endl;
77 #endif
78 }
void G4HepRepViewer::DrawView ( )
virtual

Implements G4VViewer.

Definition at line 93 of file G4HepRepViewer.cc.

93  {
94 #ifdef SDEBUG
95  cout << "G4HepRepViewer::DrawView" << endl;
96 #endif
97  if (!geometryIncluded) {
98  // draws the geometry
100  ProcessView();
101  geometryIncluded = true;
102  }
103 }
void NeedKernelVisit()
Definition: G4VViewer.cc:78
void ProcessView()
Definition: G4VViewer.cc:105

Here is the call graph for this function:

void G4HepRepViewer::FinishView ( void  )
virtual

Reimplemented from G4VViewer.

Definition at line 122 of file G4HepRepViewer.cc.

122  {
123 #ifdef SDEBUG
124  cout << "G4HepRepViewer::FinishView" << endl;
125 #endif
127 }
virtual void FinishView()
Definition: G4VViewer.cc:101

Here is the call graph for this function:

void G4HepRepViewer::reset ( )

Definition at line 129 of file G4HepRepViewer.cc.

129  {
130  geometryIncluded = false;
131 }
void G4HepRepViewer::SetView ( )
virtual

Implements G4VViewer.

Definition at line 80 of file G4HepRepViewer.cc.

80  {
81 #ifdef SDEBUG
82  cout << "G4HepRepViewer::SetView" << endl;
83 #endif
84 }
void G4HepRepViewer::ShowView ( void  )
virtual

Reimplemented from G4VViewer.

Definition at line 105 of file G4HepRepViewer.cc.

105  {
106 #ifdef SDEBUG
107  cout << "G4HepRepViewer::ShowView" << endl;
108 #endif
110 
111  G4HepRepSceneHandler* sceneHandler = dynamic_cast<G4HepRepSceneHandler*>(GetSceneHandler());
112  if (sceneHandler) {
113  if (sceneHandler->closeHepRep()) {
114  sceneHandler->openHepRep();
115 
117  if (messenger->appendGeometry()) geometryIncluded = false;
118  }
119  }
120 }
bool closeHepRep(bool final=false)
virtual void ShowView()
Definition: G4VViewer.cc:103
static G4HepRepMessenger * GetInstance()
virtual G4bool appendGeometry()
G4VSceneHandler * GetSceneHandler() const

Here is the call graph for this function:


The documentation for this class was generated from the following files: