Changeset 606 for trunk/geant4/visualization
- Timestamp:
- Nov 15, 2007, 11:56:03 AM (18 years ago)
- Location:
- trunk/geant4/visualization
- Files:
-
- 10 edited
-
OpenGL/include/G4OpenGLQtViewer.hh (modified) (1 diff)
-
OpenGL/include/G4OpenGLViewer.hh (modified) (3 diffs)
-
OpenGL/include/G4OpenGLWin32Viewer.hh (modified) (2 diffs)
-
OpenGL/include/G4OpenGLXViewer.hh (modified) (2 diffs)
-
OpenGL/src/G4OpenGLImmediateQtViewer.cc (modified) (1 diff)
-
OpenGL/src/G4OpenGLQtExportDialog.cc (modified) (1 diff)
-
OpenGL/src/G4OpenGLQtViewer.cc (modified) (2 diffs)
-
OpenGL/src/G4OpenGLStoredQtViewer.cc (modified) (2 diffs)
-
management/src/G4VisCommandsScene.cc (modified) (5 diffs)
-
management/src/G4VisManager.cc (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/geant4/visualization/OpenGL/include/G4OpenGLQtViewer.hh
r600 r606 25 25 // 26 26 // 27 // $Id: G4OpenGLQtViewer.hh,v 1. 3 2007/11/09 15:03:21 lgarnier Exp $27 // $Id: G4OpenGLQtViewer.hh,v 1.4 2007/11/13 17:48:51 lgarnier Exp $ 28 28 // GEANT4 tag $Name: $ 29 29 // -
trunk/geant4/visualization/OpenGL/include/G4OpenGLViewer.hh
r593 r606 25 25 // 26 26 // 27 // $Id: G4OpenGLViewer.hh,v 1.2 0 2007/05/08 11:04:11 allison Exp $28 // GEANT4 tag $Name: geant4-09-00-ref-01$27 // $Id: G4OpenGLViewer.hh,v 1.21 2007/11/10 14:50:01 allison Exp $ 28 // GEANT4 tag $Name: $ 29 29 // 30 30 // … … 48 48 friend class G4OpenGLImmediateSceneHandler; 49 49 friend class G4OpenGLStoredSceneHandler; 50 friend class G4OpenGLFileSceneHandler; 50 51 friend class G4OpenGLViewerMessenger; 51 52 … … 79 80 G4OpenGLSceneHandler& fOpenGLSceneHandler; 80 81 G4Colour background; //the OpenGL clear colour 82 unsigned int WinSize_x, WinSize_y; 81 83 G4bool 82 84 transparency_enabled, //is alpha blending enabled? -
trunk/geant4/visualization/OpenGL/include/G4OpenGLWin32Viewer.hh
r593 r606 25 25 // 26 26 // 27 // $Id: G4OpenGLWin32Viewer.hh,v 1.1 3 2006/06/29 21:18:20 gunterExp $28 // GEANT4 tag $Name: geant4-09-00-ref-01$27 // $Id: G4OpenGLWin32Viewer.hh,v 1.14 2007/11/10 14:50:01 allison Exp $ 28 // GEANT4 tag $Name: $ 29 29 // 30 30 // … … 55 55 void CreateGLWin32Context (); 56 56 virtual void CreateMainWindow (); 57 protected:58 G4int WinSize_x;59 G4int WinSize_y;60 57 HDC fHDC; 61 58 private: -
trunk/geant4/visualization/OpenGL/include/G4OpenGLXViewer.hh
r593 r606 25 25 // 26 26 // 27 // $Id: G4OpenGLXViewer.hh,v 1.2 7 2007/05/08 11:04:11 allison Exp $28 // GEANT4 tag $Name: geant4-09-00-ref-01$27 // $Id: G4OpenGLXViewer.hh,v 1.28 2007/11/10 14:50:01 allison Exp $ 28 // GEANT4 tag $Name: $ 29 29 // 30 30 // … … 105 105 Pixmap icon_pixmap; 106 106 XSizeHints *size_hints; 107 unsigned int WinSize_x,108 WinSize_y;109 107 Atom Xatom; 110 108 XTextProperty windowName, -
trunk/geant4/visualization/OpenGL/src/G4OpenGLImmediateQtViewer.cc
r599 r606 25 25 // 26 26 // 27 // $Id: G4OpenGLImmediateQtViewer.cc,v 1. 1 2007/09/28 14:44:13lgarnier Exp $27 // $Id: G4OpenGLImmediateQtViewer.cc,v 1.2 2007/11/13 17:48:51 lgarnier Exp $ 28 28 // GEANT4 tag $Name: $ 29 29 // -
trunk/geant4/visualization/OpenGL/src/G4OpenGLQtExportDialog.cc
r599 r606 25 25 // 26 26 // 27 // $Id: G4OpenGLQtExportDialog.cc,v 1. 3 2007/11/09 15:03:21 lgarnier Exp $27 // $Id: G4OpenGLQtExportDialog.cc,v 1.4 2007/11/13 17:48:51 lgarnier Exp $ 28 28 // GEANT4 tag $Name: $ 29 29 // -
trunk/geant4/visualization/OpenGL/src/G4OpenGLQtViewer.cc
r602 r606 25 25 // 26 26 // 27 // $Id: G4OpenGLQtViewer.cc,v 1. 4 2007/11/09 15:03:22lgarnier Exp $27 // $Id: G4OpenGLQtViewer.cc,v 1.6 2007/11/14 11:49:00 lgarnier Exp $ 28 28 // GEANT4 tag $Name: $ 29 29 // … … 1344 1344 1345 1345 if (aFilename.endsWith(".ps")) { 1346 #if QT_VERSION > 0x040200 1346 1347 printer.setOutputFormat(QPrinter::PostScriptFormat); 1347 } else { 1348 #endif 1349 } else { 1350 #if QT_VERSION > 0x040100 1348 1351 printer.setOutputFormat(QPrinter::PdfFormat); 1349 } 1352 #endif 1353 } 1354 #if QT_VERSION > 0x040100 1350 1355 printer.setOutputFileName(aFilename); 1356 #endif 1351 1357 // printer.setFullPage ( true); 1352 1358 QPainter paint(&printer); -
trunk/geant4/visualization/OpenGL/src/G4OpenGLStoredQtViewer.cc
r601 r606 25 25 // 26 26 // 27 // $Id: G4OpenGLStoredQtViewer.cc,v 1. 3 2007/11/09 15:03:22lgarnier Exp $27 // $Id: G4OpenGLStoredQtViewer.cc,v 1.5 2007/11/14 18:58:59 lgarnier Exp $ 28 28 // GEANT4 tag $Name: $ 29 29 // … … 256 256 void G4OpenGLStoredQtViewer::mouseMoveEvent(QMouseEvent *event) 257 257 { 258 printf("G4OpenGLStoredQtViewer::mouseMoveEvent\n"); 259 #if QT_VERSION < 0x040000 258 260 G4MouseMoveEvent(event->x(),event->y(),event->button()); 261 #else 262 G4MouseMoveEvent(event->x(),event->y(),event->buttons()); 263 #endif 259 264 // DrawView(); 260 265 } -
trunk/geant4/visualization/management/src/G4VisCommandsScene.cc
r593 r606 25 25 // 26 26 // 27 // $Id: G4VisCommandsScene.cc,v 1.6 6 2007/05/25 10:49:55allison Exp $28 // GEANT4 tag $Name: geant4-09-00-ref-01$27 // $Id: G4VisCommandsScene.cc,v 1.67 2007/11/10 15:03:56 allison Exp $ 28 // GEANT4 tag $Name: $ 29 29 30 30 // /vis/scene commands - John Allison 9th August 1998 … … 34 34 #include "G4VisManager.hh" 35 35 #include "G4TransportationManager.hh" 36 #include "G4RunManager.hh" 37 #include "G4Run.hh" 36 38 #include "G4PhysicalVolumeModel.hh" 37 39 #include "G4ApplicationState.hh" … … 202 204 fpVisManager->ResetTransientsDrawnFlags(); 203 205 206 // Are there any events currently kept... 207 size_t nCurrentlyKept = 0; 208 G4RunManager* runManager = G4RunManager::GetRunManager(); 209 if (runManager) { 210 const G4Run* currentRun = runManager->GetCurrentRun(); 211 if (currentRun) { 212 const std::vector<const G4Event*>* events = 213 currentRun->GetEventVector(); 214 if (events) nCurrentlyKept = events->size(); 215 } 216 } 217 204 218 if (verbosity >= G4VisManager::confirmations) { 205 219 G4cout << "End of event action set to "; … … 211 225 << " (unlimited if negative)." 212 226 "\n This may be changed with, e.g., " 213 "\"/vis/scene/endOfEventAction accumulate 100\"." 214 << G4endl; 215 } 216 } 227 "\"/vis/scene/endOfEventAction accumulate 1000\"."; 228 } 229 G4cout << G4endl; 230 } 231 217 232 if (!pScene->GetRefreshAtEndOfEvent() && 218 233 maxNumberOfKeptEvents != 0 && 219 234 verbosity >= G4VisManager::warnings) { 220 G4cout << "WARNING: The vis manager will keep "; 221 if (maxNumberOfKeptEvents < 0) G4cout << "an unlimited number of"; 222 else G4cout << "up to " << maxNumberOfKeptEvents; 223 G4cout << " events."; 224 if (maxNumberOfKeptEvents > 1 || maxNumberOfKeptEvents < 0) 225 G4cout << "\n This may use a lot of memory."; 235 G4cout << "WARNING: "; 236 if (nCurrentlyKept) { 237 G4cout << 238 "\n There are currently " << nCurrentlyKept 239 << " events kept for refreshing and/or reviewing."; 240 } else { 241 G4cout << "The vis manager will keep "; 242 if (maxNumberOfKeptEvents < 0) G4cout << "an unlimited number of"; 243 else G4cout << "up to " << maxNumberOfKeptEvents; 244 G4cout << " events."; 245 if (maxNumberOfKeptEvents > 1 || maxNumberOfKeptEvents < 0) 246 G4cout << "\n This may use a lot of memory."; 247 } 226 248 G4cout << G4endl; 227 249 } 228 UpdateVisManagerScene (pScene->GetName());229 250 } 230 251 … … 316 337 G4cout << "\"" << G4endl; 317 338 } 318 UpdateVisManagerScene (pScene->GetName());319 339 } 320 340 -
trunk/geant4/visualization/management/src/G4VisManager.cc
r593 r606 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4VisManager.cc,v 1.11 3 2007/05/25 10:50:26 allison Exp $27 // GEANT4 tag $Name: geant4-09-00-ref-01$26 // $Id: G4VisManager.cc,v 1.114 2007/11/10 14:59:46 allison Exp $ 27 // GEANT4 tag $Name: $ 28 28 // 29 29 // … … 1244 1244 G4cout << 1245 1245 " Only useful if before starting the run:" 1246 "\n a) trajectories are stored (\"/ tracking/storeTrajectory N\"), or"1246 "\n a) trajectories are stored (\"/vis/scene/add/trajectories [smooth|rich]\"), or" 1247 1247 "\n b) the Draw method of any hits is implemented." 1248 1248 "\n To view trajectories and hits:" 1249 1249 "\n open a viewer, draw a volume, \"/vis/scene/add/trajectories\"" 1250 1250 "\n \"/vis/scene/add/hits\" and, possibly, \"/vis/viewer/flush\"." 1251 "\n To see all events: \" vis/scene/endOfEventAction accumulate\"."1251 "\n To see all events: \"/vis/scene/endOfEventAction accumulate\"." 1252 1252 "\n To see events individually: \"/vis/reviewKeptEvents\"." 1253 1253 << G4endl;
Note:
See TracChangeset
for help on using the changeset viewer.
