X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=Testing%2FCMakeLists.txt;h=43b987ad651a0d26366cad8b0d39843fffd662ab;hb=64429225702c1ca65ea3b6882be0e19c94509843;hp=0540b7ee859569c049abfc88f1e7c5f2e632f1db;hpb=8e1fe98f7659cec85bcbce8551e28f8e45971370;p=gdcm.git diff --git a/Testing/CMakeLists.txt b/Testing/CMakeLists.txt index 0540b7ee..43b987ad 100644 --- a/Testing/CMakeLists.txt +++ b/Testing/CMakeLists.txt @@ -9,23 +9,19 @@ SET(GDCM_TESTS ${CXX_TEST_PATH}/gdcmTests) # They usally return if no argument is given SET(TEST_SOURCES TestBug.cxx - TestDcm2Acr.cxx TestHash.cxx - TestWrite.cxx - TestWriteSimple.cxx ) # add tests that require data IF (GDCM_DATA_ROOT) SET(TEST_SOURCES ${TEST_SOURCES} - #PrintHeader.cxx #require test.acr - PrintDocument.cxx #require test.acr + TestReadWriteReadCompare.cxx # includes generated gdcmDataImages.h + PrintAllDocument.cxx # includes generated gdcmDataImages.h + TestAllReadCompareDicom.cxx # includes generated gdcmDataImages.h PrintDicomDir.cxx - TestFindTags.cxx TestChangeHeader.cxx TestDicomDir.cxx #require DICOMDIR BuildUpDicomDir.cxx - TestReadWrite.cxx makeDicomDir.cxx ) # add test that require VTK: @@ -80,6 +76,8 @@ IF(${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION} GREATER 1.9) FILE(GLOB GDCM_DATA_IMAGES_GLOB "${GDCM_DATA_ROOT}/*.acr" "${GDCM_DATA_ROOT}/*.dcm" +# "${GDCM_DATA_ROOT}/*.nema" + "${GDCM_DATA_ROOT}/*.ima" ) ELSE(${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION} GREATER 1.9) # Since there is a bug in cmake 1.8.3, I'll have to do two separate globs @@ -89,20 +87,41 @@ ELSE(${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION} GREATER 1.9) FILE(GLOB GDCM_DATA_IMAGES_GLOB_DCM "${GDCM_DATA_ROOT}/*.dcm" ) - SET(GDCM_DATA_IMAGES_GLOB ${GDCM_DATA_IMAGES_GLOB_DCM} ${GDCM_DATA_IMAGES_GLOB_ACR}) + FILE(GLOB GDCM_DATA_IMAGES_GLOB_NEMA +# "${GDCM_DATA_ROOT}/*.nema" + ) + FILE(GLOB GDCM_DATA_IMAGES_GLOB_IMA + "${GDCM_DATA_ROOT}/*.ima" + ) + SET(GDCM_DATA_IMAGES_GLOB + ${GDCM_DATA_IMAGES_GLOB_DCM} ${GDCM_DATA_IMAGES_GLOB_ACR} + ${GDCM_DATA_IMAGES_GLOB_NEMA} ${GDCM_DATA_IMAGES_GLOB_IMA}) #SET(GDCM_DATA_IMAGES_GLOB ${GDCM_DATA_IMAGES_GLOB_ACR}) ENDIF(${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION} GREATER 1.9) # Black list of images known to break lots of readers (efilm, xmedcon ...): SET(BLACK_LIST - "gdcm-JPEG-LossLessThoravision.dcm" - "cr172241.dcm" #temporarily remove as it kills my gnome session (but not kde) - "emptyImage.dcm" #the png looks ugly... - "gdcm-MR-PHILIPS-16-Multi-Seq.fixed.dcm" weird looks exactly the same as gdcm-MR-PHILIPS-16-Multi-Seq.dcm - "gdcm-MR-PHILIPS-16.dcm" png looks ugly - "irmPhlipsNew1.dcm" png looks ugly - "mriThruVPRO.dcm" png looks ugly - "US.3405.1.dcm" looks exactly the same as US.1.2.dcm + "gdcm-JPEG-LossLessThoravision.dcm" # serial killer + "cr172241.dcm" #temporarily remove as it kills my gnome session + # (but not kde) + "emptyImage.dcm" #the png looks ugly... + "irmPhlipsNew1.dcm" #png looks ugly + "mriThruVPRO.dcm" #png looks ugly + "gdcm-MR-SIEMENS-16-1.acr" #segfaults TestReadWriteReadCompare + #segfaults TestReadWriteReadCompare: this image looks corrupted: + # - it's pixel data is 132096 bytes long + # - it has a size of 256x256 with 16 bytes per pixel, i.e. a size + # of 256*256*2 = 131072 bytes. + # Since there is a missmatch, when we have the following call stack: + # gdcmFile::GetImageData() + # PixelData = new uint8_t[ImageDataSize]; + # \--->::GetImageDataIntoVector(destination, ImageDataSize) + # \---> ::ReadPixelData(destination) + # \---> fread(destination, Header->GetPixelAreaLength(), 1, fp); + # we get a segfault because : + # - destination is ImageDataSize i.e. 131072 bytes long + # - Header->GetPixelAreaLength() = 132096 bytes long + "oldACR00001.ima" ) # gdcm-ACR-LibIDO seems to be cut