From: regrain Date: Wed, 7 Jan 2004 10:07:27 +0000 (+0000) Subject: * Modification to compile with the distutils. X-Git-Tag: Version0.3.1~18 X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;ds=inline;h=659604feaaaf9519d03d59d66711f6b4b8290804;p=gdcm.git * Modification to compile with the distutils. * Bug fix in code -- BeNours --- diff --git a/ChangeLog b/ChangeLog index 1b32de0b..8c0b3acd 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,9 @@ +2004-01-07 Benoit Regrain + * Modification to compile with the distutils. + * Bug fix in code + 2003-12-10 Benoit Regrain - * gdcmHeader is now aggregating gdcmFile, and not derived into. Thus, we + * gdcmHeader is now aggregating gdcmFile, and not derived into. Thus, we can use a gdcmHeaderHelper to load datas * gdcmPython/testSuite.py : make the testSuite compliant with modifications made in the source code diff --git a/setup.py b/setup.py index df658a28..66759c4e 100644 --- a/setup.py +++ b/setup.py @@ -86,6 +86,7 @@ vtkSources.extend(glob.glob(os.path.join(gdcmSrcDir,"*.cxx"))) vtkSources.extend(Jpeg8Sources) vtkSources.extend(Jpeg12Sources) vtkSources.extend(JpgSources) +vtkSources.remove(os.path.join(gdcmvtkSrcDir,"vtkgdcmViewer.cxx")) vtkLibraries=["vtkCommon","vtkCommonPython", "vtkIO","vtkIOPython", diff --git a/src/jpeg/ljpg/huffd.c b/src/jpeg/ljpg/huffd.c index e23fffb5..6b4bc0b0 100644 --- a/src/jpeg/ljpg/huffd.c +++ b/src/jpeg/ljpg/huffd.c @@ -5,7 +5,7 @@ * software */ /* - * $Id: huffd.c,v 1.1 2003/10/21 12:08:53 jpr Exp $ + * $Id: huffd.c,v 1.2 2004/01/07 10:07:28 regrain Exp $ */ #include #include @@ -533,7 +533,7 @@ void DecodeImage (DecompressInfo *dcPtr, unsigned short **image, int depth) else if (depth == 24) PmPutRow24 (curRowBuf, numCOL, &image24tmp); - swap(MCU *, prevRowBuf, curRowBuf); + gdcmSWAP(MCU *, prevRowBuf, curRowBuf); /* optimal case : 8 bit image, one color component, no restartInRows */ if ((depth == 8) && (compsInScan == 1) && (dcPtr->restartInRows == 0)) @@ -631,7 +631,7 @@ void DecodeImage (DecompressInfo *dcPtr, unsigned short **image, int depth) else if (depth == 24) PmPutRow24 (curRowBuf, numCOL, &image24tmp); - swap(MCU *,prevRowBuf,curRowBuf); + gdcmSWAP(MCU *,prevRowBuf,curRowBuf); continue; } dcPtr->restartRowsToGo--; @@ -684,7 +684,7 @@ void DecodeImage (DecompressInfo *dcPtr, unsigned short **image, int depth) else if (depth == 24) PmPutRow24 (curRowBuf, numCOL, &image24tmp); - swap(MCU *, prevRowBuf, curRowBuf); + gdcmSWAP(MCU *, prevRowBuf, curRowBuf); }/*endfor row*/ }/*endelse*/ diff --git a/src/jpeg/ljpg/jpeg.h b/src/jpeg/ljpg/jpeg.h index fe80d5da..fa32bc1a 100644 --- a/src/jpeg/ljpg/jpeg.h +++ b/src/jpeg/ljpg/jpeg.h @@ -4,11 +4,13 @@ * Basic jpeg data structure definitions. */ /* - * $Id: jpeg.h,v 1.2 2003/10/29 18:24:40 malaterre Exp $ + * $Id: jpeg.h,v 1.3 2004/01/07 10:07:28 regrain Exp $ */ #ifndef _JPEG #define _JPEG +#include + /* a function referenced thru EXTERNs: */ #ifdef WIN32 #define GLOBAL(type) __declspec( dllexport ) type @@ -173,7 +175,7 @@ typedef struct DecompressInfo * *-------------------------------------------------------------- */ -#define swap(type,a,b) {type c; c=(a); (a)=(b); (b)=c;} +#define gdcmSWAP(type,a,b) {type c; c=(a); (a)=(b); (b)=c;} #define MEMSET(s,c,n) memset((void *)(s),(int)(c),(int)(n)) #define MEMCPY(s1,s2,n) memcpy((void *)(s1),(void *)(s2),(int)(n)) diff --git a/vtk/vtkgdcmViewer.cxx b/vtk/vtkgdcmViewer.cxx index ce5afd62..1ce2af88 100644 --- a/vtk/vtkgdcmViewer.cxx +++ b/vtk/vtkgdcmViewer.cxx @@ -1,3 +1,5 @@ +#include + #include #include #include