Changeset 688 for trunk/geant4/visualization
- Timestamp:
- Jan 15, 2008, 2:19:33 PM (17 years ago)
- Location:
- trunk/geant4/visualization
- Files:
-
- 23 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/geant4/visualization/History
r631 r688 1 $Id: History,v 1.41 8 2007/11/19 19:56:26 perlExp $1 $Id: History,v 1.419 2008/01/04 22:17:08 allison Exp $ 2 2 ------------------------------------------------------------------- 3 3 … … 24 24 History file for visualization category 25 25 --------------------------------------- 26 27 4th January 2008 John Allison (vis-V09-01-00 with greps-V09-01-00) 28 - Draw2D capability, already available for G4Text, extended to: 29 G4Circle, G4Polyhedron, G4Polyline, G4Polymarker, G4Square. 30 o modeling-V09-01-00: Adapted to new BeginPrimitives2D signature. 31 o visman-V09-01-00: Implemented extended 2D interface. 32 o opengl-V09-01-00: Implemented extended 2D interface. 33 o vis-HepRep-V09-01-00: Adapted to new BeginPrimitives2D signature. 34 o vistest-V09-01-00: MyEventAction: Added 2D polyhedron. 26 35 27 36 19th November 2007 Joseph Perl (vis-V09-00-03) -
trunk/geant4/visualization/OpenGL/GNUmakefile
r668 r688 1 # $Id: GNUmakefile,v 1. 6 2004/06/03 11:40:13 gcosmoExp $1 # $Id: GNUmakefile,v 1.7 2008/01/15 11:05:08 lgarnier Exp $ 2 2 3 3 name := G4OpenGL -
trunk/geant4/visualization/OpenGL/History
r632 r688 1 $Id: History,v 1.10 4 2007/11/30 14:47:30lgarnier Exp $1 $Id: History,v 1.106 2008/01/15 11:05:08 lgarnier Exp $ 2 2 ------------------------------------------------------------------- 3 3 … … 20 20 History file for visualization/OpenGL 21 21 ------------------------------------- 22 23 15th Janvier 2007, Laurent Garnier 24 - Fixed some layout problems on export dialog box 25 - Some improvements on exports formats 26 - Fix a bug in the help command : The clic callback on a item was not 27 working on windows 28 - Fix a crash at exit when launched on a MAC. 29 - EPS export format is now ready for Qt3 30 - Add Vectoriel EPS export format 31 - Fix an aspect ratio deformation when resize the widget 32 - Fix a crash at launch with leopard 33 - When selecting the "move" mouse action, this action was set even when 34 mouse button was released. Fixed : Now we should clic to have the move action 35 - GNUmakefile : Added a macro for moc file 36 - Moc files : Suppression of all theses files. They are now autogenerated 37 thanks to config/common.gmk 38 39 4th January 2008 John Allison (opengl-V09-01-00) 40 - Implemented extended 2D interface. 22 41 23 42 30th November 2007 Laurent Garnier -
trunk/geant4/visualization/OpenGL/include/G4OpenGLImmediateSceneHandler.hh
r631 r688 25 25 // 26 26 // 27 // $Id: G4OpenGLImmediateSceneHandler.hh,v 1.1 3 2007/04/04 16:50:26allison Exp $27 // $Id: G4OpenGLImmediateSceneHandler.hh,v 1.14 2008/01/04 22:07:01 allison Exp $ 28 28 // GEANT4 tag $Name: $ 29 29 // … … 54 54 void BeginPrimitives (const G4Transform3D& objectTransformation); 55 55 void EndPrimitives (); 56 void BeginPrimitives2D ( );56 void BeginPrimitives2D (const G4Transform3D& objectTransformation); 57 57 void EndPrimitives2D (); 58 58 void BeginModeling (); -
trunk/geant4/visualization/OpenGL/include/G4OpenGLQtExportDialog.hh
r657 r688 25 25 // 26 26 // 27 // $Id: G4OpenGLQtExportDialog.hh,v 1. 3 2007/11/09 15:03:21lgarnier Exp $27 // $Id: G4OpenGLQtExportDialog.hh,v 1.4 2008/01/15 11:05:08 lgarnier Exp $ 28 28 // GEANT4 tag $Name: 29 29 // -
trunk/geant4/visualization/OpenGL/include/G4OpenGLQtViewer.hh
r681 r688 25 25 // 26 26 // 27 // $Id: G4OpenGLQtViewer.hh,v 1. 5 2007/11/30 14:47:30lgarnier Exp $27 // $Id: G4OpenGLQtViewer.hh,v 1.6 2008/01/15 11:05:08 lgarnier Exp $ 28 28 // GEANT4 tag $Name: $ 29 29 // … … 135 135 void actionDrawingSurfaceRemoval(); 136 136 void actionDrawingLineSurfaceRemoval(); 137 // void actionControlPanels();138 // void actionExitG4();139 137 void actionCreateEPS(); 140 138 -
trunk/geant4/visualization/OpenGL/include/G4OpenGLSceneHandler.hh
r631 r688 25 25 // 26 26 // 27 // $Id: G4OpenGLSceneHandler.hh,v 1.2 3 2007/04/04 16:50:26allison Exp $27 // $Id: G4OpenGLSceneHandler.hh,v 1.24 2008/01/04 22:07:01 allison Exp $ 28 28 // GEANT4 tag $Name: $ 29 29 // … … 58 58 virtual void BeginPrimitives (const G4Transform3D& objectTransformation); 59 59 virtual void EndPrimitives (); 60 virtual void BeginPrimitives2D ( );60 virtual void BeginPrimitives2D (const G4Transform3D& objectTransformation); 61 61 virtual void EndPrimitives2D (); 62 62 void AddPrimitive (const G4Polyline&); … … 95 95 const G4Polyhedron* CreateCutawayPolyhedron (); 96 96 97 void ClearAndDestroyAtts(); // Destroys att holders and clears pick map. 98 97 99 GLuint fPickName; 98 100 std::map<GLuint, G4AttHolder*> fPickMap; // For picking. 99 void ClearAndDestroyAtts(); // Destroys att holders and clears pick map. 101 102 G4bool fProcessing2D; 100 103 101 104 private: -
trunk/geant4/visualization/OpenGL/include/G4OpenGLStoredQtViewer.hh
r673 r688 25 25 // 26 26 // 27 // $Id: G4OpenGLStoredQtViewer.hh,v 1. 3 2007/11/09 15:03:21lgarnier Exp $27 // $Id: G4OpenGLStoredQtViewer.hh,v 1.4 2008/01/15 11:05:08 lgarnier Exp $ 28 28 // GEANT4 tag $Name: $ 29 29 // … … 77 77 QPoint beginZoom; 78 78 QPoint endZoom; 79 QImage glBufferImage;79 // QImage glBufferImage; 80 80 }; 81 81 -
trunk/geant4/visualization/OpenGL/include/G4OpenGLStoredSceneHandler.hh
r631 r688 25 25 // 26 26 // 27 // $Id: G4OpenGLStoredSceneHandler.hh,v 1.2 4 2007/04/04 16:50:26allison Exp $27 // $Id: G4OpenGLStoredSceneHandler.hh,v 1.25 2008/01/04 22:07:01 allison Exp $ 28 28 // GEANT4 tag $Name: $ 29 29 // … … 58 58 void BeginPrimitives (const G4Transform3D& objectTransformation); 59 59 void EndPrimitives (); 60 void BeginPrimitives2D ( );60 void BeginPrimitives2D (const G4Transform3D& objectTransformation); 61 61 void EndPrimitives2D (); 62 62 void BeginModeling (); … … 111 111 // A proper implementation would use geometry hierarchy. 112 112 std::map <const G4VSolid*, G4int, std::less <const G4VSolid*> > fSolidMap; 113 114 private:115 G4bool fProcessing2D;116 113 }; 117 114 -
trunk/geant4/visualization/OpenGL/src/G4OpenGLImmediateQtViewer.cc
r673 r688 25 25 // 26 26 // 27 // $Id: G4OpenGLImmediateQtViewer.cc,v 1. 3 2007/11/15 18:24:28 lgarnier Exp $27 // $Id: G4OpenGLImmediateQtViewer.cc,v 1.4 2008/01/15 11:05:08 lgarnier Exp $ 28 28 // GEANT4 tag $Name: $ 29 29 // -
trunk/geant4/visualization/OpenGL/src/G4OpenGLImmediateSceneHandler.cc
r631 r688 25 25 // 26 26 // 27 // $Id: G4OpenGLImmediateSceneHandler.cc,v 1.2 7 2007/04/04 16:50:26allison Exp $27 // $Id: G4OpenGLImmediateSceneHandler.cc,v 1.28 2008/01/04 22:07:01 allison Exp $ 28 28 // GEANT4 tag $Name: $ 29 29 // … … 130 130 131 131 void G4OpenGLImmediateSceneHandler::BeginPrimitives 132 (const G4Transform3D& objectTransformation) { 132 (const G4Transform3D& objectTransformation) 133 { 133 134 G4OpenGLSceneHandler::BeginPrimitives (objectTransformation); 135 136 G4OpenGLTransform3D oglt (objectTransformation); 137 134 138 glPushMatrix(); 135 G4OpenGLTransform3D oglt (objectTransformation);136 139 137 140 /*************************** Check matrix. … … 158 161 } 159 162 160 void G4OpenGLImmediateSceneHandler::BeginPrimitives2D() 161 { 162 G4OpenGLSceneHandler::BeginPrimitives2D(); 163 void G4OpenGLImmediateSceneHandler::BeginPrimitives2D 164 (const G4Transform3D& objectTransformation) 165 { 166 G4OpenGLSceneHandler::BeginPrimitives2D(objectTransformation); 163 167 164 168 // Push current 3D world matrices and load identity to define screen … … 171 175 glPushMatrix(); 172 176 glLoadIdentity(); 177 G4OpenGLTransform3D oglt (objectTransformation); 178 glMultMatrixd (oglt.GetGLMatrix ()); 173 179 } 174 180 -
trunk/geant4/visualization/OpenGL/src/G4OpenGLQtExportDialog.cc
r657 r688 25 25 // 26 26 // 27 // $Id: G4OpenGLQtExportDialog.cc,v 1. 4 2007/11/13 17:48:51lgarnier Exp $27 // $Id: G4OpenGLQtExportDialog.cc,v 1.5 2008/01/15 11:05:08 lgarnier Exp $ 28 28 // GEANT4 tag $Name: $ 29 29 // 30 30 // 31 31 32 #define GEANT4_QT_DEBUG32 //#define GEANT4_QT_DEBUG 33 33 #ifdef G4VIS_BUILD_OPENGLQT_DRIVER 34 34 -
trunk/geant4/visualization/OpenGL/src/G4OpenGLQtViewer.cc
r681 r688 25 25 // 26 26 // 27 // $Id: G4OpenGLQtViewer.cc,v 1. 8 2007/11/30 14:47:30lgarnier Exp $27 // $Id: G4OpenGLQtViewer.cc,v 1.9 2008/01/15 11:05:08 lgarnier Exp $ 28 28 // GEANT4 tag $Name: $ 29 29 // … … 36 36 #ifdef G4VIS_BUILD_OPENGLQT_DRIVER 37 37 38 #define GEANT4_QT_DEBUG38 //#define GEANT4_QT_DEBUG 39 39 40 40 #include "G4OpenGLQtViewer.hh" … … 590 590 591 591 #if QT_VERSION < 0x030200 592 // QAction *controlPanels = new QAction("&Control panels","&Control panels",CTRL+Key_C,mActions);593 // QAction *exitG4 = new QAction("&Exit to G4Vis >","&Exit to G4Vis >",CTRL+Key_E,mActions);594 592 QAction *createEPS = new QAction("&Save as ...","&Save as ...",CTRL+Key_S,mActions); 595 593 #else 596 // QAction *controlPanels = new QAction("&Control panels",CTRL+Key_C,mActions);597 // QAction *exitG4 = new QAction("&Exit to G4Vis >",CTRL+Key_E,mActions);598 594 QAction *createEPS = new QAction("&Save as ...",CTRL+Key_S,mActions); 599 595 #endif 600 // controlPanels->addTo(mActions);601 // exitG4->addTo(mActions);602 596 createEPS->addTo(mActions); 603 // QObject ::connect(controlPanels,604 // SIGNAL(activated()),605 // this,606 // SLOT(actionControlPanels()));607 // QObject ::connect(exitG4,608 // SIGNAL(activated()),609 // this,610 // SLOT(actionExitG4()));611 597 QObject ::connect(createEPS, 612 598 SIGNAL(activated()), … … 617 603 // === Action Menu === 618 604 QMenu *mActions = fContextMenu->addMenu("&Actions"); 619 // QAction *controlPanels = mActions->addAction("Control panels");620 // QAction *exitG4 = mActions->addAction("Exit to G4Vis >");621 605 QAction *createEPS = mActions->addAction("Save as ..."); 622 // QObject ::connect(controlPanels,623 // SIGNAL(triggered()),624 // this,625 // SLOT(actionControlPanels()));626 // QObject ::connect(exitG4,627 // SIGNAL(triggered()),628 // this,629 // SLOT(actionExitG4()));630 606 QObject ::connect(createEPS, 631 607 SIGNAL(triggered()), … … 1188 1164 #endif 1189 1165 } 1190 1191 1192 // void G4OpenGLQtViewer::actionControlPanels() {1193 // #ifdef GEANT4_QT_DEBUG1194 // printf("G4OpenGLQtViewer::actionControlPanels \n");1195 // #endif1196 // }1197 1198 // void G4OpenGLQtViewer::actionExitG4() {1199 // #ifdef GEANT4_QT_DEBUG1200 // printf("G4OpenGLQtViewer::actionExitG4() \n");1201 // #endif1202 // }1203 1166 1204 1167 void G4OpenGLQtViewer::actionCreateEPS() { … … 1356 1319 } 1357 1320 1358 1359 1321 /** 1360 1322 @param pos_x mouse x position … … 1366 1328 void G4OpenGLQtViewer::G4MouseMoveEvent(int pos_x, int pos_y,Qt::ButtonState mButtons) 1367 1329 #else 1368 1330 void G4OpenGLQtViewer::G4MouseMoveEvent(int pos_x, int pos_y,Qt::MouseButtons mButtons) 1369 1331 #endif 1370 1332 { … … 1611 1573 int size = width*height; 1612 1574 1613 1614 1575 if (depth == 1) 1615 1576 size = (width+7)/8*height; -
trunk/geant4/visualization/OpenGL/src/G4OpenGLSceneHandler.cc
r631 r688 25 25 // 26 26 // 27 // $Id: G4OpenGLSceneHandler.cc,v 1.5 1 2007/05/25 15:41:38allison Exp $27 // $Id: G4OpenGLSceneHandler.cc,v 1.52 2008/01/04 22:07:01 allison Exp $ 28 28 // GEANT4 tag $Name: $ 29 29 // … … 72 72 G4VSceneHandler (system, id, name), 73 73 fPickName(0), 74 fProcessing2D (false), 74 75 fProcessingPolymarker(false) 75 76 {} … … 124 125 } 125 126 126 void G4OpenGLSceneHandler::BeginPrimitives2D () 127 { 128 G4VSceneHandler::BeginPrimitives2D (); 127 void G4OpenGLSceneHandler::BeginPrimitives2D 128 (const G4Transform3D& objectTransformation) 129 { 130 G4VSceneHandler::BeginPrimitives2D (objectTransformation); 131 fProcessing2D = true; 129 132 } 130 133 131 134 void G4OpenGLSceneHandler::EndPrimitives2D () 132 135 { 136 fProcessing2D = false; 133 137 G4VSceneHandler::EndPrimitives2D (); 134 138 } … … 515 519 glMaterialfv (GL_FRONT, GL_AMBIENT_AND_DIFFUSE, materialColour); 516 520 } 517 glEnable (GL_LIGHTING);521 if (!fProcessing2D) glEnable (GL_LIGHTING); 518 522 break; 519 523 case (G4ViewParameters::wireframe): … … 605 609 glStencilOp (GL_KEEP, GL_KEEP, GL_KEEP); 606 610 if (drawing_style == G4ViewParameters::hlhsr) { 607 glEnable (GL_LIGHTING);611 if (!fProcessing2D) glEnable (GL_LIGHTING); 608 612 } 609 613 glEnable (GL_DEPTH_TEST); … … 759 763 case (G4ViewParameters::hsr): 760 764 { 761 glEnable (GL_LIGHTING);765 if (!fProcessing2D) glEnable (GL_LIGHTING); 762 766 glEnable (GL_DEPTH_TEST); 763 767 glEnable (GL_AUTO_NORMAL); -
trunk/geant4/visualization/OpenGL/src/G4OpenGLStoredQtViewer.cc
r682 r688 25 25 // 26 26 // 27 // $Id: G4OpenGLStoredQtViewer.cc,v 1. 6 2007/11/15 18:24:28 lgarnier Exp $27 // $Id: G4OpenGLStoredQtViewer.cc,v 1.8 2008/01/15 11:05:08 lgarnier Exp $ 28 28 // GEANT4 tag $Name: $ 29 29 // -
trunk/geant4/visualization/OpenGL/src/G4OpenGLStoredSceneHandler.cc
r631 r688 25 25 // 26 26 // 27 // $Id: G4OpenGLStoredSceneHandler.cc,v 1.3 4 2007/04/04 16:50:27allison Exp $27 // $Id: G4OpenGLStoredSceneHandler.cc,v 1.35 2008/01/04 22:07:01 allison Exp $ 28 28 // GEANT4 tag $Name: $ 29 29 // … … 60 60 fMemoryForDisplayLists (true), 61 61 fAddPrimitivePreambleNestingDepth (0), 62 fTopPODL (0), 63 fProcessing2D (false) 62 fTopPODL (0) 64 63 {} 65 64 … … 138 137 glPushMatrix(); 139 138 glLoadIdentity(); 139 G4OpenGLTransform3D oglt (*fpObjectTransformation); 140 glMultMatrixd (oglt.GetGLMatrix ()); 141 glColor3d (c.GetRed (), c.GetGreen (), c.GetBlue ()); 140 142 } 141 143 } … … 239 241 } 240 242 241 void G4OpenGLStoredSceneHandler::BeginPrimitives2D ()242 { 243 G4OpenGLSceneHandler::BeginPrimitives2D(); 244 fProcessing2D = true;243 void G4OpenGLStoredSceneHandler::BeginPrimitives2D 244 (const G4Transform3D& objectTransformation) 245 { 246 G4OpenGLSceneHandler::BeginPrimitives2D(objectTransformation); 245 247 } 246 248 247 249 void G4OpenGLStoredSceneHandler::EndPrimitives2D () 248 250 { 249 fProcessing2D = false;250 251 G4OpenGLSceneHandler::EndPrimitives2D (); 251 252 } -
trunk/geant4/visualization/OpenGL/src/G4OpenGLStoredViewer.cc
r636 r688 142 142 } 143 143 144 if (fG4OpenGLStoredSceneHandler.fTopPODL) {144 if (fG4OpenGLStoredSceneHandler.fTopPODL) 145 145 glCallList (fG4OpenGLStoredSceneHandler.fTopPODL); 146 } 146 147 147 for (size_t i = 0; i < fG4OpenGLStoredSceneHandler.fTOList.size(); ++i) { 148 148 G4OpenGLStoredSceneHandler::TO& to = -
trunk/geant4/visualization/OpenGL/src/G4OpenGLViewer.cc
r678 r688 26 26 // 27 27 // $Id: G4OpenGLViewer.cc,v 1.34 2007/05/24 18:27:13 allison Exp $ 28 // GEANT4 tag $Name: $28 // GEANT4 tag $Name: HEAD $ 29 29 // 30 30 // … … 313 313 void G4OpenGLViewer::Pick(GLdouble x, GLdouble y) 314 314 { 315 printf("G4OpenGLViewer::Pick\n");316 315 //G4cout << "X: " << x << ", Y: " << y << G4endl; 317 316 const G4int BUFSIZE = 512; -
trunk/geant4/visualization/management/History
r632 r688 1 $Id: History,v 1.10 4 2007/11/30 14:47:30 lgarnierExp $1 $Id: History,v 1.105 2008/01/04 22:03:46 allison Exp $ 2 2 3 3 ------------------------------------------------------------------- … … 26 26 History file for visualization management sub-category 27 27 ------------------------------------------------------ 28 29 4th January 2008 John Allison (visman-V09-01-00) 30 - Implemented extended 2D interface. 28 31 29 32 30th November 2007 Laurent Garnier -
trunk/geant4/visualization/management/include/G4VSceneHandler.hh
r593 r688 25 25 // 26 26 // 27 // $Id: G4VSceneHandler.hh,v 1. 39 2007/01/11 16:38:14allison Exp $28 // GEANT4 tag $Name: geant4-09-00-ref-01$27 // $Id: G4VSceneHandler.hh,v 1.40 2008/01/04 22:03:45 allison Exp $ 28 // GEANT4 tag $Name: $ 29 29 // 30 30 // … … 164 164 // } 165 165 166 virtual void BeginPrimitives2D (); 166 virtual void BeginPrimitives2D 167 (const G4Transform3D& objectTransformation); 167 168 // The x,y coordinates of the primitives passed to AddPrimitive are 168 169 // intrepreted as screen coordinates, -1 < x,y < 1. The -
trunk/geant4/visualization/management/include/G4VisManager.hh
r593 r688 25 25 // 26 26 // 27 // $Id: G4VisManager.hh,v 1.6 7 2007/07/10 17:49:27allison Exp $28 // GEANT4 tag $Name: geant4-09-00-ref-01$27 // $Id: G4VisManager.hh,v 1.68 2008/01/04 22:03:46 allison Exp $ 28 // GEANT4 tag $Name: $ 29 29 // 30 30 // … … 250 250 const G4Transform3D& objectTransformation = G4Transform3D()); 251 251 252 void Draw2D (const G4Text&); 252 virtual void Draw2D (const G4Circle&, 253 const G4Transform3D& objectTransformation = G4Transform3D()); 254 255 virtual void Draw2D (const G4NURBS&, 256 const G4Transform3D& objectTransformation = G4Transform3D()); 257 258 virtual void Draw2D (const G4Polyhedron&, 259 const G4Transform3D& objectTransformation = G4Transform3D()); 260 261 virtual void Draw2D (const G4Polyline&, 262 const G4Transform3D& objectTransformation = G4Transform3D()); 263 264 virtual void Draw2D (const G4Polymarker&, 265 const G4Transform3D& objectTransformation = G4Transform3D()); 266 267 virtual void Draw2D (const G4Square&, 268 const G4Transform3D& objectTransformation = G4Transform3D()); 269 270 virtual void Draw2D (const G4Text&, 271 const G4Transform3D& objectTransformation = G4Transform3D()); 253 272 254 273 //////////////////////////////////////////////////////////////////// -
trunk/geant4/visualization/management/src/G4VSceneHandler.cc
r593 r688 25 25 // 26 26 // 27 // $Id: G4VSceneHandler.cc,v 1.8 2 2007/05/16 15:47:44allison Exp $28 // GEANT4 tag $Name: geant4-09-00-ref-01$27 // $Id: G4VSceneHandler.cc,v 1.83 2008/01/04 22:03:46 allison Exp $ 28 // GEANT4 tag $Name: $ 29 29 // 30 30 // … … 159 159 } 160 160 161 void G4VSceneHandler::BeginPrimitives2D () { 161 void G4VSceneHandler::BeginPrimitives2D 162 (const G4Transform3D& objectTransformation) { 162 163 fNestingDepth++; 163 164 if (fNestingDepth > 1) 164 165 G4Exception("G4VSceneHandler::BeginPrimitives2D: Nesting detected." 165 166 "\n It is illegal to nest Begin/EndPrimitives."); 166 // Not actually required for 2D operations but some drivers do an 167 // initial transformation... 168 fpObjectTransformation = &fIdentityTransformation; 167 fpObjectTransformation = &objectTransformation; 169 168 } 170 169 -
trunk/geant4/visualization/management/src/G4VisManager.cc
r632 r688 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4VisManager.cc,v 1.11 4 2007/11/10 14:59:46 allison Exp $26 // $Id: G4VisManager.cc,v 1.115 2008/01/04 22:03:46 allison Exp $ 27 27 // GEANT4 tag $Name: $ 28 28 // … … 505 505 } 506 506 507 void G4VisManager::Draw2D (const G4Text& text) 507 void G4VisManager::Draw2D (const G4Circle& circle, 508 const G4Transform3D& objectTransform) 508 509 { 509 510 if (IsValidView()) { 510 511 ClearTransientStoreIfMarked(); 511 fpSceneHandler -> BeginPrimitives2D(); 512 fpSceneHandler -> BeginPrimitives2D(objectTransform); 513 fpSceneHandler -> AddPrimitive(circle); 514 fpSceneHandler -> EndPrimitives2D(); 515 } 516 } 517 518 void G4VisManager::Draw2D (const G4NURBS& nurbs, 519 const G4Transform3D& objectTransform) 520 { 521 if (IsValidView()) { 522 ClearTransientStoreIfMarked(); 523 fpSceneHandler -> BeginPrimitives2D(objectTransform); 524 fpSceneHandler -> AddPrimitive(nurbs); 525 fpSceneHandler -> EndPrimitives2D(); 526 } 527 } 528 529 void G4VisManager::Draw2D (const G4Polyhedron& polyhedron, 530 const G4Transform3D& objectTransform) 531 { 532 if (IsValidView()) { 533 ClearTransientStoreIfMarked(); 534 fpSceneHandler -> BeginPrimitives2D(objectTransform); 535 fpSceneHandler -> AddPrimitive(polyhedron); 536 fpSceneHandler -> EndPrimitives2D(); 537 } 538 } 539 540 void G4VisManager::Draw2D (const G4Polyline& line, 541 const G4Transform3D& objectTransform) 542 { 543 if (IsValidView()) { 544 ClearTransientStoreIfMarked(); 545 fpSceneHandler -> BeginPrimitives2D(objectTransform); 546 fpSceneHandler -> AddPrimitive(line); 547 fpSceneHandler -> EndPrimitives2D(); 548 } 549 } 550 551 void G4VisManager::Draw2D (const G4Polymarker& polymarker, 552 const G4Transform3D& objectTransform) 553 { 554 if (IsValidView()) { 555 ClearTransientStoreIfMarked(); 556 fpSceneHandler -> BeginPrimitives2D(objectTransform); 557 fpSceneHandler -> AddPrimitive(polymarker); 558 fpSceneHandler -> EndPrimitives2D(); 559 } 560 } 561 562 void G4VisManager::Draw2D (const G4Square& square, 563 const G4Transform3D& objectTransform) 564 { 565 if (IsValidView()) { 566 ClearTransientStoreIfMarked(); 567 fpSceneHandler -> BeginPrimitives2D(objectTransform); 568 fpSceneHandler -> AddPrimitive(square); 569 fpSceneHandler -> EndPrimitives2D(); 570 } 571 } 572 573 void G4VisManager::Draw2D (const G4Text& text, 574 const G4Transform3D& objectTransform) 575 { 576 if (IsValidView()) { 577 ClearTransientStoreIfMarked(); 578 fpSceneHandler -> BeginPrimitives2D(objectTransform); 512 579 fpSceneHandler -> AddPrimitive(text); 513 580 fpSceneHandler -> EndPrimitives2D();
Note: See TracChangeset
for help on using the changeset viewer.