]> SALOME platform Git repositories - modules/gui.git/commitdiff
Salome HOME
OCCT dev version porting (6.7.2)
authorskv <skv@opencascade.com>
Wed, 9 Jul 2014 13:21:54 +0000 (17:21 +0400)
committerskv <skv@opencascade.com>
Wed, 9 Jul 2014 13:21:54 +0000 (17:21 +0400)
src/DDS/DDS.h
src/DDS/DDS_DicGroup.h
src/DDS/DDS_DicItem.h
src/OCCViewer/OCCViewer_Trihedron.cxx [changed mode: 0755->0644]
src/OCCViewer/OCCViewer_Trihedron.h

index f6530348d8cf6452853e1c967df6b63323011f2d..2d59c983d3503037bc2f552853225dfc4dbe5e6f 100644 (file)
@@ -26,7 +26,6 @@
 #include <TCollection_AsciiString.hxx>
 
 #include <NCollection_DefineDataMap.hxx>
-#include <NCollection_DefineBaseCollection.hxx>
 
 #define UNIT_SYSTEM_SI "SI"
 
@@ -34,6 +33,4 @@ typedef enum { DDS_MT_OK, DDS_MT_WARNING,
                DDS_MT_ERROR, DDS_MT_ALARM,
                DDS_MT_INFO, DDS_MT_NONE } DDS_MsgType;
 
-DEFINE_BASECOLLECTION(DDS_BaseColOfAsciiString,TCollection_AsciiString)
-
 #endif
index e8480beb88f1e7370900d04159c1808f7e233425..5822d8afbdd95b64a45bfc0b3b11e8d76dc85df8 100644 (file)
@@ -92,8 +92,6 @@ public:
   DEFINE_STANDARD_RTTI(DDS_DicGroup)
 };
 
-DEFINE_BASECOLLECTION(DDS_BaseCollectionOfDicGroups, Handle(DDS_DicGroup))
-DEFINE_INDEXEDDATAMAP(DDS_IndexedDataMapOfDicGroups, DDS_BaseCollectionOfDicGroups,
-                      TCollection_AsciiString, Handle(DDS_DicGroup))
+typedef NCollection_IndexedDataMap<TCollection_AsciiString, Handle(DDS_DicGroup)> DDS_IndexedDataMapOfDicGroups;
 
 #endif
index fa1f9db9ca79a3c402dcb69d9e3b0fc2e5c1d157..a7fbcaeb984011395c763800c8200c83f8b1975a 100644 (file)
@@ -258,8 +258,6 @@ public:
 
 DEFINE_STANDARD_HANDLE(DDS_DicItem, MMgt_TShared)
 
-DEFINE_BASECOLLECTION(DDS_BaseCollectionOfDicItems, Handle(DDS_DicItem))
-DEFINE_INDEXEDDATAMAP(DDS_IndexedDataMapOfDicItems, DDS_BaseCollectionOfDicItems,
-                      TCollection_AsciiString, Handle(DDS_DicItem))
+typedef NCollection_IndexedDataMap<TCollection_AsciiString, Handle(DDS_DicItem)> DDS_IndexedDataMapOfDicItems;
 
 #endif
old mode 100755 (executable)
new mode 100644 (file)
index 6ffb841..14ac128
@@ -69,11 +69,21 @@ OCCViewer_Trihedron::~OCCViewer_Trihedron()
 /*!
  * Sets the bounding box (MinMax values).
  */
+#if OCC_VERSION_LARGE > 0x06070100 // for OCC-6.7.2 and higher version
+void OCCViewer_Trihedron::bounds( Graphic3d_BndBox4f& theMinMax ) const
+{
+  Graphic3d_Vec4 aMinPt (-1.f, -1.f, -1.f, 1.f);
+  Graphic3d_Vec4 aMaxPt (1.f, 1.f, 1.f, 1.f);
+
+  theMinMax.Add (aMinPt);
+  theMinMax.Add (aMaxPt);
+}
+#else
 void OCCViewer_Trihedron::bounds( Graphic3d_CBounds& aMinMax ) const
 {
   Standard_Real aXMin = -1, aYMin = -1, aZMin = -1;
   Standard_Real aXMax =  1, aYMax =  1, aZMax =  1;
-  
+
   if( aMinMax.XMin > aXMin ) aMinMax.XMin = aXMin;
   if( aMinMax.YMin > aYMin ) aMinMax.YMin = aYMin;
   if( aMinMax.ZMin > aZMin ) aMinMax.ZMin = aZMin;
@@ -81,6 +91,7 @@ void OCCViewer_Trihedron::bounds( Graphic3d_CBounds& aMinMax ) const
   if( aMinMax.YMax < aYMax ) aMinMax.YMax = aYMax;
   if( aMinMax.ZMax < aZMax ) aMinMax.ZMax = aZMax;
 }
+#endif
 
 /*!
  * Redefined method. Calculates the object presentation.
index 6cddc578dd23e868feb83777e64db78a01483b25..72c7382b5047872a9f9c11a950120e1d0bddf884 100644 (file)
 #include "OCCViewer.h"
 
 #include <AIS_InteractiveObject.hxx>
-#include <Graphic3d_CBounds.hxx>
+#include <Basics_OCCTVersion.hxx>
+#if OCC_VERSION_LARGE > 0x06070100 // for OCC-6.7.2 and higher version
+  #include <Graphic3d_BndBox4f.hxx>
+#else
+  #include <Graphic3d_CBounds.hxx>
+#endif
 #include <Standard_DefineHandle.hxx>
 
 /*!
@@ -43,7 +48,11 @@ public:
   virtual void           ComputeSelection( const Handle( SelectMgr_Selection )&,
                                            const Standard_Integer );
 
+#if OCC_VERSION_LARGE > 0x06070100
+  virtual void           bounds( Graphic3d_BndBox4f& ) const;
+#else
   virtual void           bounds( Graphic3d_CBounds& ) const;
+#endif
 
   virtual void           display();