mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2024-11-12 00:29:17 +05:00
Integrate patch from G.David (for vtk 5.2 and newer)
This commit is contained in:
parent
f1bc3e4413
commit
bf9d590cda
@ -404,9 +404,7 @@ SMESH_ActorDef::SMESH_ActorDef()
|
|||||||
|
|
||||||
myPtsLabeledDataMapper = vtkLabeledDataMapper::New();
|
myPtsLabeledDataMapper = vtkLabeledDataMapper::New();
|
||||||
myPtsLabeledDataMapper->SetInput(myPtsSelectVisiblePoints->GetOutput());
|
myPtsLabeledDataMapper->SetInput(myPtsSelectVisiblePoints->GetOutput());
|
||||||
#if (VTK_XVERSION >= 0x050200)
|
#if (VTK_XVERSION < 0x050200)
|
||||||
myPtsLabeledDataMapper->SetLabelFormat("%d");
|
|
||||||
#else
|
|
||||||
myPtsLabeledDataMapper->SetLabelFormat("%g");
|
myPtsLabeledDataMapper->SetLabelFormat("%g");
|
||||||
#endif
|
#endif
|
||||||
myPtsLabeledDataMapper->SetLabelModeToLabelScalars();
|
myPtsLabeledDataMapper->SetLabelModeToLabelScalars();
|
||||||
@ -449,9 +447,7 @@ SMESH_ActorDef::SMESH_ActorDef()
|
|||||||
|
|
||||||
myClsLabeledDataMapper = vtkLabeledDataMapper::New();
|
myClsLabeledDataMapper = vtkLabeledDataMapper::New();
|
||||||
myClsLabeledDataMapper->SetInput(myClsSelectVisiblePoints->GetOutput());
|
myClsLabeledDataMapper->SetInput(myClsSelectVisiblePoints->GetOutput());
|
||||||
#if (VTK_XVERSION >= 0x050200)
|
#if (VTK_XVERSION < 0x050200)
|
||||||
myClsLabeledDataMapper->SetLabelFormat("%d");
|
|
||||||
#else
|
|
||||||
myClsLabeledDataMapper->SetLabelFormat("%g");
|
myClsLabeledDataMapper->SetLabelFormat("%g");
|
||||||
#endif
|
#endif
|
||||||
myClsLabeledDataMapper->SetLabelModeToLabelScalars();
|
myClsLabeledDataMapper->SetLabelModeToLabelScalars();
|
||||||
|
@ -73,6 +73,10 @@
|
|||||||
#include <vtkIntArray.h>
|
#include <vtkIntArray.h>
|
||||||
#include <vtkProperty2D.h>
|
#include <vtkProperty2D.h>
|
||||||
#include <vtkPointData.h>
|
#include <vtkPointData.h>
|
||||||
|
#include <vtkConfigure.h>
|
||||||
|
#if !defined(VTK_XVERSION)
|
||||||
|
#define VTK_XVERSION (VTK_MAJOR_VERSION<<16)+(VTK_MINOR_VERSION<<8)+(VTK_BUILD_VERSION)
|
||||||
|
#endif
|
||||||
|
|
||||||
// Qt includes
|
// Qt includes
|
||||||
#include <QApplication>
|
#include <QApplication>
|
||||||
@ -145,7 +149,9 @@ namespace SMESH
|
|||||||
|
|
||||||
myPtsLabeledDataMapper = vtkLabeledDataMapper::New();
|
myPtsLabeledDataMapper = vtkLabeledDataMapper::New();
|
||||||
myPtsLabeledDataMapper->SetInput(myPtsSelectVisiblePoints->GetOutput());
|
myPtsLabeledDataMapper->SetInput(myPtsSelectVisiblePoints->GetOutput());
|
||||||
|
#if (VTK_XVERSION < 0x050200)
|
||||||
myPtsLabeledDataMapper->SetLabelFormat("%g");
|
myPtsLabeledDataMapper->SetLabelFormat("%g");
|
||||||
|
#endif
|
||||||
myPtsLabeledDataMapper->SetLabelModeToLabelScalars();
|
myPtsLabeledDataMapper->SetLabelModeToLabelScalars();
|
||||||
|
|
||||||
vtkTextProperty* aPtsTextProp = vtkTextProperty::New();
|
vtkTextProperty* aPtsTextProp = vtkTextProperty::New();
|
||||||
|
Loading…
Reference in New Issue
Block a user