typedef vtkSmartPointer<VISU_MergeFilter> PMergeFilter;
typedef vtkSmartPointer<VISU_CommonCellsFilter> PCommonCellsFilter;
- struct TCommonCellsFilterHolder;
- typedef MED::SharedPtr<TCommonCellsFilterHolder> PCommonCellsFilterHolder;
-
-
//---------------------------------------------------------------
typedef vtkSmartPointer<vtkPolyData> PPolyData;
typedef vtkSmartPointer<VISU_AppendPolyData> PAppendPolyData;
using MED::TFloat;
using MED::EBooleen;
+using namespace std;
+
#ifdef _DEBUG_
static int MYDEBUG = 0;
static int MYVALUEDEBUG = 0;
//---------------------------------------------------------------
//! Define a container for VTK representation
- class TPolyDataHolder: public virtual TSizeCounter
+ class VISU_CONVERTOR_EXPORT TPolyDataHolder: public virtual TSizeCounter
{
protected:
mutable PPolyData mySource;
GetUnstructuredGridOutput();
};
- /*!
- This container allow to combine other VTK representation into single one.
- */
- class VISU_CONVERTOR_EXPORT TCommonCellsFilterHolder: public virtual TMemoryCheckIDMapper
- {
- protected:
- mutable PCommonCellsFilter myFilter;
- mutable PMergeFilter myMergeFilter;
- public:
- TCommonCellsFilterHolder();
-
- //! This method allow to create corresponding VTK filter by demand (not at once)
- const PCommonCellsFilter&
- GetFilter() const;
-
- //! Reimplement the TNamedIDMapper::GetUnstructuredGridOutput
- virtual
- vtkUnstructuredGrid*
- GetUnstructuredGridOutput();
-
- virtual
- unsigned long int
- GetMemorySize();
-
- //! if false, TIDCommonCellsFilter - same as TIDMapperFilter
- //! if true, TIDCommonCellsFilter - use VISU_CommonCellsFilter
- bool myIsSpecialKey;
-
- //! Vector of id mappers, which consist of meshonentity in next sequence:
- //! CELL_ENTITY,FACE_ENTITY,EDGE_ENTITY
- PNamedIDMapperMap myMappers;
- };
-
//---------------------------------------------------------------
//! Define a container for VTK representation
/*!
This container allow to combine other VTK representation into single one.
*/
- class TAppendPolyDataHolder: public virtual TMemoryCheckIDMapper
+ class VISU_CONVERTOR_EXPORT TAppendPolyDataHolder: public virtual TMemoryCheckIDMapper
{
protected:
mutable PAppendPolyData myFilter;
/*!
This container allow to assign data to mesh and represent them into single VTK representation
*/
- class TMergeFilterHolder: public virtual TMemoryCheckIDMapper
+ class VISU_CONVERTOR_EXPORT TMergeFilterHolder: public virtual TMemoryCheckIDMapper
{
protected:
mutable PMergeFilter myFilter;
//---------------------------------------------------------------
//! Specialize TIDMapper to provide VTK mapping for MED TIMESTAMP mesh
- struct TUnstructuredGridIDMapperImpl: virtual TMergeFilterHolder,
+ struct VISU_CONVERTOR_EXPORT TUnstructuredGridIDMapperImpl: virtual TMergeFilterHolder,
virtual TUnstructuredGridIDMapper
{
PAppendFilterHolder myIDMapper; //!< Responsible for numbering
//---------------------------------------------------------------
//! Specialize TIDMapper to provide VTK mapping for MED TIMESTAMP mesh
- struct TPolyDataIDMapperImpl: virtual TMergeFilterHolder,
+ struct VISU_CONVERTOR_EXPORT TPolyDataIDMapperImpl: virtual TMergeFilterHolder,
virtual TPolyDataIDMapper
{
PAppendPolyDataHolder myIDMapper; //!< Responsible for numbering
//---------------------------------------------------------------
typedef std::map<EGeometry, PMeshValue> TGeom2MeshValue;
- class TGeom2Value: public virtual TBaseStructure
+ class VISU_CONVERTOR_EXPORT TGeom2Value: public virtual TBaseStructure
{
TGeom2MeshValue myGeom2MeshValue;
public:
#define _VISUPipeline_HXX_
#ifdef WNT
- #if defined VISU_PIPELINE_EXPORTS
- #if defined WIN32
- #define VISU_PIPELINE_EXPORT __declspec( dllexport )
- #else
- #define VISU_PIPELINE_EXPORT
- #endif
- #else
- #if defined WIN32
- #define VISU_PIPELINE_EXPORT __declspec( dllimport )
- #else
- #define VISU_PIPELINE_EXPORT
- #endif
- #endif
+# if defined VISU_PIPELINE_EXPORTS
+# define VISU_PIPELINE_EXPORT __declspec( dllexport )
+# else
+# define VISU_PIPELINE_EXPORT __declspec( dllimport )
+# endif
#else
- #define VISU_PIPELINE_EXPORT
+# define VISU_PIPELINE_EXPORT
#endif
#endif
namespace VISU
{
//----------------------------------------------------------------------------
- void
+ void VISU_PIPELINE_EXPORT
Mul(const vtkFloatingPointType A[3],
vtkFloatingPointType b,
vtkFloatingPointType C[3]); // C = A * b
//----------------------------------------------------------------------------
- void
+ void VISU_PIPELINE_EXPORT
Sub(const vtkFloatingPointType A[3],
const vtkFloatingPointType B[3],
vtkFloatingPointType C[3]); // C = A - B
vtkFloatingPointType theSource);
//! Checks whether the scalar range is the same or not
- bool
+ bool VISU_PIPELINE_EXPORT
CheckIsSameRange(vtkFloatingPointType* theTarget,
vtkFloatingPointType* theSource);
//! Customizes vtkMapper::ShallowCopy
- void
+ void VISU_PIPELINE_EXPORT
CopyMapper(vtkMapper* theTarget,
vtkMapper* theSource,
bool theIsCopyInput);
bool theIsCopyInput);
//! Customizes vtkPolyDataMapper::ShallowCopy
- void
+ void VISU_PIPELINE_EXPORT
CopyPolyDataMapper(vtkPolyDataMapper* theTarget,
vtkPolyDataMapper* theSource,
bool theIsCopyInput);
//! Customizes VISU_OpenGLPointSpriteMapper::ShallowCopy
- void
+ void VISU_PIPELINE_EXPORT
CopyPointSpriteDataMapper(VISU_OpenGLPointSpriteMapper* theTarget,
VISU_OpenGLPointSpriteMapper* theSource,
bool theIsCopyInput);
//----------------------------------------------------------------------------
- void
+ void VISU_PIPELINE_EXPORT
ComputeBoundsParam(vtkDataSet* theDataSet,
vtkFloatingPointType theDirection[3],
vtkFloatingPointType theMinPnt[3],
//----------------------------------------------------------------------------
- void
+ void VISU_PIPELINE_EXPORT
DistanceToPosition(vtkDataSet* theDataSet,
vtkFloatingPointType theDirection[3],
vtkFloatingPointType theDist,
//----------------------------------------------------------------------------
- void
+ void VISU_PIPELINE_EXPORT
PositionToDistance(vtkDataSet* theDataSet,
vtkFloatingPointType theDirection[3],
vtkFloatingPointType thePos[3],
{
SVTK_ViewWindow* aView = VISU::GetActiveViewWindow<SVTK_ViewWindow>();
if (aView == NULL) return;
- if (!myCutLines) return;
+ if (!(bool)myCutLines) return;
if (myPreviewActor != 0) return;
storeToPrsObject(myCutLines);
}
SVTK_ViewWindow* aView = VISU::GetActiveViewWindow<SVTK_ViewWindow>();
if (aView) {
- if (theUpdate && myPreviewCheck->isChecked() && myCutLines) {
+ if (theUpdate && myPreviewCheck->isChecked() && (bool)myCutLines) {
deletePlanes();
createPlanes();
}
myCutLines->SetDisplacement(myPosSpn->value());
SVTK_ViewWindow* aView = VISU::GetActiveViewWindow<SVTK_ViewWindow>();
if (aView) {
- if (theUpdate && myPreviewCheck->isChecked() && myCutLines) {
+ if (theUpdate && myPreviewCheck->isChecked() && (bool)myCutLines) {
deletePlanes();
createPlanes();
}
void VisuGUI_CutLinesDlg::onRotation (double theValue)
{
- if (!myCutLines) return;
+ if (!(bool)myCutLines) return;
SVTK_ViewWindow* aView = VISU::GetActiveViewWindow<SVTK_ViewWindow>();
if (aView) {
if (myPreviewCheck->isChecked()) {
void VisuGUI_CutLinesDlg::onPlanePos (const QString& theValue)
{
- if (!myCutLines) return;
+ if (!(bool)myCutLines) return;
SVTK_ViewWindow* aView = VISU::GetActiveViewWindow<SVTK_ViewWindow>();
if (aView) {
if (myPreviewCheck->isChecked()) {
void VisuGUI_CutPlanesPane::createPlanes()
{
if (VISU::GetActiveViewWindow<SVTK_ViewWindow>() == NULL) return;
- if (!myCutPlanes) return;
+ if (!(bool)myCutPlanes) return;
if (myPreviewActor != 0) return;
vtkAppendPolyData* aPolyData = myCutPlanes->GetSpecificPL()->GetAppendPolyData();
*/
void VisuGUI_CutPlanesPane::DrawTable()
{
- if (!myCutPlanes) return;
+ if (!(bool)myCutPlanes) return;
if (!hasInit) return;
int aNbRows = myPosTable->numRows();
void VisuGUI_CutPlanesPane::onRotation (double theValue)
{
- if (!myCutPlanes) return;
+ if (!(bool)myCutPlanes) return;
if (myPreviewCheck->isChecked()) {
if (SVTK_ViewWindow* vf = VISU::GetActiveViewWindow<SVTK_ViewWindow>()) {
myCutPlanes->SetOrientation(getOrientaion(),getRotation1()*PI/180.,getRotation2()*PI/180.);
#ifndef __VISU_PRS3D_UTILS_H__
#define __VISU_PRS3D_UTILS_H__
+#include "VISU_I.hxx"
+
#include "VISU_Prs3d_i.hh"
#include <vtkTimeStamp.h>
namespace VISU
{
//----------------------------------------------------------------------------
- struct TSetModified: vtkTimeStamp
+ struct VISU_I_EXPORT TSetModified: vtkTimeStamp
{
VISU::Prs3d_i* myPrs3d;
#ifndef __VISU_RESULT_UTILS_H__
#define __VISU_RESULT_UTILS_H__
+#include "VISU_I.hxx"
+
#include "VISU_Result_i.hh"
#include "SALOME_Event.hxx"
namespace VISU
{
//----------------------------------------------------------------------------
- struct TUpdateObjBrowser: public SALOME_Event
+ struct VISU_I_EXPORT TUpdateObjBrowser: public SALOME_Event
{
int myStudyId;
CORBA::Boolean* myIsDone;
//----------------------------------------------------------------------------
- struct TResultManager
+ struct VISU_I_EXPORT TResultManager
{
Result_i* myResult;
//----------------------------------------------------------------------------
- struct TTransactionManager
+ struct VISU_I_EXPORT TTransactionManager
{
_PTR(StudyBuilder) myStudyBuilder;
//----------------------------------------------------------------------------
- QString
+ QString VISU_I_EXPORT
GenerateName(const std::string& theName);
//----------------------------------------------------------------------------
- bool
+ bool VISU_I_EXPORT
SplitName(const std::string& theName,
std::string& theBase,
std::string& theSuffix,
//----------------------------------------------------------------------------
- std::string
+ std::string VISU_I_EXPORT
MakeFileName(const std::string& theName,
const void* thePointer);
//----------------------------------------------------------------------------
- void
+ void VISU_I_EXPORT
BuildEntities(Result_i* theResult,
Result_i::PInput theInput,
CORBA::Boolean* theIsDone,
//----------------------------------------------------------------------------
- void
+ void VISU_I_EXPORT
BuildGroups(Result_i* theResult,
Result_i::PInput theInput,
CORBA::Boolean* theIsDone,
//----------------------------------------------------------------------------
- void
+ void VISU_I_EXPORT
BuildFields(Result_i* theResult,
Result_i::PInput theInput,
CORBA::Boolean* theIsDone,
//----------------------------------------------------------------------------
- void
+ void VISU_I_EXPORT
BuildMinMax(Result_i* theResult,
Result_i::PInput theInput,
CORBA::Boolean* theIsDone,
//----------------------------------------------------------------------------
- void
+ void VISU_I_EXPORT
BuildFieldDataTree(Result_i* theResult,
Result_i::PInput theInput,
CORBA::Boolean* theIsFieldsDone,
_PTR(Study) theStudy);
//----------------------------------------------------------------------------
- bool
+ bool VISU_I_EXPORT
RemoveFile(const std::string& theFileName,
bool theRemoveEmptyDir = true);
//----------------------------------------------------------------------------
- bool
+ bool VISU_I_EXPORT
CopyFile(const std::string& theSourceFileName,
const std::string& theTargetFileName);