]> SALOME platform Git repositories - modules/gui.git/commitdiff
Salome HOME
Fix for Bug NPAL16976 T_24092007 T_reliquat_2007
authorapo <apo@opencascade.com>
Thu, 20 Sep 2007 09:55:33 +0000 (09:55 +0000)
committerapo <apo@opencascade.com>
Thu, 20 Sep 2007 09:55:33 +0000 (09:55 +0000)
  bug in appearance of polyhedron in VTK viewer after debug NPAL16814.

The bug was fixed by introduction one additianal line of code, namely -
  myPoints->Modified(); // the VTK bug

src/VTKViewer/VTKViewer_ConvexTool.cxx

index 04c68d127c8c97c053cf2f95579496a0657158ad..6d08b21a6ae63da3c369ce1566036321ebe67667 100644 (file)
@@ -108,6 +108,8 @@ VTKViewer_Triangulator
             vtkIdType theCellId)
 {
   myPoints->Reset();
+  myPoints->Modified(); // the VTK bug
+
   vtkIdType aNumPts;
   theInput->GetCellPoints(theCellId, aNumPts, myPointIds); 
   if ( aNumPts > 0 ) {
@@ -231,7 +233,7 @@ VTKViewer_Triangulator
 
   static vtkFloatingPointType EPS = 1.0E-2;
   vtkFloatingPointType aDistEps = aCellLength/3.0 * EPS;
-  if(DEBUG_TRIA_EXECUTE) cout<<"\taCellLength = "<<aCellLength<<"; aDistEps = "<<aDistEps<<"\n";
+  if(DEBUG_TRIA_EXECUTE) cout<<"\taNumFaces = "<<aNumFaces<<"; aCellLength = "<<aCellLength<<"; aDistEps = "<<aDistEps<<"\n";
 
   // To initialize set of points that belong to the cell
   typedef std::set<vtkIdType> TPointIds;
@@ -397,9 +399,9 @@ VTKViewer_Triangulator
            aCenter[0] += aPntCoord[0];
            aCenter[1] += aPntCoord[1];
            aCenter[2] += aPntCoord[2];
-           if(DEBUG_TRIA_EXECUTE) cout  << "Added = TRUE" << endl;
+           if(DEBUG_TRIA_EXECUTE) cout  << "Added = TRUE" << endl;
          } else {
-           if(DEBUG_TRIA_EXECUTE) cout  << "Added = FALSE" << endl;
+           if(DEBUG_TRIA_EXECUTE) cout  << "Added = FALSE" << endl;
          }
        }
        int aNbPoints = aPointIds.size();