Changeset 1315 for trunk/source/visualization
- Timestamp:
- Jun 18, 2010, 11:42:07 AM (14 years ago)
- Location:
- trunk/source/visualization
- Files:
-
- 21 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/visualization/HepRep/History
r1294 r1315 1 .$Id: History,v 1.13 3 2010/05/30 10:28:02 allisonExp $1 .$Id: History,v 1.134 2010/06/05 06:25:03 perl Exp $ 2 2 ------------------------------------------------------------------- 3 3 … … 20 20 History file for visualization/HepRep sub-category 21 21 -------------------------------------------------- 22 23 4th June 2010 Joseph Perl (vis-HepRep-V09-03-02) 24 - G4HepRepMessenger: Add command renderCylAsPolygons 25 - G4HepRepFileSceneHandler: Use new command 22 26 23 27 30th May 2010 John Allison (vis-HepRep-V09-03-00) -
trunk/source/visualization/HepRep/include/G4HepRepMessenger.hh
r1228 r1315 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4HepRepMessenger.hh,v 1. 8 2009/11/23 05:42:28perl Exp $27 // GEANT4 tag $Name: $26 // $Id: G4HepRepMessenger.hh,v 1.9 2010/06/05 06:25:03 perl Exp $ 27 // GEANT4 tag $Name: geant4-09-04-beta-cand-01 $ 28 28 // 29 29 // … … 51 51 virtual G4bool getOverwrite(); 52 52 virtual G4bool getCullInvisibles(); 53 virtual G4bool renderCylAsPolygons(); 53 54 54 55 // Used by HepRepXML … … 76 77 G4bool cullInvisibles; 77 78 G4UIcmdWithABool* setCullInvisiblesCommand; 78 79 80 G4bool cylAsPolygons; 81 G4UIcmdWithABool* renderCylAsPolygonsCommand; 82 79 83 G4String suffix; 80 84 G4UIcmdWithAString* setEventNumberSuffixCommand; -
trunk/source/visualization/HepRep/src/G4HepRepFileSceneHandler.cc
r1228 r1315 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4HepRepFileSceneHandler.cc,v 1.6 8 2009/12/16 17:51:21 gunterExp $27 // GEANT4 tag $Name: $26 // $Id: G4HepRepFileSceneHandler.cc,v 1.69 2010/06/05 06:25:03 perl Exp $ 27 // GEANT4 tag $Name: geant4-09-04-beta-cand-01 $ 28 28 // 29 29 // … … 210 210 #endif 211 211 212 // HepRApp does not correctly represent the end faces of cones at 213 // non-standard angles, let the base class convert these solids to polygons. 214 CLHEP::HepRotation r = fpObjectTransformation->getRotation(); 215 G4bool linedUpWithAnAxis = (std::fabs(r.phiX())<=.001 || 216 std::fabs(r.phiY())<=.001 || 217 std::fabs(r.phiZ())<=.001 || 218 std::fabs(r.phiX()-pi)<=.001 || 219 std::fabs(r.phiY()-pi)<=.001 || 220 std::fabs(r.phiZ()-pi)<=.001); 221 //G4cout << "Angle X:" << r.phiX() << ", Angle Y:" << r.phiY() << ", Angle Z:" << r.phiZ() << G4endl; 222 //G4cout << "linedUpWithAnAxis:" << linedUpWithAnAxis << G4endl; 223 212 224 // HepRep does not have a primitive for a cut cone, 213 225 // so if this cone is cut, let the base class convert this 214 226 // solid to polygons. 215 if (cons.GetDeltaPhiAngle() < twopi) { 227 G4HepRepMessenger* messenger = G4HepRepMessenger::GetInstance(); 228 if (cons.GetDeltaPhiAngle() < twopi || !linedUpWithAnAxis || messenger->renderCylAsPolygons()) 229 { 216 230 G4VSceneHandler::AddSolid(cons); // Invoke default action. 217 231 } else { … … 278 292 // so if this cylinder is cut, let the base class convert this 279 293 // solid to polygons. 280 if (tubs.GetDeltaPhiAngle() < twopi || !linedUpWithAnAxis) 294 G4HepRepMessenger* messenger = G4HepRepMessenger::GetInstance(); 295 if (tubs.GetDeltaPhiAngle() < twopi || !linedUpWithAnAxis || messenger->renderCylAsPolygons()) 281 296 { 282 297 G4VSceneHandler::AddSolid(tubs); // Invoke default action. … … 291 306 haveVisible = false; 292 307 AddHepRepInstance("Cylinder", NULL); 293 294 G4HepRepMessenger* messenger = G4HepRepMessenger::GetInstance();295 308 296 309 if (fpVisAttribs && (fpVisAttribs->IsVisible()==0) && messenger->getCullInvisibles()) … … 475 488 if (!pTrModel) G4Exception 476 489 ("G4HepRepFileSceneHandler::AddCompound(const G4VTrajectory&): Not a G4TrajectoriesModel."); 477 G4int drawingMode = pTrModel->GetDrawingMode();478 490 479 491 // Pointers to hold trajectory attribute values and definitions. … … 551 563 // Would rather be able to get these attDefs without needing a reference from any 552 564 // particular point, but don't know how to do that. 553 if (( drawingMode!=0 ||trajContext->GetDrawStepPts() || trajContext->GetDrawAuxPts())565 if ((trajContext->GetDrawStepPts() || trajContext->GetDrawAuxPts()) 554 566 && traj.GetPointEntries()>0) { 555 567 G4VTrajectoryPoint* aTrajectoryPoint = traj.GetPoint(0); … … 626 638 627 639 // Draw step points. 628 if ( drawingMode!=0 ||trajContext->GetDrawStepPts()) {640 if (trajContext->GetDrawStepPts()) { 629 641 if (!doneInitTraj) 630 642 InitTrajectory(); … … 642 654 G4bool visible; 643 655 G4bool square; 644 if (drawingMode==0) { 645 G4Colour colour = trajContext->GetStepPtsColour(); 646 redness = colour.GetRed(); 647 greenness = colour.GetGreen(); 648 blueness = colour.GetBlue(); 649 markSize = (G4int) trajContext->GetStepPtsSize(); 650 visible = (G4int) trajContext->GetStepPtsVisible(); 651 square = (trajContext->GetStepPtsType()==G4Polymarker::squares); 652 } else { 653 redness = 1.; 654 greenness = 1.; 655 blueness = 1.; 656 markSize = std::abs(drawingMode/1000); 657 visible = true; 658 square = false; 659 } 656 G4Colour colour = trajContext->GetStepPtsColour(); 657 redness = colour.GetRed(); 658 greenness = colour.GetGreen(); 659 blueness = colour.GetBlue(); 660 markSize = (G4int) trajContext->GetStepPtsSize(); 661 visible = (G4int) trajContext->GetStepPtsVisible(); 662 square = (trajContext->GetStepPtsType()==G4Polymarker::squares); 660 663 661 664 // Avoiding drawing anything black on black. … … 735 738 736 739 // Draw Auxiliary Points 737 if ( drawingMode!=0 ||trajContext->GetDrawAuxPts()) {740 if (trajContext->GetDrawAuxPts()) { 738 741 if (!doneInitTraj) 739 742 InitTrajectory(); … … 751 754 G4bool visible; 752 755 G4bool square; 753 if (drawingMode==0) { 754 G4Colour colour = trajContext->GetAuxPtsColour(); 755 redness = colour.GetRed(); 756 greenness = colour.GetGreen(); 757 blueness = colour.GetBlue(); 758 markSize = (G4int) trajContext->GetAuxPtsSize(); 759 visible = (G4int) trajContext->GetAuxPtsVisible(); 760 square = (trajContext->GetAuxPtsType()==G4Polymarker::squares); 761 } else { 762 redness = 1.; 763 greenness = 1.; 764 blueness = 1.; 765 markSize = std::abs(drawingMode/1000); 766 visible = true; 767 square = false; 768 } 756 G4Colour colour = trajContext->GetAuxPtsColour(); 757 redness = colour.GetRed(); 758 greenness = colour.GetGreen(); 759 blueness = colour.GetBlue(); 760 markSize = (G4int) trajContext->GetAuxPtsSize(); 761 visible = (G4int) trajContext->GetAuxPtsVisible(); 762 square = (trajContext->GetAuxPtsType()==G4Polymarker::squares); 769 763 770 764 // Avoiding drawing anything black on black. -
trunk/source/visualization/HepRep/src/G4HepRepMessenger.cc
r1228 r1315 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4HepRepMessenger.cc,v 1.1 1 2009/11/23 05:42:28perl Exp $27 // GEANT4 tag $Name: $26 // $Id: G4HepRepMessenger.cc,v 1.12 2010/06/05 06:25:03 perl Exp $ 27 // GEANT4 tag $Name: geant4-09-04-beta-cand-01 $ 28 28 // 29 29 #include "G4HepRepMessenger.hh" … … 100 100 } 101 101 setCullInvisiblesCommand->AvailableForStates(G4State_Idle); 102 103 renderCylAsPolygonsCommand = new G4UIcmdWithABool("/vis/heprep/renderCylAsPolygons", this); 104 renderCylAsPolygonsCommand->SetGuidance("Render cylinders and cones as polygons."); 105 renderCylAsPolygonsCommand->SetGuidance("This command is used by HepRepFile, not by HepRepXML."); 106 renderCylAsPolygonsCommand->SetParameterName("flag",false); 107 renderCylAsPolygonsCommand->SetDefaultValue(true); 108 renderCylAsPolygonsCommand->AvailableForStates(G4State_Idle); 102 109 103 110 setEventNumberSuffixCommand = new G4UIcmdWithAString("/vis/heprep/setEventNumberSuffix", this); … … 122 129 addPointAttributesCommand->SetDefaultValue(false); 123 130 addPointAttributesCommand->AvailableForStates(G4State_Idle); 124 125 126 127 useSolidsCommand->SetGuidance("This command is used by HepRepXML, not by HepRepFile. ");128 129 130 131 132 useSolidsCommand = new G4UIcmdWithABool("/vis/heprep/useSolids", this); 133 useSolidsCommand->SetGuidance("Use HepRep Solids, rather than Geant4 Primitives."); 134 useSolidsCommand->SetGuidance("This command is used by HepRepXML, not by HepRepFile.."); 135 useSolidsCommand->SetParameterName("flag",false); 136 useSolidsCommand->SetDefaultValue(true); 137 useSolidsCommand->AvailableForStates(G4State_Idle); 131 138 } 132 139 … … 136 143 delete setOverwriteCommand; 137 144 delete setCullInvisiblesCommand; 145 delete renderCylAsPolygonsCommand; 138 146 delete setEventNumberSuffixCommand; 139 147 delete appendGeometryCommand; … … 152 160 } else if (command==setCullInvisiblesCommand) { 153 161 return cullInvisibles; 162 } else if (command==renderCylAsPolygonsCommand) { 163 return renderCylAsPolygonsCommand->ConvertToString(cylAsPolygons); 154 164 } else if (command==setEventNumberSuffixCommand) { 155 165 return suffix; … … 174 184 } else if (command==setCullInvisiblesCommand) { 175 185 cullInvisibles = setCullInvisiblesCommand->GetNewBoolValue(newValue); 186 } else if (command==renderCylAsPolygonsCommand) { 187 cylAsPolygons = renderCylAsPolygonsCommand->GetNewBoolValue(newValue); 176 188 } else if (command==setEventNumberSuffixCommand) { 177 189 suffix = newValue; … … 201 213 } 202 214 215 G4bool G4HepRepMessenger::renderCylAsPolygons() { 216 return cylAsPolygons; 217 } 218 203 219 G4String G4HepRepMessenger::getEventNumberSuffix() { 204 220 return suffix; -
trunk/source/visualization/History
r1290 r1315 1 $Id: History,v 1.4 75 2010/06/01 16:20:18allison Exp $1 $Id: History,v 1.481 2010/06/15 16:41:14 allison Exp $ 2 2 ------------------------------------------------------------------- 3 3 … … 24 24 History file for visualization category 25 25 --------------------------------------- 26 27 15th June 2010 John Allison (vis-V09-03-08) 28 - visman-V09-03-10: 29 o Added virtual destructors to fix compilation warnings. 30 o Improved action after "/vis/geometry/..." commands. 31 - raytracer-V09-03-02 (Gabriele Cosmo): 32 o Added virtual destructors to fix compilation warnings. 33 34 4th June 2010 Joseph Perl (vis-V09-03-07) 35 - vis-HepRep-V09-03-02 36 o Added command renderCylAsPolygon 37 - opengl-V09-03-07 38 o G4OpenGLImmediate/StoredQtViewer : Add protection against multiple 39 repaint call. Add protection against resizeGl with bad values 40 41 3rd June 2010 John Allison 42 - opengl-V09-03-06: 43 o Restored all behaviour-sensitive changes to geant4-09-03. 44 - visman-V09-03-09: 45 o Fixed unchecked pointer. 46 o Changed /vis/scene/add/digiti[sz]ations to /vis/scene/add/digis. 47 - opengl-V09-03-05: 48 o Restored some changes to geant4-09-03 to preserve behaviour. 49 50 1st June 2010 John Allison 51 - modeling-V09-03-03: Added default colours to G4TrajectoryDrawByParticleID. 26 52 27 53 1st June 2010 John Allison (vis-V09-03-06) -
trunk/source/visualization/OpenGL/History
r1307 r1315 1 $Id: History,v 1.17 8 2010/06/04 15:27:47 lgarnierExp $1 $Id: History,v 1.179 2010/06/05 06:26:38 perl Exp $ 2 2 ------------------------------------------------------------------- 3 3 … … 18 18 ---------------------------------------------------------- 19 19 20 4th June 2010 Laurent Garnier 20 4th June 2010 Laurent Garnier (opengl-V09-03-07) 21 21 - G4OpenGLImmediate/StoredQtViewer : Add protection against multiple 22 22 repaint call. Add protection against resizeGl with bad values -
trunk/source/visualization/OpenGL/src/G4OpenGLViewer.cc
r1314 r1315 113 113 glDisable (GL_POLYGON_SMOOTH); 114 114 115 if (fVP) {115 // if (fVP != NULL) { 116 116 fWinSize_x = fVP.GetWindowSizeHintX(); 117 117 fWinSize_y = fVP.GetWindowSizeHintY(); 118 }118 // } 119 119 } 120 120 -
trunk/source/visualization/RayTracer/History
r1294 r1315 1 $Id: History,v 1.6 3 2010/05/30 10:22:26 allisonExp $1 $Id: History,v 1.64 2010/06/14 14:33:34 gcosmo Exp $ 2 2 ------------------------------------------------------------------- 3 3 … … 24 24 History file for Ray Tracer category 25 25 --------------------------------------- 26 27 14th June 2010 Gabriele Cosmo (raytracer-V09-03-02) 28 - Added missing virtual destructor to G4VRTScanner, G4RTXScanner and 29 G4RTSimpleScanner. 26 30 27 31 30th May 2010 John Allison (raytracer-V09-03-01) -
trunk/source/visualization/RayTracer/include/G4RTSimpleScanner.hh
r954 r1315 25 25 // 26 26 // 27 // $Id: G4RTSimpleScanner.hh,v 1. 3 2006/06/29 21:23:25 gunterExp $28 // GEANT4 tag $Name: $27 // $Id: G4RTSimpleScanner.hh,v 1.4 2010/06/14 14:33:34 gcosmo Exp $ 28 // GEANT4 tag $Name: vis-V09-03-08 $ 29 29 // 30 30 // … … 45 45 46 46 G4RTSimpleScanner(); 47 virtual ~G4RTSimpleScanner(); 47 48 48 // Compiler defaults for destructor, copy constructor and 49 // assignmemt. 49 // Compiler defaults for copy constructor and assignmemt. 50 50 51 51 virtual const G4String& GetGSName() const; -
trunk/source/visualization/RayTracer/include/G4RTXScanner.hh
r954 r1315 25 25 // 26 26 // 27 // $Id: G4RTXScanner.hh,v 1. 4 2006/06/29 21:23:31 gunterExp $28 // GEANT4 tag $Name: $27 // $Id: G4RTXScanner.hh,v 1.5 2010/06/14 14:33:34 gcosmo Exp $ 28 // GEANT4 tag $Name: vis-V09-03-08 $ 29 29 // 30 30 // … … 53 53 54 54 G4RTXScanner(); 55 virtual ~G4RTXScanner(); 55 56 56 // Compiler defaults for destructor, copy constructor and 57 // assignmemt. 57 // Compiler defaults for copy constructor and assignmemt. 58 58 59 59 virtual const G4String& GetGSName() const; -
trunk/source/visualization/RayTracer/include/G4VRTScanner.hh
r954 r1315 25 25 // 26 26 // 27 // $Id: G4VRTScanner.hh,v 1. 5 2006/06/29 21:23:53 gunterExp $28 // GEANT4 tag $Name: $27 // $Id: G4VRTScanner.hh,v 1.6 2010/06/14 14:33:34 gcosmo Exp $ 28 // GEANT4 tag $Name: vis-V09-03-08 $ 29 29 // 30 30 // … … 44 44 public: // with description 45 45 46 G4VRTScanner(); 47 virtual ~G4VRTScanner(); 48 46 49 virtual const G4String& GetGSName() const = 0; 47 50 // Get name that acts as graphics system name. … … 66 69 }; 67 70 68 inline void G4VRTScanner::Draw 69 (unsigned char, unsigned char, unsigned char) 70 {} 71 inline 72 void G4VRTScanner::Draw(unsigned char, unsigned char, unsigned char) {} 71 73 72 74 #endif -
trunk/source/visualization/RayTracer/src/G4RTSimpleScanner.cc
r954 r1315 25 25 // 26 26 // 27 // $Id: G4RTSimpleScanner.cc,v 1. 4 2007/05/22 17:10:42 allisonExp $28 // GEANT4 tag $Name: $27 // $Id: G4RTSimpleScanner.cc,v 1.5 2010/06/14 14:33:34 gcosmo Exp $ 28 // GEANT4 tag $Name: vis-V09-03-08 $ 29 29 // 30 30 // … … 33 33 34 34 G4RTSimpleScanner::G4RTSimpleScanner(): 35 theNRow(0), theNColumn(0), theIRow(0), theIColumn(0)35 G4VRTScanner(), theNRow(0), theNColumn(0), theIRow(0), theIColumn(0) 36 36 { 37 37 theGSName = "RayTracer"; 38 38 theGSNickname = "RayTracer"; 39 39 } 40 41 G4RTSimpleScanner::~G4RTSimpleScanner(){} 40 42 41 43 const G4String& G4RTSimpleScanner::GetGSName() const -
trunk/source/visualization/RayTracer/src/G4RTXScanner.cc
r1136 r1315 25 25 // 26 26 // 27 // $Id: G4RTXScanner.cc,v 1. 7 2009/09/16 16:56:52 allisonExp $28 // GEANT4 tag $Name: $27 // $Id: G4RTXScanner.cc,v 1.8 2010/06/14 14:33:34 gcosmo Exp $ 28 // GEANT4 tag $Name: vis-V09-03-08 $ 29 29 // 30 30 // … … 48 48 49 49 G4RTXScanner::G4RTXScanner(): 50 theNRow(0), theNColumn(0), theIRow(0), theIColumn(0)50 G4VRTScanner(), theNRow(0), theNColumn(0), theIRow(0), theIColumn(0) 51 51 { 52 52 theGSName = "RayTracerX"; 53 53 theGSNickname = "RayTracerX"; 54 54 } 55 56 G4RTXScanner::~G4RTXScanner() {} 55 57 56 58 const G4String& G4RTXScanner::GetGSName() const -
trunk/source/visualization/management/History
r1288 r1315 1 $Id: History,v 1.15 0 2010/06/01 16:14:10allison Exp $1 $Id: History,v 1.152 2010/06/15 16:34:43 allison Exp $ 2 2 3 3 ------------------------------------------------------------------- … … 26 26 History file for visualization management sub-category 27 27 ------------------------------------------------------ 28 29 15th June 2010 John Allison (visman-V09-03-10) 30 - G4VisCommandsGeometrySet.hh: Added virtual destructors to fix 31 compilation warnings. 32 - G4VisCommandsGeometrySet.cc: Changed "/vis/viewer/rebuild" to 33 "/vis/scene/notifyHandlers", the command to be executed after a 34 "/vis/geometry/..." command. "/vis/scene/notifyHandlers" causes 35 rebuild if viewer is "auto-refresh", otherwiae a message advises a 36 rebuild. This prevents over-enthusiatic rebuildin. 37 38 3rd June 2010 John Allison (visman-V09-03-09) 39 - G4VisManager.cc: Checked valid view in DispatchToModel. 40 - Changed /vis/scene/add/digiti[sz]ations to /vis/scene/add/digis. 28 41 29 42 1st June 2010 John Allison (visman-V09-03-07) -
trunk/source/visualization/management/include/G4VisCommandsGeometrySet.hh
r954 r1315 25 25 // 26 26 // 27 // $Id: G4VisCommandsGeometrySet.hh,v 1. 3 2007/01/05 16:24:19allison Exp $28 // GEANT4 tag $Name: $27 // $Id: G4VisCommandsGeometrySet.hh,v 1.4 2010/06/15 16:33:55 allison Exp $ 28 // GEANT4 tag $Name: vis-V09-03-08 $ 29 29 30 30 // /vis/geometry commands - John Allison 31st January 2006 … … 40 40 class G4VVisCommandGeometrySetFunction { 41 41 public: 42 virtual ~G4VVisCommandGeometrySetFunction() {} 42 43 virtual void operator()(G4VisAttributes*) const = 0; 43 44 }; … … 46 47 public G4VVisCommandGeometrySetFunction { 47 48 public: 49 virtual ~G4VisCommandGeometrySetColourFunction() {} 48 50 G4VisCommandGeometrySetColourFunction 49 51 (const G4Colour& colour): … … 59 61 public G4VVisCommandGeometrySetFunction { 60 62 public: 63 virtual ~G4VisCommandGeometrySetDaughtersInvisibleFunction() {} 61 64 G4VisCommandGeometrySetDaughtersInvisibleFunction 62 65 (G4bool daughtersInvisible): … … 72 75 public G4VVisCommandGeometrySetFunction { 73 76 public: 77 virtual ~G4VisCommandGeometrySetForceAuxEdgeVisibleFunction() {} 74 78 G4VisCommandGeometrySetForceAuxEdgeVisibleFunction 75 79 (G4bool forceAuxEdgeVisible): … … 85 89 public G4VVisCommandGeometrySetFunction { 86 90 public: 91 virtual ~G4VisCommandGeometrySetForceLineSegmentsPerCircleFunction() {} 87 92 G4VisCommandGeometrySetForceLineSegmentsPerCircleFunction 88 93 (G4int lineSegmentsPerCircle): … … 98 103 public G4VVisCommandGeometrySetFunction { 99 104 public: 105 virtual ~G4VisCommandGeometrySetForceSolidFunction() {} 100 106 G4VisCommandGeometrySetForceSolidFunction 101 107 (G4bool forceSolid): … … 111 117 public G4VVisCommandGeometrySetFunction { 112 118 public: 119 virtual ~G4VisCommandGeometrySetForceWireframeFunction() {} 113 120 G4VisCommandGeometrySetForceWireframeFunction 114 121 (G4bool forceWireframe): … … 124 131 public G4VVisCommandGeometrySetFunction { 125 132 public: 133 virtual ~G4VisCommandGeometrySetLineStyleFunction() {} 126 134 G4VisCommandGeometrySetLineStyleFunction 127 135 (G4VisAttributes::LineStyle lineStyle): … … 137 145 public G4VVisCommandGeometrySetFunction { 138 146 public: 147 virtual ~G4VisCommandGeometrySetLineWidthFunction() {} 139 148 G4VisCommandGeometrySetLineWidthFunction 140 149 (G4double lineWidth): … … 150 159 public G4VVisCommandGeometrySetFunction { 151 160 public: 161 virtual ~G4VisCommandGeometrySetVisibilityFunction() {} 152 162 G4VisCommandGeometrySetVisibilityFunction 153 163 (G4bool visibility): -
trunk/source/visualization/management/include/G4VisCommandsSceneAdd.hh
r1288 r1315 25 25 // 26 26 // 27 // $Id: G4VisCommandsSceneAdd.hh,v 1.2 0 2010/05/30 11:30:49allison Exp $28 // GEANT4 tag $Name: $27 // $Id: G4VisCommandsSceneAdd.hh,v 1.21 2010/06/03 10:17:44 allison Exp $ 28 // GEANT4 tag $Name: geant4-09-04-beta-cand-01 $ 29 29 30 30 // /vis/scene commands - John Allison 9th August 1998 … … 63 63 G4VisCommandSceneAddDigis& operator = (const G4VisCommandSceneAddDigis&); 64 64 G4UIcmdWithoutParameter* fpCommand; 65 G4UIcmdWithoutParameter* fpCommandUS;66 65 }; 67 66 -
trunk/source/visualization/management/src/G4VisCommandsGeometrySet.cc
r954 r1315 25 25 // 26 26 // 27 // $Id: G4VisCommandsGeometrySet.cc,v 1. 7 2007/01/05 16:24:19allison Exp $28 // GEANT4 tag $Name: $27 // $Id: G4VisCommandsGeometrySet.cc,v 1.8 2010/06/15 16:34:30 allison Exp $ 28 // GEANT4 tag $Name: vis-V09-03-08 $ 29 29 30 30 // /vis/geometry commands - John Allison 31st January 2006 … … 64 64 } 65 65 if (fpVisManager->GetCurrentViewer()) { 66 G4UImanager::GetUIpointer()->ApplyCommand("/vis/ viewer/rebuild");66 G4UImanager::GetUIpointer()->ApplyCommand("/vis/scene/notifyHandlers"); 67 67 } 68 68 } -
trunk/source/visualization/management/src/G4VisCommandsSceneAdd.cc
r1288 r1315 25 25 // 26 26 // 27 // $Id: G4VisCommandsSceneAdd.cc,v 1.8 1 2010/06/01 16:08:15allison Exp $28 // GEANT4 tag $Name: $27 // $Id: G4VisCommandsSceneAdd.cc,v 1.82 2010/06/03 10:17:44 allison Exp $ 28 // GEANT4 tag $Name: geant4-09-04-beta-cand-01 $ 29 29 // /vis/scene commands - John Allison 9th August 1998 30 30 … … 162 162 163 163 G4VisCommandSceneAddDigis::G4VisCommandSceneAddDigis () { 164 fpCommand = new G4UIcmdWithoutParameter ("/vis/scene/add/digi tisations", this);164 fpCommand = new G4UIcmdWithoutParameter ("/vis/scene/add/digis", this); 165 165 fpCommand -> SetGuidance ("Adds digis to current scene."); 166 166 fpCommand -> SetGuidance 167 167 ("Digis are drawn at end of event when the scene in which" 168 168 "\nthey are added is current."); 169 170 fpCommandUS = new G4UIcmdWithoutParameter ("/vis/scene/add/digitizations", this);171 fpCommandUS -> SetGuidance ("Adds digis to current scene.");172 fpCommandUS -> SetGuidance173 ("Digis are drawn at end of event when the scene in which"174 "\nthey are added is current.");175 169 } 176 170 177 171 G4VisCommandSceneAddDigis::~G4VisCommandSceneAddDigis () { 178 delete fpCommandUS;179 172 delete fpCommand; 180 173 } -
trunk/source/visualization/management/src/G4VisManager.cc
r1292 r1315 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4VisManager.cc,v 1.12 8 2010/06/01 16:08:15allison Exp $27 // GEANT4 tag $Name: $26 // $Id: G4VisManager.cc,v 1.129 2010/06/03 10:16:11 allison Exp $ 27 // GEANT4 tag $Name: geant4-09-04-beta-cand-01 $ 28 28 // 29 29 // … … 940 940 assert (0 != trajectoryModel); // Should exist 941 941 942 G4TrajectoriesModel* trajectoriesModel = 943 dynamic_cast<G4TrajectoriesModel*>(fpSceneHandler->GetModel()); 944 if (trajectoriesModel) { 945 if (trajectoriesModel->IsDrawingModeSet()) { 942 if (IsValidView()) { 943 G4TrajectoriesModel* trajectoriesModel = 944 dynamic_cast<G4TrajectoriesModel*>(fpSceneHandler->GetModel()); 945 if (trajectoriesModel) { 946 if (trajectoriesModel->IsDrawingModeSet()) { 947 trajectoryModel->Draw(trajectory, i_mode, visible); 948 } else { 949 trajectoryModel->Draw(trajectory, visible); 950 } 951 } else { 952 // Just draw at user's request 946 953 trajectoryModel->Draw(trajectory, i_mode, visible); 947 } else { 948 trajectoryModel->Draw(trajectory, visible); 949 } 950 } else { 951 // Just draw at user's request 952 trajectoryModel->Draw(trajectory, i_mode, visible); 954 } 953 955 } 954 956 } … … 1361 1363 if (eventID < nEventsToBeProcessed - 1) { 1362 1364 fpViewer->ShowView(); 1365 fpViewer->DrawView(); 1363 1366 fpSceneHandler->SetMarkForClearingTransientStore(true); 1364 1367 } else { // Last event... -
trunk/source/visualization/modeling/History
r1288 r1315 1 $Id: History,v 1.1 19 2010/05/30 11:24:57allison Exp $1 $Id: History,v 1.121 2010/06/01 21:49:49 allison Exp $ 2 2 ------------------------------------------------------------------- 3 3 … … 20 20 History file for visualization/modeling 21 21 --------------------------------------- 22 23 1st June 2010 John Allison (modeling-V09-03-03) 24 - G4TrajectoryDrawByParticleID.cc: Set some defaults: 25 Set("gamma", "green"); 26 Set("e-", "red"); 27 Set("e+", "blue"); 28 Set("pi+", "magenta"); 29 Set("pi-", "magenta"); 30 Set("proton", "cyan"); 31 Set("neutron", "yellow"); 22 32 23 33 30th May 2010 John Allison (modeling-V09-03-02) -
trunk/source/visualization/modeling/src/G4TrajectoryDrawByParticleID.cc
r1288 r1315 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4TrajectoryDrawByParticleID.cc,v 1.1 0 2010/05/28 02:00:59allison Exp $27 // GEANT4 tag $Name: $26 // $Id: G4TrajectoryDrawByParticleID.cc,v 1.11 2010/06/01 21:17:41 allison Exp $ 27 // GEANT4 tag $Name: geant4-09-04-beta-cand-01 $ 28 28 // 29 29 // Jane Tinslay, John Allison, Joseph Perl November 2005 … … 38 38 :G4VTrajectoryModel(name, context) 39 39 ,fDefault(G4Colour::Grey()) 40 {} 40 { 41 Set("gamma", "green"); 42 Set("e-", "red"); 43 Set("e+", "blue"); 44 Set("pi+", "magenta"); 45 Set("pi-", "magenta"); 46 Set("proton", "cyan"); 47 Set("neutron", "yellow"); 48 } 41 49 42 50 G4TrajectoryDrawByParticleID::~G4TrajectoryDrawByParticleID() {}
Note: See TracChangeset
for help on using the changeset viewer.