Salome HOME
Fix for the bug IPAL22854: preview is wrong for Create a new mesh
[modules/smesh.git] / src / SMESHGUI / SMESHGUI_MeshEditPreview.cxx
index dad1047e1837a290491ce7afa034e2b05ef9b714..85ba45195287268b8be7692f592dbe3c15315dae 100644 (file)
@@ -73,6 +73,11 @@ SMESHGUI_MeshEditPreview::SMESHGUI_MeshEditPreview(SVTK_ViewWindow* theViewWindo
   myPreviewActor->VisibilityOn();
   myPreviewActor->PickableOff();
 
+  vtkFloatingPointType aFactor,aUnits;
+  myPreviewActor->SetResolveCoincidentTopology(true);
+  myPreviewActor->GetPolygonOffsetParameters(aFactor,aUnits);
+  myPreviewActor->SetPolygonOffsetParameters(aFactor,0.2*aUnits);
+
   vtkFloatingPointType anRGB[3];
   SMESH::GetColor( "SMESH", "selection_element_color", anRGB[0], anRGB[1], anRGB[2], QColor( 0, 170, 255 ) );
   SetColor( anRGB[0], anRGB[1], anRGB[2] );