Geant4 10.7.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4HepRepSceneHandler Class Reference

#include <G4HepRepSceneHandler.hh>

+ Inheritance diagram for G4HepRepSceneHandler:

Public Member Functions

 G4HepRepSceneHandler (G4VGraphicsSystem &system, const G4String &name="")
 
virtual ~G4HepRepSceneHandler ()
 
void AddSolid (const G4Box &box)
 
void AddSolid (const G4Cons &cons)
 
void AddSolid (const G4Tubs &tubs)
 
void AddSolid (const G4Trd &trd)
 
void AddSolid (const G4Trap &trap)
 
void AddSolid (const G4Sphere &sphere)
 
void AddSolid (const G4Para &para)
 
void AddSolid (const G4Torus &torus)
 
void AddSolid (const G4Polycone &polycone)
 
void AddSolid (const G4Polyhedra &polyhedra)
 
void AddSolid (const G4Orb &orb)
 
void AddSolid (const G4Ellipsoid &ellipsoid)
 
void AddSolid (const G4TessellatedSolid &tess)
 
void AddSolid (const G4VSolid &solid)
 
void AddCompound (const G4VTrajectory &)
 
void AddCompound (const G4VHit &hit)
 
void AddCompound (const G4VDigi &digi)
 
void AddCompound (const G4THitsMap< G4double > &hits)
 
void AddCompound (const G4THitsMap< G4StatDouble > &hits)
 
void PreAddSolid (const G4Transform3D &objectTransformation, const G4VisAttributes &visAttribs)
 
void PostAddSolid ()
 
void AddPrimitive (const G4Polyline &)
 
void AddPrimitive (const G4Text &)
 
void AddPrimitive (const G4Circle &)
 
void AddPrimitive (const G4Square &)
 
void AddPrimitive (const G4Polyhedron &)
 
void AddPrimitive (const G4Polymarker &)
 
void AddPrimitive (const G4Scale &scale)
 
void BeginPrimitives (const G4Transform3D &objectTransformation)
 
void EndPrimitives ()
 
void BeginModeling ()
 
void EndModeling ()
 
void openHepRep ()
 
bool closeHepRep (bool final=false)
 
void openFile (G4String name)
 
void closeFile ()
 
- Public Member Functions inherited from G4VSceneHandler
 G4VSceneHandler (G4VGraphicsSystem &system, G4int id, const G4String &name="")
 
virtual ~G4VSceneHandler ()
 
virtual void PreAddSolid (const G4Transform3D &objectTransformation, const G4VisAttributes &)
 
virtual void PostAddSolid ()
 
virtual void AddSolid (const G4Box &)
 
virtual void AddSolid (const G4Cons &)
 
virtual void AddSolid (const G4Orb &)
 
virtual void AddSolid (const G4Para &)
 
virtual void AddSolid (const G4Sphere &)
 
virtual void AddSolid (const G4Torus &)
 
virtual void AddSolid (const G4Trap &)
 
virtual void AddSolid (const G4Trd &)
 
virtual void AddSolid (const G4Tubs &)
 
virtual void AddSolid (const G4Ellipsoid &)
 
virtual void AddSolid (const G4Polycone &)
 
virtual void AddSolid (const G4Polyhedra &)
 
virtual void AddSolid (const G4TessellatedSolid &)
 
virtual void AddSolid (const G4VSolid &)
 
virtual void AddCompound (const G4VTrajectory &)
 
virtual void AddCompound (const G4VHit &)
 
virtual void AddCompound (const G4VDigi &)
 
virtual void AddCompound (const G4THitsMap< G4double > &)
 
virtual void AddCompound (const G4THitsMap< G4StatDouble > &)
 
virtual void BeginModeling ()
 
virtual void EndModeling ()
 
virtual void BeginPrimitives (const G4Transform3D &objectTransformation=G4Transform3D())
 
virtual void EndPrimitives ()
 
virtual void BeginPrimitives2D (const G4Transform3D &objectTransformation=G4Transform3D())
 
virtual void EndPrimitives2D ()
 
virtual void AddPrimitive (const G4Polyline &)=0
 
virtual void AddPrimitive (const G4Scale &)
 
virtual void AddPrimitive (const G4Text &)=0
 
virtual void AddPrimitive (const G4Circle &)=0
 
virtual void AddPrimitive (const G4Square &)=0
 
virtual void AddPrimitive (const G4Polymarker &)
 
virtual void AddPrimitive (const G4Polyhedron &)=0
 
virtual const G4VisExtentGetExtent () const
 
const G4StringGetName () const
 
G4int GetSceneHandlerId () const
 
G4int GetViewCount () const
 
G4VGraphicsSystemGetGraphicsSystem () const
 
G4SceneGetScene () const
 
const G4ViewerListGetViewerList () const
 
G4VModelGetModel () const
 
G4VViewerGetCurrentViewer () const
 
G4bool GetMarkForClearingTransientStore () const
 
G4bool IsReadyForTransients () const
 
G4bool GetTransientsDrawnThisEvent () const
 
G4bool GetTransientsDrawnThisRun () const
 
const G4Transform3DGetObjectTransformation () const
 
void SetName (const G4String &)
 
void SetCurrentViewer (G4VViewer *)
 
virtual void SetScene (G4Scene *)
 
G4ViewerListSetViewerList ()
 
void SetModel (G4VModel *)
 
void SetMarkForClearingTransientStore (G4bool)
 
void SetTransientsDrawnThisEvent (G4bool)
 
void SetTransientsDrawnThisRun (G4bool)
 
void SetObjectTransformation (const G4Transform3D &)
 
const G4ColourGetColour ()
 
const G4ColourGetColor ()
 
const G4ColourGetTextColour (const G4Text &)
 
const G4ColourGetTextColor (const G4Text &)
 
G4double GetLineWidth (const G4VisAttributes *)
 
G4ViewParameters::DrawingStyle GetDrawingStyle (const G4VisAttributes *)
 
G4int GetNumberOfCloudPoints (const G4VisAttributes *) const
 
G4bool GetAuxEdgeVisible (const G4VisAttributes *)
 
G4int GetNoOfSides (const G4VisAttributes *)
 
G4double GetMarkerSize (const G4VMarker &, MarkerSizeType &)
 
G4double GetMarkerDiameter (const G4VMarker &, MarkerSizeType &)
 
G4double GetMarkerRadius (const G4VMarker &, MarkerSizeType &)
 
G4ModelingParametersCreateModelingParameters ()
 
void DrawEvent (const G4Event *)
 
void DrawEndOfRunModels ()
 
template<class T >
void AddSolidT (const T &solid)
 
template<class T >
void AddSolidWithAuxiliaryEdges (const T &solid)
 
G4int IncrementViewCount ()
 
virtual void ClearStore ()
 
virtual void ClearTransientStore ()
 
void AddViewerToList (G4VViewer *pView)
 
void RemoveViewerFromList (G4VViewer *pView)
 
- Public Member Functions inherited from G4VGraphicsScene
 G4VGraphicsScene ()
 
virtual ~G4VGraphicsScene ()
 
virtual void PreAddSolid (const G4Transform3D &objectTransformation, const G4VisAttributes &visAttribs)=0
 
virtual void PostAddSolid ()=0
 
virtual void AddSolid (const G4Box &)=0
 
virtual void AddSolid (const G4Cons &)=0
 
virtual void AddSolid (const G4Orb &)=0
 
virtual void AddSolid (const G4Para &)=0
 
virtual void AddSolid (const G4Sphere &)=0
 
virtual void AddSolid (const G4Torus &)=0
 
virtual void AddSolid (const G4Trap &)=0
 
virtual void AddSolid (const G4Trd &)=0
 
virtual void AddSolid (const G4Tubs &)=0
 
virtual void AddSolid (const G4Ellipsoid &)=0
 
virtual void AddSolid (const G4Polycone &)=0
 
virtual void AddSolid (const G4Polyhedra &)=0
 
virtual void AddSolid (const G4TessellatedSolid &)=0
 
virtual void AddSolid (const G4VSolid &)=0
 
virtual void AddCompound (const G4VTrajectory &)=0
 
virtual void AddCompound (const G4VHit &)=0
 
virtual void AddCompound (const G4VDigi &)=0
 
virtual void AddCompound (const G4THitsMap< G4double > &)=0
 
virtual void AddCompound (const G4THitsMap< G4StatDouble > &)=0
 
virtual void BeginPrimitives (const G4Transform3D &objectTransformation=G4Transform3D())=0
 
virtual void EndPrimitives ()=0
 
virtual void BeginPrimitives2D (const G4Transform3D &objectTransformation=G4Transform3D())=0
 
virtual void EndPrimitives2D ()=0
 
virtual void AddPrimitive (const G4Polyline &)=0
 
virtual void AddPrimitive (const G4Scale &)=0
 
virtual void AddPrimitive (const G4Text &)=0
 
virtual void AddPrimitive (const G4Circle &)=0
 
virtual void AddPrimitive (const G4Square &)=0
 
virtual void AddPrimitive (const G4Polymarker &)=0
 
virtual void AddPrimitive (const G4Polyhedron &)=0
 
virtual const G4VisExtentGetExtent () const
 

Additional Inherited Members

- Public Types inherited from G4VSceneHandler
enum  MarkerSizeType { world , screen }
 
- Protected Member Functions inherited from G4VSceneHandler
virtual void ProcessScene ()
 
virtual void RequestPrimitives (const G4VSolid &solid)
 
virtual G4DisplacedSolidCreateSectionSolid ()
 
virtual G4DisplacedSolidCreateCutawaySolid ()
 
void LoadAtts (const G4Visible &, G4AttHolder *)
 
- Protected Attributes inherited from G4VSceneHandler
G4VGraphicsSystemfSystem
 
const G4int fSceneHandlerId
 
G4String fName
 
G4int fViewCount
 
G4ViewerList fViewerList
 
G4VViewerfpViewer
 
G4ScenefpScene
 
G4bool fMarkForClearingTransientStore
 
G4bool fReadyForTransients
 
G4bool fTransientsDrawnThisEvent
 
G4bool fTransientsDrawnThisRun
 
G4bool fProcessingSolid
 
G4bool fProcessing2D
 
G4VModelfpModel
 
G4Transform3D fObjectTransformation
 
G4int fNestingDepth
 
const G4VisAttributesfpVisAttribs
 
const G4Transform3D fIdentityTransformation
 

Detailed Description

Author
Mark Donszelmann

Definition at line 63 of file G4HepRepSceneHandler.hh.

Constructor & Destructor Documentation

◆ G4HepRepSceneHandler()

G4HepRepSceneHandler::G4HepRepSceneHandler ( G4VGraphicsSystem system,
const G4String name = "" 
)

Definition at line 92 of file G4HepRepSceneHandler.cc.

93 : G4VSceneHandler (system, sceneIdCount++, name),
94 out (0),
95 geometryLayer ("Geometry"),
96 eventLayer ("Event"),
97 calHitLayer ("CalHit"),
98 trajectoryLayer ("Trajectory"),
99 hitLayer ("Hit"),
100 rootVolumeName ("Geometry"),
101 baseName (""),
102 eventNumberPrefix (""),
103 eventNumberSuffix (""),
104 eventNumber (1),
105 eventNumberWidth (-1),
106 extension (""),
107 writeBinary (false),
108 writeZip (false),
109 writeGZ (false),
110 writeMultipleFiles (false),
111 currentHit (NULL),
112 currentTrack (NULL),
113 _heprep (NULL),
114 _heprepGeometry (NULL)
115{
116
117#ifdef LDEBUG
118 cout << "G4HepRepSceneHandler::G4HepRepSceneHandler: " << system << endl;
119#endif
120
121 materialState[kStateSolid] = G4String("Solid");
122 materialState[kStateLiquid] = G4String("Liquid");
123 materialState[kStateGas] = G4String("Gas");
124 materialState[kStateUndefined] = G4String("Undefined");
125
126 factory = new XMLHepRepFactory();
127 writer = NULL;
128
129 // opening of file deferred to closeHepRep();
130 openHepRep();
131}
@ kStateSolid
Definition: G4Material.hh:111
@ kStateLiquid
Definition: G4Material.hh:111
@ kStateGas
Definition: G4Material.hh:111
@ kStateUndefined
Definition: G4Material.hh:111

◆ ~G4HepRepSceneHandler()

G4HepRepSceneHandler::~G4HepRepSceneHandler ( )
virtual

Definition at line 134 of file G4HepRepSceneHandler.cc.

134 {
135#ifdef LDEBUG
136 cout << "G4HepRepSceneHandler::~G4HepRepSceneHandler() " << endl;
137#endif
138 close();
139
140 delete factory;
141 factory = NULL;
142
143 G4HepRep* pHepRepSystem = dynamic_cast<G4HepRep*>(GetGraphicsSystem());
144 if (pHepRepSystem) pHepRepSystem->removeSceneHandler();
145}
void removeSceneHandler()
Definition: G4HepRep.cc:78
G4VGraphicsSystem * GetGraphicsSystem() const

Member Function Documentation

◆ AddCompound() [1/5]

void G4HepRepSceneHandler::AddCompound ( const G4THitsMap< G4double > &  hits)
inlinevirtual

Reimplemented from G4VSceneHandler.

Definition at line 89 of file G4HepRepSceneHandler.hh.

89 {
91 }
virtual void AddCompound(const G4VTrajectory &)

◆ AddCompound() [2/5]

void G4HepRepSceneHandler::AddCompound ( const G4THitsMap< G4StatDouble > &  hits)
inlinevirtual

Reimplemented from G4VSceneHandler.

Definition at line 92 of file G4HepRepSceneHandler.hh.

92 {
94 }

◆ AddCompound() [3/5]

void G4HepRepSceneHandler::AddCompound ( const G4VDigi digi)
inlinevirtual

Reimplemented from G4VSceneHandler.

Definition at line 86 of file G4HepRepSceneHandler.hh.

86 {
88 }

◆ AddCompound() [4/5]

void G4HepRepSceneHandler::AddCompound ( const G4VHit hit)
virtual

Reimplemented from G4VSceneHandler.

Definition at line 1017 of file G4HepRepSceneHandler.cc.

1017 {
1018#ifdef PDEBUG
1019 cout << "G4HepRepSceneHandler::AddCompound(G4VHit&) " << endl;
1020#endif
1021 if (dontWrite()) return;
1022
1023 currentHit = &hit;
1025 currentHit = NULL;
1026}

◆ AddCompound() [5/5]

void G4HepRepSceneHandler::AddCompound ( const G4VTrajectory trajectory)
virtual

Reimplemented from G4VSceneHandler.

Definition at line 1005 of file G4HepRepSceneHandler.cc.

1005 {
1006#ifdef PDEBUG
1007 cout << "G4HepRepSceneHandler::AddCompound(G4VTrajectory&) " << endl;
1008#endif
1009 if (dontWrite()) return;
1010
1011 currentTrack = &trajectory;
1012 G4VSceneHandler::AddCompound(trajectory);
1013 currentTrack = NULL;
1014}

◆ AddPrimitive() [1/7]

void G4HepRepSceneHandler::AddPrimitive ( const G4Circle circle)
virtual

Implements G4VSceneHandler.

Definition at line 844 of file G4HepRepSceneHandler.cc.

844 {
845#ifdef PDEBUG
846 cout << "G4HepRepSceneHandler::AddPrimitive(G4Circle&) " << endl;
847#endif
848 if (dontWrite()) return;
849
850 if (fProcessing2D) {
851 static G4bool warned = false;
852 if (!warned) {
853 warned = true;
855 ("G4HepRepSceneHandler::AddPrimitive (const G4Circle&)",
856 "vis-HepRep1003", JustWarning,
857 "2D circles not implemented. Ignored.");
858 }
859 return;
860 }
861
862 HepRepInstance* instance = factory->createHepRepInstance(getEventInstance(), getHitType());
863
864 addAttributes(instance, getHitType());
865
866 G4Point3D center = transform * circle.GetPosition();
867
869 setColor (instance, GetColor());
870
871 setVisibility(instance, circle);
872
873 setMarker(instance, circle);
874
875 factory->createHepRepPoint(instance, center.x(), center.y(), center.z());
876}
@ JustWarning
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *description)
Definition: G4Exception.cc:35
bool G4bool
Definition: G4Types.hh:86
G4Point3D GetPosition() const
const G4VisAttributes * fpVisAttribs
const G4Colour & GetColor()
const G4VisAttributes * GetVisAttributes() const
virtual HepRepInstance * createHepRepInstance(HepRepInstance *parent, HepRepType *type)=0
virtual HepRepPoint * createHepRepPoint(HepRepInstance *instance, double x, double y, double z)=0

◆ AddPrimitive() [2/7]

void G4HepRepSceneHandler::AddPrimitive ( const G4Polyhedron polyhedron)
virtual

Implements G4VSceneHandler.

Definition at line 879 of file G4HepRepSceneHandler.cc.

879 {
880
881#ifdef PDEBUG
882 cout << "G4HepRepSceneHandler::AddPrimitive(G4Polyhedron&) " << endl;
883#endif
884 if (dontWrite()) return;
885
886 if (fProcessing2D) {
887 static G4bool warned = false;
888 if (!warned) {
889 warned = true;
891 ("G4HepRepSceneHandler::AddPrimitive (const G4Polyhedron&)",
892 "vis-HepRep1004", JustWarning,
893 "2D polyhedra not implemented. Ignored.");
894 }
895 return;
896 }
897
898 G4Normal3D surfaceNormal;
899 G4Point3D vertex;
900
901 if (polyhedron.GetNoFacets()==0) return;
902
903 HepRepInstance* instance = getGeometryOrEventInstance(getCalHitType());
904
905 addAttributes(instance, getCalHitType());
906
907 setVisibility(instance, polyhedron);
908
909 G4int currentDepth = 0;
910 G4PhysicalVolumeModel* pPVModel =
911 dynamic_cast<G4PhysicalVolumeModel*>(fpModel);
912 if (pPVModel) currentDepth = pPVModel->GetCurrentDepth();
913
914 G4bool notLastFace;
915 do {
916 HepRepInstance* face;
917 if (isEventData()) {
918 face = factory->createHepRepInstance(instance, getCalHitFaceType());
919 } else {
920 face = getGeometryInstance("*Face", currentDepth+1);
921 setAttribute(face, "PickParent", true);
922 setAttribute(face, "DrawAs", G4String("Polygon"));
923 }
924
925 setLine(face, polyhedron);
926 fpVisAttribs = polyhedron.GetVisAttributes();
927 setColor(face, GetColor());
928 if (isEventData()) setColor(face, GetColor(), G4String("FillColor"));
929
930 notLastFace = polyhedron.GetNextNormal (surfaceNormal);
931
932 G4int edgeFlag = 1;
933 G4bool notLastEdge;
934 do {
935 notLastEdge = polyhedron.GetNextVertex (vertex, edgeFlag);
936 vertex = transform * vertex;
937 factory->createHepRepPoint(face, vertex.x(), vertex.y(), vertex.z());
938 } while (notLastEdge);
939 } while (notLastFace);
940}
int G4int
Definition: G4Types.hh:85
G4bool GetNextNormal(G4Normal3D &normal) const
G4bool GetNextVertex(G4Point3D &vertex, G4int &edgeFlag) const
G4int GetNoFacets() const

◆ AddPrimitive() [3/7]

void G4HepRepSceneHandler::AddPrimitive ( const G4Polyline line)
virtual

Implements G4VSceneHandler.

Definition at line 755 of file G4HepRepSceneHandler.cc.

755 {
756
757#ifdef PDEBUG
758 cout << "G4HepRepSceneHandler::AddPrimitive(G4Polyline&) " << line.size() << endl;
759#endif
760 if (dontWrite()) return;
761
762 if (fProcessing2D) {
763 static G4bool warned = false;
764 if (!warned) {
765 warned = true;
767 ("G4HepRepSceneHandler::AddPrimitive (const G4Polyline&)",
768 "vis-HepRep1001", JustWarning,
769 "2D polylines not implemented. Ignored.");
770 }
771 return;
772 }
773
774 HepRepInstance* instance = factory->createHepRepInstance(getEventInstance(), getTrajectoryType());
775
776 addAttributes(instance, getTrajectoryType());
777
779 setColor(instance, GetColor());
780
781 setVisibility(instance, line);
782
783 setLine(instance, line);
784
785 for (size_t i=0; i < line.size(); i++) {
786 G4Point3D vertex = transform * line[i];
787 factory->createHepRepPoint(instance, vertex.x(), vertex.y(), vertex.z());
788 }
789}

◆ AddPrimitive() [4/7]

void G4HepRepSceneHandler::AddPrimitive ( const G4Polymarker line)
virtual

Reimplemented from G4VSceneHandler.

Definition at line 792 of file G4HepRepSceneHandler.cc.

792 {
793
794#ifdef PDEBUG
795 cout << "G4HepRepSceneHandler::AddPrimitive(G4Polymarker&) " << line.size() << endl;
796#endif
797 if (dontWrite()) return;
798
799 if (fProcessing2D) {
800 static G4bool warned = false;
801 if (!warned) {
802 warned = true;
804 ("G4HepRepSceneHandler::AddPrimitive (const G4Polymarker&)",
805 "vis-HepRep1002", JustWarning,
806 "2D polymarkers not implemented. Ignored.");
807 }
808 return;
809 }
810
811 HepRepInstance* instance = factory->createHepRepInstance(getEventInstance(), getHitType());
812
813 addAttributes(instance, getHitType());
814
816 setColor(instance, GetColor());
817
818 setVisibility(instance, line);
819
820 setMarker(instance, line);
821
822 // Default MarkName is set to Circle for this Type.
823 int mtype = line.GetMarkerType();
824
825 // Cannot be case statement since line.xxx is not a constant
826 if (mtype == line.dots) {
827 setAttribute(instance, "Fill", true);
828 setColor(instance, GetColor(), G4String("FillColor"));
829 } else if (mtype == line.circles) {
830 } else if (mtype == line.squares) {
831 setAttribute(instance, "MarkName", G4String("Box"));
832 } else {
833 // line.line + default
834 setAttribute(instance, "MarkName", G4String("Plus"));
835 }
836
837 for (size_t i=0; i < line.size(); i++) {
838 G4Point3D vertex = transform * line[i];
839 factory->createHepRepPoint(instance, vertex.x(), vertex.y(), vertex.z());
840 }
841}
MarkerType GetMarkerType() const

◆ AddPrimitive() [5/7]

void G4HepRepSceneHandler::AddPrimitive ( const G4Scale scale)
virtual

Reimplemented from G4VSceneHandler.

Definition at line 1000 of file G4HepRepSceneHandler.cc.

1000 {
1001 if (dontWrite()) return;
1003}
virtual void AddPrimitive(const G4Polyline &)=0

◆ AddPrimitive() [6/7]

void G4HepRepSceneHandler::AddPrimitive ( const G4Square square)
virtual

Implements G4VSceneHandler.

Definition at line 967 of file G4HepRepSceneHandler.cc.

967 {
968#ifdef PDEBUG
969 cout << "G4HepRepSceneHandler::AddPrimitive(G4Square&) " << endl;
970#endif
971 if (dontWrite()) return;
972
973 if (fProcessing2D) {
974 static G4bool warned = false;
975 if (!warned) {
976 warned = true;
978 ("G4HepRepSceneHandler::AddPrimitive (const G4Square&)",
979 "vis-HepRep1006", JustWarning,
980 "2D squares not implemented. Ignored.");
981 }
982 return;
983 }
984
985 HepRepInstance* instance = factory->createHepRepInstance(getEventInstance(), getHitType());
986
987 addAttributes(instance, getHitType());
988
989 G4Point3D center = transform * square.GetPosition();
990
991 setColor (instance, getColorFor(square));
992
993 setVisibility(instance, square);
994
995 setMarker(instance, square);
996
997 factory->createHepRepPoint(instance, center.x(), center.y(), center.z());
998}

◆ AddPrimitive() [7/7]

void G4HepRepSceneHandler::AddPrimitive ( const G4Text )
virtual

Implements G4VSceneHandler.

Definition at line 943 of file G4HepRepSceneHandler.cc.

943 {
944#ifdef PDEBUG
945 cout << "G4HepRepSceneHandler::AddPrimitive(G4Text&) " << endl;
946#endif
947 if (dontWrite()) return;
948
949 /*** You may need this
950 if (fProcessing2D) {
951 static G4bool warned = false;
952 if (!warned) {
953 warned = true;
954 G4Exception
955 ("G4HepRepSceneHandler::AddPrimitive (const G4Text&)",
956 "vis-HepRep1005", JustWarning,
957 "2D text not implemented. Ignored.");
958 }
959 return;
960 }
961 ***/
962
963 cout << "G4HepRepSceneHandler::AddPrimitive G4Text : not yet implemented. " << endl;
964}

◆ AddSolid() [1/14]

void G4HepRepSceneHandler::AddSolid ( const G4Box box)
virtual

Reimplemented from G4VSceneHandler.

Definition at line 467 of file G4HepRepSceneHandler.cc.

467 {
468#ifdef SDEBUG
469 cout << "G4HepRepSceneHandler::AddSolid(const G4Box& box)" << endl;
470#endif
471
472 if (dontWrite()) return;
473
475
476 if (! messenger->useSolids()) {
478 return;
479 }
480
481 G4double dx = box.GetXHalfLength();
482 G4double dy = box.GetYHalfLength();
483 G4double dz = box.GetZHalfLength();
484
485 G4Point3D vertex1(G4Point3D( dx, dy,-dz));
486 G4Point3D vertex2(G4Point3D( dx,-dy,-dz));
487 G4Point3D vertex3(G4Point3D(-dx,-dy,-dz));
488 G4Point3D vertex4(G4Point3D(-dx, dy,-dz));
489 G4Point3D vertex5(G4Point3D( dx, dy, dz));
490 G4Point3D vertex6(G4Point3D( dx,-dy, dz));
491 G4Point3D vertex7(G4Point3D(-dx,-dy, dz));
492 G4Point3D vertex8(G4Point3D(-dx, dy, dz));
493
494 vertex1 = (transform) * vertex1;
495 vertex2 = (transform) * vertex2;
496 vertex3 = (transform) * vertex3;
497 vertex4 = (transform) * vertex4;
498 vertex5 = (transform) * vertex5;
499 vertex6 = (transform) * vertex6;
500 vertex7 = (transform) * vertex7;
501 vertex8 = (transform) * vertex8;
502
503 HepRepInstance* instance = getGeometryOrEventInstance(getCalHitType());
504 addAttributes(instance, getCalHitType());
505
506 setAttribute(instance, "DrawAs", G4String("Prism"));
507
508 setVisibility(instance, box);
509 setLine(instance, box);
510 setColor(instance, getColorFor(box));
511
512 factory->createHepRepPoint(instance, vertex1.x(), vertex1.y(), vertex1.z());
513 factory->createHepRepPoint(instance, vertex2.x(), vertex2.y(), vertex2.z());
514 factory->createHepRepPoint(instance, vertex3.x(), vertex3.y(), vertex3.z());
515 factory->createHepRepPoint(instance, vertex4.x(), vertex4.y(), vertex4.z());
516 factory->createHepRepPoint(instance, vertex5.x(), vertex5.y(), vertex5.z());
517 factory->createHepRepPoint(instance, vertex6.x(), vertex6.y(), vertex6.z());
518 factory->createHepRepPoint(instance, vertex7.x(), vertex7.y(), vertex7.z());
519 factory->createHepRepPoint(instance, vertex8.x(), vertex8.y(), vertex8.z());
520}
HepGeom::Point3D< G4double > G4Point3D
Definition: G4Point3D.hh:34
double G4double
Definition: G4Types.hh:83
G4double GetYHalfLength() const
G4double GetZHalfLength() const
G4double GetXHalfLength() const
virtual G4bool useSolids()
static G4HepRepMessenger * GetInstance()
virtual void AddSolid(const G4Box &)

◆ AddSolid() [2/14]

void G4HepRepSceneHandler::AddSolid ( const G4Cons cons)
virtual

Reimplemented from G4VSceneHandler.

Definition at line 523 of file G4HepRepSceneHandler.cc.

523 {
524#ifdef SDEBUG
525 cout << "G4HepRepSceneHandler::AddSolid(const G4Cons& cons)" << endl;
526#endif
527
528 if (dontWrite()) return;
529
531
532 if (! messenger->useSolids() || (cons.GetDeltaPhiAngle() < twopi)) {
534 return;
535 }
536
537 G4PhysicalVolumeModel* pPVModel =
538 dynamic_cast<G4PhysicalVolumeModel*>(fpModel);
539 if (!pPVModel) {
541 return;
542 }
543
544 G4LogicalVolume* pCurrentLV = pPVModel->GetCurrentLV();
545 G4int currentDepth = pPVModel->GetCurrentDepth();
546 G4Material* pCurrentMaterial = pPVModel->GetCurrentMaterial();
547
548 G4Point3D vertex1(G4Point3D( 0., 0., cons.GetZHalfLength()));
549 G4Point3D vertex2(G4Point3D( 0., 0.,-cons.GetZHalfLength()));
550
551 vertex1 = (transform) * vertex1;
552 vertex2 = (transform) * vertex2;
553
554 HepRepInstance* instance = getGeometryInstance(pCurrentLV, pCurrentMaterial, currentDepth);
555 setAttribute(instance, "DrawAs", G4String("Cylinder"));
556
557 setVisibility(instance, cons);
558 setLine(instance, cons);
559 setColor(instance, getColorFor(cons));
560
561 HepRepType* type = getGeometryType(pCurrentLV->GetName(), currentDepth);
562
563 // Outer cylinder.
564 HepRepInstance* outer = factory->createHepRepInstance(instance, type);
565 outer->addAttValue("pickParent",true);
566 outer->addAttValue("showParentAttributes",true);
567
568 HepRepPoint* op1 = factory->createHepRepPoint(outer, vertex1.x(), vertex1.y(), vertex1.z());
569 op1->addAttValue("Radius",cons.GetOuterRadiusPlusZ());
570
571 HepRepPoint* op2 = factory->createHepRepPoint(outer, vertex2.x(), vertex2.y(), vertex2.z());
572 op2->addAttValue("Radius",cons.GetOuterRadiusMinusZ());
573
574 // Inner cylinder.
575 HepRepInstance* inner = factory->createHepRepInstance(instance, type);
576 inner->addAttValue("pickParent",true);
577 inner->addAttValue("showParentAttributes",true);
578
579 HepRepPoint* ip1 = factory->createHepRepPoint(inner, vertex1.x(), vertex1.y(), vertex1.z());
580 ip1->addAttValue("Radius",cons.GetInnerRadiusPlusZ());
581
582 HepRepPoint* ip2 = factory->createHepRepPoint(inner, vertex2.x(), vertex2.y(), vertex2.z());
583 ip2->addAttValue("Radius",cons.GetInnerRadiusMinusZ());
584}
G4double GetOuterRadiusPlusZ() const
G4double GetDeltaPhiAngle() const
G4double GetInnerRadiusMinusZ() const
G4double GetInnerRadiusPlusZ() const
G4double GetOuterRadiusMinusZ() const
G4double GetZHalfLength() const
const G4String & GetName() const
G4LogicalVolume * GetCurrentLV() const
G4Material * GetCurrentMaterial() const
virtual void addAttValue(HepRepAttValue *attValue)=0

◆ AddSolid() [3/14]

void G4HepRepSceneHandler::AddSolid ( const G4Ellipsoid ellipsoid)
virtual

Reimplemented from G4VSceneHandler.

Definition at line 739 of file G4HepRepSceneHandler.cc.

739 {
740 if (dontWrite()) return;
741 G4VSceneHandler::AddSolid (ellipsoid);
742}

◆ AddSolid() [4/14]

void G4HepRepSceneHandler::AddSolid ( const G4Orb orb)
virtual

Reimplemented from G4VSceneHandler.

Definition at line 734 of file G4HepRepSceneHandler.cc.

734 {
735 if (dontWrite()) return;
737}

◆ AddSolid() [5/14]

void G4HepRepSceneHandler::AddSolid ( const G4Para para)
virtual

Reimplemented from G4VSceneHandler.

Definition at line 714 of file G4HepRepSceneHandler.cc.

714 {
715 if (dontWrite()) return;
717}

◆ AddSolid() [6/14]

void G4HepRepSceneHandler::AddSolid ( const G4Polycone polycone)
virtual

Reimplemented from G4VSceneHandler.

Definition at line 724 of file G4HepRepSceneHandler.cc.

724 {
725 if (dontWrite()) return;
726 G4VSceneHandler::AddSolid (polycone);
727}

◆ AddSolid() [7/14]

void G4HepRepSceneHandler::AddSolid ( const G4Polyhedra polyhedra)
virtual

Reimplemented from G4VSceneHandler.

Definition at line 729 of file G4HepRepSceneHandler.cc.

729 {
730 if (dontWrite()) return;
731 G4VSceneHandler::AddSolid (polyhedra);
732}

◆ AddSolid() [8/14]

void G4HepRepSceneHandler::AddSolid ( const G4Sphere sphere)
virtual

Reimplemented from G4VSceneHandler.

Definition at line 709 of file G4HepRepSceneHandler.cc.

709 {
710 if (dontWrite()) return;
712}

◆ AddSolid() [9/14]

void G4HepRepSceneHandler::AddSolid ( const G4TessellatedSolid tess)
virtual

Reimplemented from G4VSceneHandler.

Definition at line 744 of file G4HepRepSceneHandler.cc.

744 {
745 if (dontWrite()) return;
747}

◆ AddSolid() [10/14]

void G4HepRepSceneHandler::AddSolid ( const G4Torus torus)
virtual

Reimplemented from G4VSceneHandler.

Definition at line 719 of file G4HepRepSceneHandler.cc.

719 {
720 if (dontWrite()) return;
722}

◆ AddSolid() [11/14]

void G4HepRepSceneHandler::AddSolid ( const G4Trap trap)
virtual

Reimplemented from G4VSceneHandler.

Definition at line 704 of file G4HepRepSceneHandler.cc.

704 {
705 if (dontWrite()) return;
707}

◆ AddSolid() [12/14]

void G4HepRepSceneHandler::AddSolid ( const G4Trd trd)
virtual

Reimplemented from G4VSceneHandler.

Definition at line 647 of file G4HepRepSceneHandler.cc.

647 {
648#ifdef SDEBUG
649 cout << "G4HepRepSceneHandler::AddSolid(const G4Trd& trd)" << endl;
650#endif
651 if (dontWrite()) return;
652
654
655 if (! messenger->useSolids()) {
657 return;
658 }
659
660 G4double dx1 = trd.GetXHalfLength1();
661 G4double dy1 = trd.GetYHalfLength1();
662 G4double dx2 = trd.GetXHalfLength2();
663 G4double dy2 = trd.GetYHalfLength2();
664 G4double dz = trd.GetZHalfLength();
665
666 G4Point3D vertex1(G4Point3D( dx1, dy1,-dz));
667 G4Point3D vertex2(G4Point3D( dx1,-dy1,-dz));
668 G4Point3D vertex3(G4Point3D(-dx1,-dy1,-dz));
669 G4Point3D vertex4(G4Point3D(-dx1, dy1,-dz));
670 G4Point3D vertex5(G4Point3D( dx2, dy2, dz));
671 G4Point3D vertex6(G4Point3D( dx2,-dy2, dz));
672 G4Point3D vertex7(G4Point3D(-dx2,-dy2, dz));
673 G4Point3D vertex8(G4Point3D(-dx2, dy2, dz));
674
675 vertex1 = (transform) * vertex1;
676 vertex2 = (transform) * vertex2;
677 vertex3 = (transform) * vertex3;
678 vertex4 = (transform) * vertex4;
679 vertex5 = (transform) * vertex5;
680 vertex6 = (transform) * vertex6;
681 vertex7 = (transform) * vertex7;
682 vertex8 = (transform) * vertex8;
683
684 HepRepInstance* instance = getGeometryOrEventInstance(getCalHitType());
685
686 addAttributes(instance, getCalHitType());
687
688 setAttribute(instance, "DrawAs", G4String("Prism"));
689
690 setVisibility(instance, trd);
691 setLine(instance, trd);
692 setColor(instance, getColorFor(trd));
693
694 factory->createHepRepPoint(instance, vertex1.x(), vertex1.y(), vertex1.z());
695 factory->createHepRepPoint(instance, vertex2.x(), vertex2.y(), vertex2.z());
696 factory->createHepRepPoint(instance, vertex3.x(), vertex3.y(), vertex3.z());
697 factory->createHepRepPoint(instance, vertex4.x(), vertex4.y(), vertex4.z());
698 factory->createHepRepPoint(instance, vertex5.x(), vertex5.y(), vertex5.z());
699 factory->createHepRepPoint(instance, vertex6.x(), vertex6.y(), vertex6.z());
700 factory->createHepRepPoint(instance, vertex7.x(), vertex7.y(), vertex7.z());
701 factory->createHepRepPoint(instance, vertex8.x(), vertex8.y(), vertex8.z());
702}
G4double GetXHalfLength2() const
G4double GetYHalfLength2() const
G4double GetXHalfLength1() const
G4double GetYHalfLength1() const
G4double GetZHalfLength() const

◆ AddSolid() [13/14]

void G4HepRepSceneHandler::AddSolid ( const G4Tubs tubs)
virtual

Reimplemented from G4VSceneHandler.

Definition at line 587 of file G4HepRepSceneHandler.cc.

587 {
588#ifdef SDEBUG
589 cout << "G4HepRepSceneHandler::AddSolid(const G4Tubs& tubs)" << endl;
590#endif
591
592 if (dontWrite()) return;
593
595
596 if (! messenger->useSolids() || (tubs.GetDeltaPhiAngle() < twopi)) {
598 return;
599 }
600
601 G4PhysicalVolumeModel* pPVModel =
602 dynamic_cast<G4PhysicalVolumeModel*>(fpModel);
603 if (!pPVModel) {
605 return;
606 }
607
608 G4LogicalVolume* pCurrentLV = pPVModel->GetCurrentLV();
609 G4int currentDepth = pPVModel->GetCurrentDepth();
610 G4Material* pCurrentMaterial = pPVModel->GetCurrentMaterial();
611
612 G4Point3D vertex1(G4Point3D( 0., 0., tubs.GetZHalfLength()));
613 G4Point3D vertex2(G4Point3D( 0., 0.,-tubs.GetZHalfLength()));
614
615 vertex1 = (transform) * vertex1;
616 vertex2 = (transform) * vertex2;
617
618 HepRepInstance* instance = getGeometryInstance(pCurrentLV, pCurrentMaterial, currentDepth);
619 setAttribute(instance, "DrawAs", G4String("Cylinder"));
620
621 setVisibility(instance, tubs);
622 setLine(instance, tubs);
623 setColor(instance, getColorFor(tubs));
624
625 HepRepType* type = getGeometryType(pCurrentLV->GetName(), currentDepth);
626
627 // Outer cylinder.
628 HepRepInstance* outer = factory->createHepRepInstance(instance, type);
629 outer->addAttValue("Radius",tubs.GetOuterRadius());
630 outer->addAttValue("pickParent",true);
631 outer->addAttValue("showParentAttributes",true);
632 factory->createHepRepPoint(outer, vertex1.x(), vertex1.y(), vertex1.z());
633 factory->createHepRepPoint(outer, vertex2.x(), vertex2.y(), vertex2.z());
634
635 // Inner cylinder.
636 if (tubs.GetInnerRadius() > 0.) {
637 HepRepInstance* inner = factory->createHepRepInstance(instance, type);
638 inner->addAttValue("Radius",tubs.GetInnerRadius());
639 inner->addAttValue("pickParent",true);
640 inner->addAttValue("showParentAttributes",true);
641 factory->createHepRepPoint(inner, vertex1.x(), vertex1.y(), vertex1.z());
642 factory->createHepRepPoint(inner, vertex2.x(), vertex2.y(), vertex2.z());
643 }
644}
G4double GetZHalfLength() const
G4double GetInnerRadius() const
G4double GetOuterRadius() const
G4double GetDeltaPhiAngle() const

◆ AddSolid() [14/14]

void G4HepRepSceneHandler::AddSolid ( const G4VSolid solid)
virtual

Reimplemented from G4VSceneHandler.

Definition at line 749 of file G4HepRepSceneHandler.cc.

749 {
750 if (dontWrite()) return;
752}

◆ BeginModeling()

void G4HepRepSceneHandler::BeginModeling ( )
virtual

Reimplemented from G4VSceneHandler.

Definition at line 452 of file G4HepRepSceneHandler.cc.

452 {
453#ifdef SDEBUG
454 cout << "G4HepRepSceneHandler::BeginModeling() " << endl;
455#endif
457}
virtual void BeginModeling()

◆ BeginPrimitives()

void G4HepRepSceneHandler::BeginPrimitives ( const G4Transform3D objectTransformation)
virtual

Reimplemented from G4VSceneHandler.

Definition at line 1048 of file G4HepRepSceneHandler.cc.

1048 {
1049#ifdef SDEBUG
1050 cout << "G4HepRepSceneHandler::BeginPrimitives(G4Transform3D&)" << endl;
1051#endif
1052
1053 G4VSceneHandler::BeginPrimitives (objectTransformation);
1054 transform = objectTransformation;
1055}
virtual void BeginPrimitives(const G4Transform3D &objectTransformation=G4Transform3D())

◆ closeFile()

void G4HepRepSceneHandler::closeFile ( )

Definition at line 434 of file G4HepRepSceneHandler.cc.

434 {
435 writer->close();
436 delete writer;
437 writer = NULL;
438
439 delete out;
440 out = NULL;
441}
virtual bool close()=0

Referenced by closeHepRep().

◆ closeHepRep()

bool G4HepRepSceneHandler::closeHepRep ( bool  final = false)

Returns true if the HepRep was (already) closed, false if the HepRep is still open

Definition at line 294 of file G4HepRepSceneHandler.cc.

294 {
295 if (_heprep == NULL) return true;
296
297#ifdef LDEBUG
298 cout << "G4HepRepSceneHandler::CloseHepRep() start" << endl;
299#endif
300
301 // if this is the final close, then there should not be any event pending to be written.
302 if (final) {
303 if (_eventInstanceTree != NULL) {
304 cerr << "WARNING: you probably used '/vis/viewer/endOfEventAction accumulate' and "
305 << "forgot to call /vis/viewer/update before exit. No event written." << endl;
306 }
307 } else {
308
310
311 // add geometry to the heprep if there is an event (separate geometries are written
312 // using DrawView() called from /vis/viewer/flush)
313 if (_eventInstanceTree != NULL) {
315
316 // couple geometry
317
318 if ( messenger->appendGeometry()) {
319 // couple geometry to event if geometry was written
320 if ((_geometryInstanceTree != NULL)) {
321 getEventInstanceTree()->addInstanceTree(getGeometryInstanceTree());
322 }
323 } else {
324 char name[128];
325 if (writeMultipleFiles) {
326 sprintf(name, "%s%s%s#%s", baseName.c_str(), "-geometry", extension.c_str(), "G4GeometryData");
327 } else {
328 sprintf(name, "%s%s#%s", "geometry", (writeBinary ? ".bheprep" : ".heprep"), "G4GeometryData");
329 }
330 getEventInstanceTree()->addInstanceTree(factory->createHepRepTreeID(name, "1.0"));
331 }
332 }
333
334 // force inclusion of all subtypes of event
335 if (_eventInstanceTree != NULL) {
336 getEventType();
337 getTrajectoryType();
338 getHitType();
339 getCalHitType();
340 getCalHitFaceType();
341 }
342
343 // Give this HepRep all of the layer order info for both geometry and event,
344 // since these will both end up in a single HepRep.
345 writeLayers(_heprepGeometry);
346 writeLayers(_heprep);
347
348 // open heprep file
349 if (writer == NULL) {
350 open((GetScene() == NULL) ? G4String("G4HepRepOutput.heprep.zip") : GetScene()->GetName());
351 }
352
353 // write out separate geometry
354 if (! messenger->appendGeometry() && (_heprepGeometry != NULL)) {
355 if (writeMultipleFiles) {
356 char fileName[128];
357 sprintf(fileName, "%s%s%s", baseName.c_str(), "-geometry", extension.c_str());
358 openFile(G4String(fileName));
359 }
360
361 char name[128];
362 sprintf(name, "%s%s", "geometry", (writeBinary ? ".bheprep" : ".heprep"));
363 if (!writeMultipleFiles) {
364 writer->addProperty("RecordLoop.ignore", name);
365 }
366
367 writer->write(_heprepGeometry, G4String(name));
368
369 delete _heprepGeometry;
370 _heprepGeometry = NULL;
371
372 if (writeMultipleFiles) closeFile();
373 }
374
375 if (writeMultipleFiles) {
376// NOTE: does not work on Solaris 5.2 and Linux 2.95.2
377// stringstream fileName;
378// fileName << baseName << eventNumberPrefix << setw(eventNumberWidth) << setfill('0') << eventNumber << eventNumberSuffix << extension;
379// openFile(fileName.str());
380// Use instead:
381 char fileName[128];
382 char fileFormat[128];
383 sprintf(fileFormat, "%s%d%s", "%s%s%0", eventNumberWidth, "d%s%s");
384 sprintf(fileName, fileFormat, baseName.c_str(), eventNumberPrefix.c_str(), eventNumber, eventNumberSuffix.c_str(), extension.c_str());
385 openFile(G4String(fileName));
386 }
387
388 // write out the heprep
389// NOTE: does not work on Solaris 5.2 and Linux 2.95.2
390// stringstream eventName;
391// eventName << "event-" << setw(eventNumberWidth) << setfill('0') << eventNumber << (writeBinary ? ".bheprep" : ".heprep");
392// writer->write(_heprep, eventName.str());
393// Use instead:
394 char eventName[128];
395 char eventFormat[128];
396 sprintf(eventFormat, "%s%d%s%s", "event-%0", eventNumberWidth, "d", (writeBinary ? ".bheprep" : ".heprep"));
397 sprintf(eventName, eventFormat, eventNumber);
398 if (writer) writer->write(_heprep, G4String(eventName));
399
400 eventNumber++;
401 }
402
403 delete _heprep;
404 _heprep = NULL;
405
406 if (writeMultipleFiles) closeFile();
407
408 return true;
409}
virtual G4bool appendGeometry()
void openFile(G4String name)
G4Scene * GetScene() const
G4VViewer * GetCurrentViewer() const
const G4String & GetName() const
virtual void DrawView()=0
virtual HepRepTreeID * createHepRepTreeID(std::string name, std::string version, std::string qualifier="top-level")=0
virtual void addInstanceTree(HepRepTreeID *instanceTree)=0
virtual bool addProperty(std::string key, std::string value)=0
virtual bool write(HepRep *heprep, std::string name)=0
const char * name(G4int ptype)

Referenced by G4HepRepViewer::ShowView().

◆ EndModeling()

void G4HepRepSceneHandler::EndModeling ( )
virtual

Reimplemented from G4VSceneHandler.

Definition at line 460 of file G4HepRepSceneHandler.cc.

460 {
461#ifdef SDEBUG
462 cout << "G4HepRepSceneHandler::EndModeling() " << endl;
463#endif
465}
virtual void EndModeling()

◆ EndPrimitives()

void G4HepRepSceneHandler::EndPrimitives ( )
virtual

Reimplemented from G4VSceneHandler.

Definition at line 1058 of file G4HepRepSceneHandler.cc.

1058 {
1059#ifdef SDEBUG
1060 cout << "G4HepRepSceneHandler::EndPrimitives" << endl;
1061#endif
1063}
virtual void EndPrimitives()

◆ openFile()

void G4HepRepSceneHandler::openFile ( G4String  name)

Definition at line 429 of file G4HepRepSceneHandler.cc.

429 {
430 out = new ofstream(name.c_str(), std::ios::out | std::ios::binary );
431 writer = factory->createHepRepWriter(out, writeZip, writeZip || writeGZ);
432}
virtual HepRepWriter * createHepRepWriter(std::ostream *out, bool randomAccess, bool compress)=0

Referenced by closeHepRep().

◆ openHepRep()

void G4HepRepSceneHandler::openHepRep ( )

Definition at line 264 of file G4HepRepSceneHandler.cc.

264 {
265#ifdef LDEBUG
266 cout << "G4HepRepSceneHandler::OpenHepRep() " << endl;
267#endif
268
269 if (_heprep != NULL) return;
270
271 // all done on demand, once pointers are set to NULL
272 _heprepGeometry = NULL;
273 _geometryInstanceTree = NULL;
274 _geometryRootInstance = NULL;
275 _geometryInstance.clear();
276 _geometryTypeTree = NULL;
277 _geometryRootType = NULL;
278 _geometryTypeName.clear();
279 _geometryType.clear();
280 _eventInstanceTree = NULL;
281 _eventInstance = NULL;
282 _eventTypeTree = NULL;
283 _eventType = NULL;
284 _trajectoryType = NULL;
285 _hitType = NULL;
286 _calHitType = NULL;
287 _calHitFaceType = NULL;
288}

Referenced by G4HepRepSceneHandler(), and G4HepRepViewer::ShowView().

◆ PostAddSolid()

void G4HepRepSceneHandler::PostAddSolid ( )
virtual

Reimplemented from G4VSceneHandler.

Definition at line 1040 of file G4HepRepSceneHandler.cc.

1040 {
1041#ifdef SDEBUG
1042 cout << "G4HepRepSceneHandler::PostAddSolid()" << endl;
1043#endif
1045}
virtual void PostAddSolid()

◆ PreAddSolid()

void G4HepRepSceneHandler::PreAddSolid ( const G4Transform3D objectTransformation,
const G4VisAttributes visAttribs 
)
virtual

Reimplemented from G4VSceneHandler.

Definition at line 1028 of file G4HepRepSceneHandler.cc.

1029 {
1030
1031 G4VSceneHandler::PreAddSolid (objectTransformation, visAttribs);
1032
1033 transform = objectTransformation;
1034#ifdef SDEBUG
1035 cout << "G4HepRepSceneHandler::PreAddSolid(G4Transform3D&, G4VisAttributes&)" << endl;
1036#endif
1037}
virtual void PreAddSolid(const G4Transform3D &objectTransformation, const G4VisAttributes &)

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