]> SALOME platform Git repositories - modules/visu.git/commitdiff
Salome HOME
IPAL21489 Filter by Scalars... does not show visible elements for some presentations. before_mergefrom_V5_1_3_BR_07Dec09
authordmv <dmv@opencascade.com>
Thu, 3 Dec 2009 14:15:20 +0000 (14:15 +0000)
committerdmv <dmv@opencascade.com>
Thu, 3 Dec 2009 14:15:20 +0000 (14:15 +0000)
doc/salome/gui/VISU/input/viewing_3d_presentations.doc
src/VISUGUI/VISU_msg_en.ts
src/VISU_I/VISU_Prs3d_i.cc

index b4545de605e2ecb19761fe6e01c4ae68cd5bfe76..40ad0203982a3b882a9839beb3fed3cea0ae36af 100644 (file)
@@ -28,6 +28,8 @@ viewer.</li>
 has been created and change its parameters.</li>
 <li><b>Filter by Scalars</b> - allows showing only the cells with
 values that fit into the defined <b>Scalar Range</b>.
+<br>If the presentation is created on nodes, only the cells with all 
+nodes lying in the range defined by the scalar filter will be visible.
 
 \image html viewing2.png
 
index f8fddcb921b9f4d27991bcfe258bd79c350a8b72..7a04f2832b613f370d37d41f94f9ffbb90855087 100644 (file)
@@ -454,6 +454,10 @@ Do you want to enlarge the cache?</translation>
             <source>WRN_NO_AVAILABLE_DATA</source>
             <translation>No Available data in selection</translation>
         </message>
+       <message>
+            <source>WRN_NO_VISIBLE_ELEMENTS</source>
+            <translation>There are no visible elements.</translation>
+        </message>
         <message>
             <source>WRN_STUDY_LOCKED</source>
             <translation>Current Study is locked</translation>
index 620cf98d36caafbc3cd07d9fbc29fcc43c832aab..4f61facd92130fff0c353c5021ce9051f0a2d863 100644 (file)
@@ -33,6 +33,7 @@
 
 #include "SALOME_Event.h"
 #include "SUIT_ResourceMgr.h"
+#include "SUIT_MessageBox.h"
 
 #include <vtkActorCollection.h>
 #include <vtkUnstructuredGrid.h>
@@ -382,8 +383,13 @@ VISU::Prs3d_i
 
   aDataSet->Update();
   static float eps = VTK_LARGE_FLOAT * 0.1 ;
-  if (!aDataSet->GetNumberOfCells())
-    throw std::runtime_error("There are no visible elements");
+  if (!aDataSet->GetNumberOfCells()) {
+    SUIT_MessageBox::warning( 0,
+                              QObject::tr("WRN_VISU"),
+                              QObject::tr("WRN_NO_VISIBLE_ELEMENTS"),
+                              QObject::tr("BUT_OK"));
+    return;
+  }
 
   if (aDataSet->GetLength() > eps)
     throw std::runtime_error("Diagonal of the actor is too large !!!");