]> Creatis software - creaVtk.git/commitdiff
#3470 merge vtk8itk5wx3-mingw64
authorEduardo DAVILA <davila@creatis.insa-lyon.fr>
Thu, 16 Sep 2021 12:13:17 +0000 (14:13 +0200)
committerEduardo DAVILA <davila@creatis.insa-lyon.fr>
Thu, 16 Sep 2021 12:13:17 +0000 (14:13 +0200)
bbtk_creaVtk_PKG/src/bbcreaVtkReadMHDPlane.cxx
lib/creaVtk/vtkTensorsVisu.cpp
lib/creaVtk/vtkVectorsVisu.cpp

index e9634ee8169fbe19093cf0279f4ee95048cb31c0..cfa8d83d0f47cf3efeedd5c6e261e5d3e281c31f 100644 (file)
@@ -251,9 +251,14 @@ void ReadMHDPlane::Read64lseek(std::string fileNameIn, std::string plane)
                long long       pos;
                long long lsize                 = dimX*dimY*width *dataSize;
 #if defined(_WIN32)
-                  _sopen_s( &fd, filename.c_str(), _O_RDONLY, _SH_DENYNO, 0 );
+            _sopen_s( &fd, filename.c_str(), _O_RDONLY, _SH_DENYNO, 0 );
 #else
-               fd = open ( filename.c_str() ,  O_RDONLY|O_LARGEFILE );
+        //EED2021-09-03
+        #if defined(MACOSX)
+            fd = open ( filename.c_str() ,  O_RDONLY );
+        #else
+            fd = open ( filename.c_str() ,  O_RDONLY|O_LARGEFILE );
+        #endif
 #endif // defined(_WIN32)
                if (fd < 0)
                {
@@ -285,7 +290,12 @@ void ReadMHDPlane::Read64lseek(std::string fileNameIn, std::string plane)
 #if defined(_WIN32)
                        if (_lseeki64( fd, pos, SEEK_SET ) < 0)
 #else
-                       if (lseek64(fd, pos, SEEK_SET) < 0) 
+            //EED2021-09-03
+            #if defined(MACOSX)
+                if (lseek(fd, pos, SEEK_SET) < 0)
+            #else
+                if (lseek64(fd, pos, SEEK_SET) < 0)
+            #endif
 #endif // defined(_WIN32)
                        {
                                printf("EED ReadMHDPlane::Read64lseek \n");
@@ -374,7 +384,12 @@ void ReadMHDPlane::copy_YZ_plane(int fd,vtkImageData *newImage,int slice,int iWi
 #if defined(_WIN32)
                        if (_lseeki64( fd, pos , SEEK_SET ) < 0)
 #else
-                       if (lseek64(fd, pos , SEEK_SET) < 0) 
+            //EED2021-09-03
+            #if defined(MACOSX)
+                if (lseek(fd, pos , SEEK_SET) < 0)
+            #else
+                if (lseek64(fd, pos , SEEK_SET) < 0)
+            #endif
 #endif // defined(_WIN32)
                        {
                                printf("EED ReadMHDPlane::Read64lseek \n");
@@ -406,7 +421,12 @@ void ReadMHDPlane::copy_ZX_plane(int fd,vtkImageData *newImage,int slice,int iWi
 #if defined(_WIN32)
                if (_lseeki64( fd, pos + j*sizeBytesPlane , SEEK_SET ) < 0)
 #else
-               if (lseek64(fd, pos + j*sizeBytesPlane , SEEK_SET) < 0) 
+            //EED2021-09-03
+            #if defined(MACOSX)
+                if (lseek(fd, pos + j*sizeBytesPlane , SEEK_SET) < 0)
+            #else
+                if (lseek64(fd, pos + j*sizeBytesPlane , SEEK_SET) < 0)
+            #endif
 #endif // defined(_WIN32)
                {
                        printf("EED ReadMHDPlane::Read64lseek \n");
index 9a535195eb1666e548a0173ae90c2bf13490e4c3..f96e10429d4733c66a380ffa9c0ecc15efe78c8e 100644 (file)
@@ -201,7 +201,9 @@ void vtkTensorsVisu::Process()
        //_pdm->SetColorModeToDefault();
        // _pdm->SetColorModeToDirectScalars();  // NOT compile
        _pdm->SetScalarModeToUsePointFieldData();
-       _pdm->ImmediateModeRenderingOn();
+
+//EED2021-09-03 Deprecated. Removed in vtk 8.1
+//     _pdm->ImmediateModeRenderingOn();
 
        _LutEED->SetVectorModeToComponent();
        //_LutEED->SetVectorModeToRGBColors();
index 376d4036211699121b49e0d31a4b75de98b1f118..7fe98611e3342bc5c0bcdcc63c4142f17d0e77e0 100644 (file)
@@ -112,7 +112,9 @@ for (i=0;i<sizeDa;i++)
        //_pdm->SetColorModeToDefault();
        // _pdm->SetColorModeToDirectScalars();  // NOT compile
        _pdm->SetScalarModeToUsePointFieldData();
-       _pdm->ImmediateModeRenderingOn();
+
+//EED2021-09-03 Deprecated. Removed in vtk 8.1
+//     _pdm->ImmediateModeRenderingOn();
 
        _LutEED->SetVectorModeToComponent();
        //_LutEED->SetVectorModeToRGBColors();