[cgma-dev] r3504 - cgm/trunk/geom/OCC

kraftche at cae.wisc.edu kraftche at cae.wisc.edu
Thu Jan 28 11:42:57 CST 2010


Author: kraftche
Date: 2010-01-28 11:42:57 -0600 (Thu, 28 Jan 2010)
New Revision: 3504

Modified:
   cgm/trunk/geom/OCC/OCCQueryEngine.cpp
   cgm/trunk/geom/OCC/OCCQueryEngine.hpp
Log:
Correctly report OpenCascade version

Modified: cgm/trunk/geom/OCC/OCCQueryEngine.cpp
===================================================================
--- cgm/trunk/geom/OCC/OCCQueryEngine.cpp	2010-01-28 17:32:39 UTC (rev 3503)
+++ cgm/trunk/geom/OCC/OCCQueryEngine.cpp	2010-01-28 17:42:57 UTC (rev 3504)
@@ -13,6 +13,7 @@
 // Creation Date : 7/17/00
 //
 //-------------------------------------------------------------------------
+#include <Standard_Version.hxx>
 #include <Standard_Stream.hxx>
 //#include <Standard_SStream.hxx>
 //#include <Standard_String.hxx>
@@ -116,10 +117,6 @@
 
 OCCQueryEngine* OCCQueryEngine::instance_ = NULL;
 
-const int OCCQueryEngine::OCCQE_MAJOR_VERSION = 6;
-const int OCCQueryEngine::OCCQE_MINOR_VERSION = 2;
-const int OCCQueryEngine::OCCQE_SUBMINOR_VERSION = 0;
-
 typedef std::map<int, TopologyBridge*>::value_type valType;
 int OCCQueryEngine::iTotalTBCreated = 0;
 int OCCQueryEngine::total_coedges = 0;
@@ -177,29 +174,22 @@
 
 int OCCQueryEngine::get_major_version()
 {
-  return OCCQE_MAJOR_VERSION;
+  return OCC_VERSION_MAJOR;
 }
 
 int OCCQueryEngine::get_minor_version()
 {
-  return OCCQE_MINOR_VERSION;
+  return OCC_VERSION_MINOR;
 }
 
 int OCCQueryEngine::get_subminor_version()
 {
-  return OCCQE_SUBMINOR_VERSION;
+  return OCC_VERSION_MAINTENANCE;
 }
 
 CubitString OCCQueryEngine::get_engine_version_string()
 {
-  CubitString version_string = "OCC Geometry Engine version ";
-  version_string += CubitString(get_major_version());
-  version_string += CubitString(".");
-  version_string += CubitString(get_minor_version());
-  version_string += CubitString(".");
-  version_string += CubitString(get_subminor_version());
-  
-  return version_string;
+  return CubitString("OpenCascade ") + OCC_VERSION_STRING;
 }
 
 //================================================================================

Modified: cgm/trunk/geom/OCC/OCCQueryEngine.hpp
===================================================================
--- cgm/trunk/geom/OCC/OCCQueryEngine.hpp	2010-01-28 17:32:39 UTC (rev 3503)
+++ cgm/trunk/geom/OCC/OCCQueryEngine.hpp	2010-01-28 17:42:57 UTC (rev 3504)
@@ -425,10 +425,6 @@
 
   static OCCQueryEngine* instance_;
     //- static pointer to unique instance of this class
-
-  static const int OCCQE_MAJOR_VERSION;
-  static const int OCCQE_MINOR_VERSION;
-  static const int OCCQE_SUBMINOR_VERSION;
 };
 
 // ********** BEGIN INLINE FUNCTIONS          **********



More information about the cgma-dev mailing list