Includes of VTK headers are wrapped in #pragmas to ensure that MSVC warning messages disabled by VTK headers are still enabled for OCCT code
#include <IVtkDraw_HighlightAndSelectionPipeline.hxx>
#include <IVtkDraw_Interactor.hxx>
+// prevent disabling some MSVC warning messages by VTK headers
+#ifdef _MSC_VER
+#pragma warning(push)
+#pragma warning(disable: 4244)
+#endif
#include <vtkAlgorithmOutput.h>
#include <vtkAppendPolyData.h>
#include <vtkBMPWriter.h>
#include <vtkSmartPointer.h>
#include <vtkTIFFWriter.h>
#include <vtkWindowToImageFilter.h>
-
#ifndef _WIN32
#include <X11/X.h>
#include <X11/Shell.h>
#include <X11/Xutil.h>
#include <tk.h>
#endif
+#ifdef _MSC_VER
+#pragma warning(pop)
+#endif
// workaround name conflicts with OCCT methods (in class TopoDS_Shape for example)
#ifdef Convex
#include <IVtkDraw_HighlightAndSelectionPipeline.hxx>
+// prevent disabling some MSVC warning messages by VTK headers
+#ifdef _MSC_VER
+#pragma warning(push)
+#endif
#include <vtkRenderer.h>
#include <vtkActor.h>
#include <vtkPolyDataMapper.h>
#include <vtkAppendPolyData.h>
#include <vtkProperty.h>
#include <vtkRenderWindow.h>
+#ifdef _MSC_VER
+#pragma warning(pop)
+#endif
#include <IVtkOCC_Shape.hxx>
#include <IVtkTools_DisplayModeFilter.hxx>
#include <Standard_Transient.hxx>
#include <TopoDS_Shape.hxx>
+// prevent disabling some MSVC warning messages by VTK headers
+#ifdef _MSC_VER
+#pragma warning(push)
+#endif
#include <vtkActor.h>
#include <vtkPolyData.h>
#include <vtkPolyDataMapper.h>
#include <vtkRenderer.h>
#include <vtkSmartPointer.h>
+#ifdef _MSC_VER
+#pragma warning(pop)
+#endif
#include <IVtk_Types.hxx>
#include <IVtkTools_DisplayModeFilter.hxx>
// Alternatively, this file may be used under the terms of Open CASCADE
// commercial license or contractual agreement.
+// prevent disabling some MSVC warning messages by VTK headers
+#ifdef _MSC_VER
+#pragma warning(push)
+#endif
#ifdef _WIN32
-#include <windows.h>
#include <vtkWin32RenderWindowInteractor.h>
#include <vtkWin32OpenGLRenderWindow.h>
+#else
+#include <GL/glx.h>
+#include <vtkXRenderWindowInteractor.h>
+#include <vtkXOpenGLRenderWindow.h>
+#endif
+#include <vtkActor.h>
+#include <vtkActorCollection.h>
+#include <vtkCommand.h>
+#include <vtkObjectFactory.h>
+#include <vtkSmartPointer.h>
+
+#include <IVtkDraw_Interactor.hxx>
+
+#ifdef _MSC_VER
+#pragma warning(pop)
#endif
#include <IVtkTools_ShapePicker.hxx>
#include <IVtkTools_DisplayModeFilter.hxx>
#include <IVtkTools_ShapeObject.hxx>
#include <IVtkTools_ShapeDataSource.hxx>
-#include <IVtkDraw_Interactor.hxx>
#include <Message.hxx>
#include <Message_Messenger.hxx>
-#include <vtkActor.h>
-#include <vtkActorCollection.h>
-#include <vtkCommand.h>
-#include <vtkObjectFactory.h>
-#include <vtkSmartPointer.h>
-
-#ifndef _WIN32
-#include <X11/X.h>
-#include <X11/Shell.h>
-#include <X11/Xlib.h>
-#include <GL/glx.h>
-#include <vtkXRenderWindowInteractor.h>
-#include <vtkXOpenGLRenderWindow.h>
-#include <X11/Xutil.h>
-#include <tk.h>
-#endif
-
//===========================================================
// Function : ClearHighlightAndSelection
// Purpose :
#include <tk.h>
#endif
+// prevent disabling some MSVC warning messages by VTK headers
+#ifdef _MSC_VER
+#pragma warning(push)
+#endif
#include <vtkRenderWindowInteractor.h>
#include <vtkSmartPointer.h>
+#ifdef _MSC_VER
+#pragma warning(pop)
+#endif
+
#include <IVtkTools_ShapePicker.hxx>
#include <IVtkDraw_HighlightAndSelectionPipeline.hxx>
#include <Aspect_Window.hxx>
#include <IVtkTools.hxx>
#include <IVtkVTK_ShapeData.hxx>
+
+// prevent disabling some MSVC warning messages by VTK headers
+#ifdef _MSC_VER
+#pragma warning(push)
+#endif
#include <vtkLookupTable.h>
#include <vtkMapper.h>
+#ifdef _MSC_VER
+#pragma warning(pop)
+#endif
namespace IVtkTools
{
#include <IVtkTools_DisplayModeFilter.hxx>
#include <IVtkVTK_ShapeData.hxx>
+
+// prevent disabling some MSVC warning messages by VTK headers
+#ifdef _MSC_VER
+#pragma warning(push)
+#endif
#include <vtkInformation.h>
#include <vtkInformationVector.h>
#include <vtkObjectFactory.h>
+#ifdef _MSC_VER
+#pragma warning(pop)
+#endif
vtkStandardNewMacro(IVtkTools_DisplayModeFilter)
#include <IVtkOCC_ShapeMesher.hxx>
#include <IVtkTools_ShapeObject.hxx>
-// VTK includes
+// prevent disabling some MSVC warning messages by VTK headers
+#ifdef _MSC_VER
+#pragma warning(push)
+#endif
#include <vtkObjectFactory.h>
#include <vtkCellData.h>
#include <vtkIdTypeArray.h>
#include <vtkPolyData.h>
#include <vtkTransform.h>
#include <vtkTransformPolyDataFilter.h>
+#ifdef _MSC_VER
+#pragma warning(pop)
+#endif
vtkStandardNewMacro(IVtkTools_ShapeDataSource)
#include <IVtkTools_ShapeObject.hxx>
#include <IVtkTools_ShapeDataSource.hxx>
+
+// prevent disabling some MSVC warning messages by VTK headers
+#ifdef _MSC_VER
+#pragma warning(push)
+#endif
#include <vtkActor.h>
#include <vtkObjectFactory.h>
#include <vtkDataSet.h>
#include <vtkInformation.h>
#include <vtkInformationObjectBaseKey.h>
#include <vtkPolyData.h>
+#ifdef _MSC_VER
+#pragma warning(pop)
+#endif
IVtkTools_ShapeObject::KeyPtr IVtkTools_ShapeObject::myKey = 0;
#include <IVtkTools.hxx>
#include <IVtkOCC_Shape.hxx>
+
+// prevent disabling some MSVC warning messages by VTK headers
+#ifdef _MSC_VER
+#pragma warning(push)
+#endif
#include <vtkDataObject.h>
#include <vtkSetGet.h>
#include <vtkWeakPointer.h>
+#ifdef _MSC_VER
+#pragma warning(pop)
+#endif
class vtkActor;
class vtkDataSet;
#include <IVtkTools_ShapePicker.hxx>
#include <IVtkTools_ShapeObject.hxx>
#include <IVtkVTK_View.hxx>
+
+// prevent disabling some MSVC warning messages by VTK headers
+#ifdef _MSC_VER
+#pragma warning(push)
+#endif
#include <vtkCommand.h>
#include <vtkObjectFactory.h>
#include <vtkRenderer.h>
#include <vtkActorCollection.h>
+#ifdef _MSC_VER
+#pragma warning(pop)
+#endif
//! @class IVtkTools_ShapePicker
//! VTK picker implementation for OCCT shapes.
#include <IVtkTools.hxx>
#include <IVtk_Types.hxx>
#include <IVtkOCC_ShapePickerAlgo.hxx>
+
+// prevent disabling some MSVC warning messages by VTK headers
+#ifdef _MSC_VER
+#pragma warning(push)
+#endif
#include <vtkAbstractPropPicker.h>
#include <vtkSmartPointer.h>
+#ifdef _MSC_VER
+#pragma warning(pop)
+#endif
class vtkRenderer;
class vtkActorCollection;
#include <IVtkTools_SubPolyDataFilter.hxx>
#include <IVtkVTK_ShapeData.hxx>
+
+// prevent disabling some MSVC warning messages by VTK headers
+#ifdef _MSC_VER
+#pragma warning(push)
+#endif
#include <vtkCellData.h>
#include <vtkIdList.h>
#include <vtkIdTypeArray.h>
#include <vtkInformation.h>
#include <vtkInformationVector.h>
#include <vtkObjectFactory.h>
-
+#ifdef _MSC_VER
+#pragma warning(pop)
+#endif
vtkStandardNewMacro(IVtkTools_SubPolyDataFilter)
// commercial license or contractual agreement.
#include <IVtkVTK_ShapeData.hxx>
+
+// prevent disabling some MSVC warning messages by VTK headers
+#ifdef _MSC_VER
+#pragma warning(push)
+#endif
#include <vtkCellData.h>
#include <vtkDoubleArray.h>
#include <vtkIdList.h>
#include <vtkIdTypeArray.h>
#include <vtkPoints.h>
#include <vtkPolyData.h>
+#ifdef _MSC_VER
+#pragma warning(pop)
+#endif
IMPLEMENT_STANDARD_RTTIEXT(IVtkVTK_ShapeData,IVtk_IShapeData)
#define __IVTKVTK_SHAPEDATA_H__
#include <IVtk_IShapeData.hxx>
+
+// prevent disabling some MSVC warning messages by VTK headers
+#ifdef _MSC_VER
+#pragma warning(push)
+#endif
#include <vtkPolyData.h>
#include <vtkSmartPointer.h>
+#ifdef _MSC_VER
+#pragma warning(pop)
+#endif
class vtkIdTypeArray;
#include <IVtkVTK_View.hxx>
+
+// prevent disabling some MSVC warning messages by VTK headers
+#ifdef _MSC_VER
+#pragma warning(push)
+#endif
#include <vtkAutoInit.h>
#include <vtkCamera.h>
#include <vtkRenderer.h>
#include <vtkRenderWindow.h>
#include <vtkTransform.h>
+#ifdef _MSC_VER
+#pragma warning(pop)
+#endif
IMPLEMENT_STANDARD_RTTIEXT(IVtkVTK_View,IVtk_IView)