Changeset 866
- Timestamp:
- Oct 15, 2008, 2:48:57 PM (16 years ago)
- Location:
- trunk/source/visualization/OpenGL
- Files:
-
- 10 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/visualization/OpenGL/History
r862 r866 1 $Id: History,v 1.11 7 2008/10/02 08:56:45lgarnier Exp $1 $Id: History,v 1.118 2008/10/15 10:33:27 lgarnier Exp $ 2 2 ------------------------------------------------------------------- 3 3 … … 20 20 History file for visualization/OpenGL 21 21 ------------------------------------- 22 23 12th October Laurent Garnier 24 - G4OpenGLQtExportDialog : improvments for Qt3" 25 - G4OpenGLQtViewer,G4OpenGLImmediateQtViewer,G4OpenGLStoreQtViewer : Add the name on OpenGlQt viewers 26 - G4OpenGLStoredQtViewer,G4OpenGLImmediateQt, G4OpenGLStoredQt : Change OGLSQT and OGLIQT by OGLSQt and OGLIQt 22 27 23 28 2 October Laurent Garnier -
trunk/source/visualization/OpenGL/include/G4OpenGLQtExportDialog.hh
r704 r866 25 25 // 26 26 // 27 // $Id: G4OpenGLQtExportDialog.hh,v 1. 5 2008/01/30 10:54:13lgarnier Exp $27 // $Id: G4OpenGLQtExportDialog.hh,v 1.6 2008/10/15 10:16:17 lgarnier Exp $ 28 28 // GEANT4 tag $Name: 29 29 // … … 36 36 37 37 #include <qdialog.h> 38 #include <qobject.h> 38 39 39 40 class QButtonGroup; -
trunk/source/visualization/OpenGL/include/G4OpenGLQtMovieDialog.hh
r863 r866 25 25 // 26 26 // 27 // $Id: G4OpenGLQtMovieDialog.hh,v 1. 3 2008/10/07 01:03:04lgarnier Exp $27 // $Id: G4OpenGLQtMovieDialog.hh,v 1.4 2008/10/07 05:36:11 lgarnier Exp $ 28 28 // GEANT4 tag $Name: 29 29 // … … 79 79 80 80 public slots : 81 void checkAllParameters();82 81 void stopFinishClose(); 83 82 void save(); -
trunk/source/visualization/OpenGL/include/G4OpenGLQtViewer.hh
r857 r866 25 25 // 26 26 // 27 // $Id: G4OpenGLQtViewer.hh,v 1.1 0 2008/06/20 13:55:06lgarnier Exp $28 // GEANT4 tag $Name: HEAD$27 // $Id: G4OpenGLQtViewer.hh,v 1.12 2008/10/15 10:24:04 lgarnier Exp $ 28 // GEANT4 tag $Name: $ 29 29 // 30 30 // … … 105 105 protected: 106 106 void CreateGLQtContext (); 107 virtual void CreateMainWindow (QGLWidget* );107 virtual void CreateMainWindow (QGLWidget*,QString); 108 108 void manageContextMenuEvent(QContextMenuEvent *e); 109 109 #if QT_VERSION < 0x040000 -
trunk/source/visualization/OpenGL/src/G4OpenGLImmediateQt.cc
r850 r866 25 25 // 26 26 // 27 // $Id: G4OpenGLImmediateQt.cc,v 1. 2 2007/11/15 18:24:28lgarnier Exp $28 // GEANT4 tag $Name: HEAD$27 // $Id: G4OpenGLImmediateQt.cc,v 1.3 2008/10/15 10:26:25 lgarnier Exp $ 28 // GEANT4 tag $Name: $ 29 29 // 30 30 // … … 43 43 G4OpenGLImmediateQt::G4OpenGLImmediateQt (): 44 44 G4VGraphicsSystem ("OpenGLImmediateQt", 45 "OGLIQ T",45 "OGLIQt", 46 46 G4VisFeaturesOfOpenGLIQt (), 47 47 G4VGraphicsSystem::threeD) -
trunk/source/visualization/OpenGL/src/G4OpenGLImmediateQtViewer.cc
r850 r866 25 25 // 26 26 // 27 // $Id: G4OpenGLImmediateQtViewer.cc,v 1. 4 2008/01/15 11:05:08lgarnier Exp $28 // GEANT4 tag $Name: HEAD$27 // $Id: G4OpenGLImmediateQtViewer.cc,v 1.5 2008/10/15 10:24:04 lgarnier Exp $ 28 // GEANT4 tag $Name: $ 29 29 // 30 30 // … … 75 75 #endif 76 76 77 CreateMainWindow (this);77 CreateMainWindow (this,QString(fName)); 78 78 #ifdef GEANT4_QT_DEBUG 79 79 printf("G4OpenGLImmediateQtViewer::Initialise () 3\n"); -
trunk/source/visualization/OpenGL/src/G4OpenGLQtViewer.cc
r863 r866 25 25 // 26 26 // 27 // $Id: G4OpenGLQtViewer.cc,v 1.2 4 2008/06/20 13:55:06lgarnier Exp $28 // GEANT4 tag $Name: HEAD$27 // $Id: G4OpenGLQtViewer.cc,v 1.26 2008/10/07 03:39:47 lgarnier Exp $ 28 // GEANT4 tag $Name: $ 29 29 // 30 30 // … … 167 167 void G4OpenGLQtViewer::CreateMainWindow ( 168 168 QGLWidget* glWidget 169 ,QString name 169 170 ) 170 171 ////////////////////////////////////////////////////////////////////////////// … … 235 236 236 237 #if QT_VERSION < 0x040000 237 GLWindow->setCaption( tr( "QGl Viewer" ));238 GLWindow->setCaption(name ); 238 239 #else 239 240 GLWindow->setLayout(mainLayout); 240 GLWindow->setWindowTitle( tr("QGl Viewer"));241 #endif 242 GLWindow->resize( 300, 300);241 GLWindow->setWindowTitle( name); 242 #endif 243 GLWindow->resize(fVP.GetWindowSizeHintX(), fVP.GetWindowSizeHintY()); 243 244 GLWindow->move(900,300); 244 245 GLWindow->show(); … … 1057 1058 } else if (fMouseAction == STYLE3) { //pick 1058 1059 G4cout << "Click and pick " << G4endl; 1060 } else { 1061 G4cout << "Move camera point of view with mouse" << G4endl; 1062 G4cout << "Press left/right arrows to move volume left/right" << G4endl; 1063 G4cout << "Press up/down arrows to move volume up/down" << G4endl; 1064 G4cout << "Press ALT+up/down arrows to move volume toward/forward" << G4endl; 1065 G4cout << "Press SHIFT+left/right arrows to rotate volume left/right" << G4endl; 1066 G4cout << "Press SHIFT+up/down arrows to rotate volume up/down" << G4endl; 1067 G4cout << "Press +/- to zoom into volume" << G4endl; 1068 G4cout << "Press ALT+/- to slow/speed auto rotation/move" << G4endl; 1069 G4cout << "In video mode : " << G4endl; 1070 G4cout << " Press SPACE to Start/Pause video recording " << G4endl; 1071 G4cout << " Press RETURN to Stop video recording " << G4endl; 1059 1072 } 1060 1073 … … 1885 1898 #else 1886 1899 bool alpha = aImage.hasAlphaChannel(); 1900 #endif 1887 1901 for(int y=height-1; y >=0 ; y--) { 1888 1902 QRgb * s = (QRgb*)(aImage.scanLine(y)); … … 1904 1918 fprintf (fp, "\n"); 1905 1919 } 1906 #endif1907 1920 1908 1921 } … … 2769 2782 2770 2783 setRecordingInfos("Parameter file "+fParameterFileName+" generated in "+fMovieTempFolderPath); 2771 printf("Parameter file %s generated in %s\n",fParameterFileName.toStdString().c_str(),fMovieTempFolderPath.toStdString().c_str());2772 2784 setRecordingStatus(READY_TO_ENCODE); 2773 2785 return true; -
trunk/source/visualization/OpenGL/src/G4OpenGLStoredQt.cc
r864 r866 25 25 // 26 26 // 27 // $Id: G4OpenGLStoredQt.cc,v 1. 6 2008/10/07 05:28:49lgarnier Exp $27 // $Id: G4OpenGLStoredQt.cc,v 1.7 2008/10/15 10:26:25 lgarnier Exp $ 28 28 // GEANT4 tag $Name: $ 29 29 // … … 45 45 G4OpenGLStoredQt::G4OpenGLStoredQt (): 46 46 G4VGraphicsSystem ("OpenGLStoredQt", 47 "OGLSQ T",47 "OGLSQt", 48 48 G4VisFeaturesOfOpenGLSQt (), 49 49 G4VGraphicsSystem::threeD) -
trunk/source/visualization/OpenGL/src/G4OpenGLStoredQtViewer.cc
r863 r866 25 25 // 26 26 // 27 // $Id: G4OpenGLStoredQtViewer.cc,v 1.1 5 2008/06/20 13:55:06lgarnier Exp $28 // GEANT4 tag $Name: HEAD$27 // $Id: G4OpenGLStoredQtViewer.cc,v 1.18 2008/10/15 10:29:39 lgarnier Exp $ 28 // GEANT4 tag $Name: $ 29 29 // 30 30 // … … 52 52 { 53 53 // if no scene... 54 if (fSceneHandler.GetScene() == 0) {55 G4cerr << "G4OpenGLStoredQtViewer: Creating a Viewer without a scene is not allowed. \nPlease use /vis/scene/create before /vis/open/.... "56 << G4endl;57 return;58 }54 // if (fSceneHandler.GetScene() == 0) { 55 // G4cerr << "G4OpenGLStoredQtViewer: Creating a Viewer without a scene is not allowed. \nPlease use /vis/scene/create before /vis/open/.... " 56 // << G4endl; 57 // return; 58 // } 59 59 60 60 //set true to picking … … 93 93 printf("G4OpenGLStoredQtViewer::Initialise () 2\n"); 94 94 #endif 95 CreateMainWindow (this );95 CreateMainWindow (this,QString(fName)); 96 96 #ifdef GEANT4_QT_DEBUG 97 97 printf("G4OpenGLStoredQtViewer::Initialise () 3\n"); … … 121 121 glDepthMask (GL_TRUE); 122 122 123 hasToRepaint =true; 123 if (fSceneHandler.GetScene() == 0) { 124 hasToRepaint =false; 125 } else { 126 hasToRepaint =true; 127 } 124 128 125 129 #ifdef GEANT4_QT_DEBUG -
trunk/source/visualization/OpenGL/src/G4OpenGLStoredSceneHandler.cc
r850 r866 104 104 if (fMemoryForDisplayLists) { 105 105 fDisplayListId = glGenLists (1); 106 if ( !fDisplayListId) { // Could pre-allocate?106 if (glGetError() == GL_OUT_OF_MEMORY) { // Could pre-allocate? 107 107 G4cout << 108 108 "********************* WARNING! ********************" … … 172 172 } 173 173 174 if ((glGetError() == GL_TABLE_TOO_LARGE) || (glGetError() == GL_OUT_OF_MEMORY)) { // Could close? 175 G4cout << 176 "ERROR: G4OpenGLStoredSceneHandler::EndModeling: Failure to allocate" 177 " display List for fTopPODL - try OpenGL Immediated mode." 178 << G4endl; 179 } 174 180 if (fMemoryForDisplayLists) { 175 181 glEndList(); 182 if (glGetError() == GL_OUT_OF_MEMORY) { // Could close? 183 G4cout << 184 "ERROR: G4OpenGLStoredSceneHandler::EndModeling: Failure to allocate" 185 " display List for fTopPODL - try OpenGL Immediated mode." 186 << G4endl; 187 } 176 188 } 177 189 if (fReadyForTransients || !fMemoryForDisplayLists) { … … 283 295 // Make a List which calls the other lists. 284 296 fTopPODL = glGenLists (1); 285 if ( !fTopPODL) {297 if (glGetError() == GL_OUT_OF_MEMORY) { // Could pre-allocate? 286 298 G4cout << 287 299 "ERROR: G4OpenGLStoredSceneHandler::EndModeling: Failure to allocate" … … 301 313 } 302 314 glEndList (); 315 if (glGetError() == GL_OUT_OF_MEMORY) { // Could close? 316 G4cout << 317 "ERROR: G4OpenGLStoredSceneHandler::EndModeling: Failure to allocate" 318 " display List for fTopPODL - try OpenGL Immediated mode." 319 << G4endl; 320 } 303 321 } 304 322
Note: See TracChangeset
for help on using the changeset viewer.