diff --git a/Modules/AlgorithmsExt/CMakeLists.txt b/Modules/AlgorithmsExt/CMakeLists.txt index 019fbbee2c..4e593dfe19 100644 --- a/Modules/AlgorithmsExt/CMakeLists.txt +++ b/Modules/AlgorithmsExt/CMakeLists.txt @@ -1,16 +1,16 @@ mitk_create_module( DEPENDS MitkDataTypesExt MitkLegacyGL PACKAGE_DEPENDS PUBLIC ITK|ITKThresholding - PRIVATE ANN ITK|ITKIOImageBase + PRIVATE ANN ITK|ITKIOImageBase VTK|ImagingGeneral ) if(TARGET ${MODULE_TARGET}) if(MITK_USE_OpenMP) target_link_libraries(${MODULE_TARGET} PUBLIC OpenMP::OpenMP_CXX) endif() if(BUILD_TESTING) add_subdirectory(test) endif() endif() diff --git a/Modules/Annotation/CMakeLists.txt b/Modules/Annotation/CMakeLists.txt index 2cf47f8160..fd9f2dee9a 100644 --- a/Modules/Annotation/CMakeLists.txt +++ b/Modules/Annotation/CMakeLists.txt @@ -1,5 +1,6 @@ MITK_CREATE_MODULE( DEPENDS MitkCore + PACKAGE_DEPENDS PUBLIC VTK|RenderingAnnotation PRIVATE VTK|IOImage ) add_subdirectory(test) diff --git a/Modules/AppUtil/CMakeLists.txt b/Modules/AppUtil/CMakeLists.txt index 579fad9f59..469ce3c6d7 100644 --- a/Modules/AppUtil/CMakeLists.txt +++ b/Modules/AppUtil/CMakeLists.txt @@ -1,14 +1,14 @@ set(qt5_depends Qt5|Widgets) if(UNIX AND NOT APPLE) set(qt5_depends "${qt5_depends}+X11Extras") endif() mitk_create_module( PACKAGE_DEPENDS PUBLIC CTK|CTKPluginFramework ${qt5_depends} Poco|Util - PRIVATE VTK + PRIVATE VTK|GUISupportQt DEPENDS PUBLIC qtsingleapplication PRIVATE MitkCore ) diff --git a/Modules/ContourModel/CMakeLists.txt b/Modules/ContourModel/CMakeLists.txt index b52388f2ec..98b2e63246 100644 --- a/Modules/ContourModel/CMakeLists.txt +++ b/Modules/ContourModel/CMakeLists.txt @@ -1,8 +1,8 @@ MITK_CREATE_MODULE( INCLUDE_DIRS Algorithms DataManagement IO Rendering DEPENDS MitkCore MitkSceneSerializationBase MitkLegacyGL MitkAnnotation MitkMultilabel - PACKAGE_DEPENDS ITK|ITKReview + PACKAGE_DEPENDS PRIVATE ITK|ITKReview VTK|RenderingContext2D+RenderingContextOpenGL2 # AUTOLOAD_WITH MitkCore TODO: Create IO Submodule and autoload that one instead. ) add_subdirectory(Testing) diff --git a/Modules/Core/CMakeLists.txt b/Modules/Core/CMakeLists.txt index bae8a92060..280a587669 100644 --- a/Modules/Core/CMakeLists.txt +++ b/Modules/Core/CMakeLists.txt @@ -1,66 +1,66 @@ set(TOOL_CPPS "") # temporary suppress warnings in the following files until image accessors are fully integrated. set_source_files_properties( src/DataManagement/mitkImage.cpp COMPILE_FLAGS -DMITK_NO_DEPRECATED_WARNINGS ) set_source_files_properties( src/Controllers/mitkSliceNavigationController.cpp COMPILE_FLAGS -DMITK_NO_DEPRECATED_WARNINGS ) MITK_CREATE_MODULE( INCLUDE_DIRS PUBLIC ${MITK_BINARY_DIR} PRIVATE src/Algorithms src/Controllers src/DataManagement src/Interactions src/IO src/Rendering ${OPENGL_INCLUDE_DIR} DEPENDS PUBLIC mbilog CppMicroServices PACKAGE_DEPENDS PRIVATE tinyxml OpenGL PUBLIC ITK|ITKTransform+ITKImageGrid+ITKImageFeature+ITKIOImageBase+ITKIOHDF5+ITKIOLSM+ITKIOMRC+ITKIOBioRad+ITKIOGE+ITKIOStimulate+ITKIOBruker+ITKIOMINC # We privately use/link all ITK modules in order to support all IO, Transform, etc. # factories from ITK which are registered "automatically" via a factory manager. PRIVATE ITK - PUBLIC VTK|vtkFiltersTexture+vtkFiltersParallel+vtkImagingStencil+vtkImagingMath+vtkInteractionStyle+vtkRenderingOpenGL2+vtkRenderingContextOpenGL2+vtkRenderingVolumeOpenGL2+vtkRenderingFreeType+vtkRenderingLabel+vtkInteractionWidgets+vtkIOGeometry+vtkIOXML + PUBLIC VTK|FiltersTexture+FiltersParallel+ImagingStencil+ImagingMath+InteractionStyle+RenderingOpenGL2+RenderingVolumeOpenGL2+RenderingFreeType+RenderingLabel+InteractionWidgets+IOGeometry+IOXML PUBLIC Boost|boost SUBPROJECTS MITK-Core # Do not automatically create CppMicroServices initialization code. # Because the VTK 6 "auto-init" functionality injects file-local static # initialization code in every cpp file which includes a VTK header, # static initialization order becomes an issue again. For the Mitk # core library, we need to ensure that the VTK static initialization stuff # happens before the CppMicroServices initialization, since the latter # might already use VTK code which needs to access VTK object factories. # Hence, CppMicroServices initialization code is placed manually within # the mitkCoreActivator.cpp file. NO_INIT ) if(NOT TARGET ${MODULE_TARGET}) message(SEND_ERROR "Core target ${MODULE_TARGET} does not exist") endif() function(_itk_create_factory_register_manager) # In MITK_ITK_Config.cmake, we do *not* include ITK_USE_FILE, which # prevents multiple registrations/unregistrations of ITK IO factories # during library loading/unloading (of MITK libraries). However, we need # "one" place where the IO factories are registered at # least once. This could be the application executable, but every executable would # need to take care of that itself. Instead, we allow the auto registration in the # Mitk Core library. set(NO_DIRECTORY_SCOPED_ITK_COMPILE_DEFINITION 1) find_package(ITK) include(${ITK_USE_FILE}) if(NOT ITK_NO_IO_FACTORY_REGISTER_MANAGER) # We manually add the define which will be of target scope. MITK # patches ITK_USE_FILE to remove the directory scoped compile # definition since it would be propagated to other targets in the # same directory scope but these targets might want to *not* # use the ITK factory manager stuff. target_compile_definitions(${MODULE_TARGET} PRIVATE ITK_IO_FACTORY_REGISTER_MANAGER) endif() endfunction() _itk_create_factory_register_manager() if(MSVC_IDE OR MSVC_VERSION) target_link_libraries(${MODULE_TARGET} PRIVATE psapi.lib) endif() if(BUILD_TESTING) add_subdirectory(TestingHelper) add_subdirectory(test) endif() diff --git a/Modules/Core/TestingHelper/CMakeLists.txt b/Modules/Core/TestingHelper/CMakeLists.txt index a94c4819e3..021d400931 100644 --- a/Modules/Core/TestingHelper/CMakeLists.txt +++ b/Modules/Core/TestingHelper/CMakeLists.txt @@ -1,7 +1,7 @@ mitk_create_module( DEPENDS PUBLIC MitkCore PACKAGE_DEPENDS PUBLIC CppUnit - PRIVATE VTK|vtkTestingRendering tinyxml OpenGL + PRIVATE VTK|TestingRendering tinyxml OpenGL ) diff --git a/Modules/Core/test/CMakeLists.txt b/Modules/Core/test/CMakeLists.txt index 7b3e5e46e9..e33bc212b2 100644 --- a/Modules/Core/test/CMakeLists.txt +++ b/Modules/Core/test/CMakeLists.txt @@ -1,192 +1,192 @@ # The core tests need relaxed compiler flags... # TODO fix core tests to compile without these additional no-error flags if(MSVC_VERSION) # disable deprecated warnings (they would lead to errors) mitkFunctionCheckCAndCXXCompilerFlags("/wd4996" CMAKE_C_FLAGS CMAKE_CXX_FLAGS) else() mitkFunctionCheckCAndCXXCompilerFlags("-Wno-error=deprecated" CMAKE_C_FLAGS CMAKE_CXX_FLAGS) mitkFunctionCheckCAndCXXCompilerFlags("-Wno-error=deprecated-declarations" CMAKE_C_FLAGS CMAKE_CXX_FLAGS) endif() MITK_CREATE_MODULE_TESTS() if(TARGET ${TESTDRIVER}) - mitk_use_modules(TARGET ${TESTDRIVER} PACKAGES ITK|ITKThresholding+ITKTestKernel VTK|vtkTestingRendering tinyxml) + mitk_use_modules(TARGET ${TESTDRIVER} PACKAGES ITK|ITKThresholding+ITKTestKernel VTK|TestingRendering tinyxml) mitkAddCustomModuleTest(mitkVolumeCalculatorTest_Png2D-bw mitkVolumeCalculatorTest ${MITK_DATA_DIR}/Png2D-bw.png ${MITK_DATA_DIR}/Pic2DplusT.nrrd ) mitkAddCustomModuleTest(mitkEventConfigTest_CreateObjectInDifferentWays mitkEventConfigTest ${MITK_SOURCE_DIR}/Modules/Core/test/resource/Interactions/StatemachineConfigTest.xml ) mitkAddCustomModuleTest(mitkDataStorageTest_US4DCyl mitkDataStorageTest ${MITK_DATA_DIR}/US4DCyl.nrrd ) mitkAddCustomModuleTest(mitkPointSetReaderTest mitkPointSetReaderTest ${MITK_DATA_DIR}/PointSetReaderTestData.mps ) mitkAddCustomModuleTest(mitkImageTest_4DImageData mitkImageTest ${MITK_DATA_DIR}/US4DCyl.nrrd ) mitkAddCustomModuleTest(mitkImageTest_2D+tImageData mitkImageTest ${MITK_DATA_DIR}/Pic2DplusT.nrrd ) mitkAddCustomModuleTest(mitkImageTest_3DImageData mitkImageTest ${MITK_DATA_DIR}/Pic3D.nrrd ) mitkAddCustomModuleTest(mitkImageEqualTest mitkImageEqualTest) mitkAddCustomModuleTest(mitkImageTest_brainImage mitkImageTest ${MITK_DATA_DIR}/brain.mhd ) mitkAddCustomModuleTest(mitkLevelWindowManagerTest mitkLevelWindowManagerTest ${MITK_DATA_DIR}/Pic3D.nrrd ) mitkAddCustomModuleTest(mitkMultiComponentImageDataComparisonFilterTest mitkMultiComponentImageDataComparisonFilterTest ${MITK_DATA_DIR}/NrrdWritingTestImage.jpg ) mitkAddCustomModuleTest(mitkImageToItkTest mitkImageToItkTest ${MITK_DATA_DIR}/Pic3D.nrrd ) mitkAddCustomModuleTest(mitkImageSliceSelectorTest mitkImageSliceSelectorTest ${MITK_DATA_DIR}/Pic2DplusT.nrrd ) mitkAddCustomModuleTest(mitkRotatedSlice4DTest mitkRotatedSlice4DTest ${MITK_DATA_DIR}/UltrasoundImages/4D_TEE_Data_MV.dcm ) mitkAddCustomModuleTest(mitkImageVtkMapper2D_rgbaImage640x480 mitkImageVtkMapper2DTest ${MITK_DATA_DIR}/RenderingTestData/rgbaImage.png #input image to load in data storage -V ${MITK_DATA_DIR}/RenderingTestData/ReferenceScreenshots/rgbaImage640x480REF.png #corresponding reference screenshot ) mitkAddCustomModuleTest(mitkImageVtkMapper2D_pic3d640x480 mitkImageVtkMapper2DTest #test for standard Pic3D axial slice ${MITK_DATA_DIR}/Pic3D.nrrd #input image to load in data storage -V ${MITK_DATA_DIR}/RenderingTestData/ReferenceScreenshots/pic3d640x480REF.png #corresponding reference screenshot ) mitkAddCustomModuleTest(mitkImageVtkMapper2D_pic3dColorBlue640x480 mitkImageVtkMapper2DColorTest #test for color property (=blue) Pic3D sagittal slice ${MITK_DATA_DIR}/Pic3D.nrrd #input image to load in data storage -V ${MITK_DATA_DIR}/RenderingTestData/ReferenceScreenshots/pic3dColorBlue640x480REF.png #corresponding reference screenshot ) mitkAddCustomModuleTest(mitkImageVtkMapper2D_pic3dLevelWindow640x480 mitkImageVtkMapper2DLevelWindowTest #test for levelwindow property (=blood) #Pic3D sagittal slice ${MITK_DATA_DIR}/Pic3D.nrrd #input image to load in data storage -V ${MITK_DATA_DIR}/RenderingTestData/ReferenceScreenshots/pic3dLevelWindowBlood640x480REF.png #corresponding reference #screenshot ) #mitkAddCustomModuleTest(mitkImageVtkMapper2D_pic3dOpacity640x480 mitkImageVtkMapper2DOpacityTest #test for opacity (=0.5) Pic3D coronal slice # ${MITK_DATA_DIR}/Pic3D.nrrd #input image to load in data storage # -V ${MITK_DATA_DIR}/RenderingTestData/ReferenceScreenshots/pic3dOpacity640x480REF.png corresponding reference screenshot #) mitkAddCustomModuleTest(mitkImageVtkMapper2D_pic3dSwivel640x480 mitkImageVtkMapper2DSwivelTest #test for a randomly chosen Pic3D swivelled slice ${MITK_DATA_DIR}/Pic3D.nrrd #input image to load in data storage -V ${MITK_DATA_DIR}/RenderingTestData/ReferenceScreenshots/pic3dSwivel640x480REF.png #corresponding reference screenshot ) mitkAddCustomModuleTest(mitkPointSetVtkMapper2D_openMeAlone640x480 mitkPointSetVtkMapper2DTest ${MITK_DATA_DIR}/RenderingTestData/openMeAlone.mps #input point set to load in data storage -V ${MITK_DATA_DIR}/RenderingTestData/ReferenceScreenshots/openMeAlone640x480REF.png #corresponding reference screenshot ) mitkAddCustomModuleTest(mitkPointSetVtkMapper2D_Pic3DPointSetForPic3D640x480 mitkPointSetVtkMapper2DImageTest ${MITK_DATA_DIR}/Pic3D.nrrd ${MITK_DATA_DIR}/RenderingTestData/PointSetForPic3D.mps #input point set and image to load in data storage -V ${MITK_DATA_DIR}/RenderingTestData/ReferenceScreenshots/Pic3DPointSetForPic3D640x480REF.png #corresponding reference screenshot ) mitkAddCustomModuleTest(mitkPointSetVtkMapper2D_openMeAloneGlyphType640x480 mitkPointSetVtkMapper2DGlyphTypeTest ${MITK_DATA_DIR}/RenderingTestData/openMeAlone.mps #input point set to load in data storage -V ${MITK_DATA_DIR}/RenderingTestData/ReferenceScreenshots/openMeAloneGlyphType640x480REF.png #corresponding reference screenshot ) mitkAddCustomModuleTest(mitkPointSetVtkMapper2D_openMeAloneTransformed640x480 mitkPointSetVtkMapper2DTransformedPointsTest ${MITK_DATA_DIR}/RenderingTestData/openMeAlone.mps #input point set to load in data storage -V ${MITK_DATA_DIR}/RenderingTestData/ReferenceScreenshots/openMeAloneTransformedPoints640x480REF.png #corresponding reference screenshot ) # Currently not working on windows because of a rendering timing issue # see bug 18083 for details if(NOT WIN32) mitkAddCustomModuleTest(mitkSurfaceDepthSortingTransparency_StanfordBunnySTL640x480 mitkSurfaceDepthSortingTest ${MITK_DATA_DIR}/RenderingTestData/Stanford_bunny.stl -V ${MITK_DATA_DIR}/RenderingTestData/ReferenceScreenshots/Stanford_bunnySTLDepthSorting640x480REF.png) endif() # BUG 18695 - tests deactivated, because win 32 bit continuous renders images slightly different. TODO! #Test reslice interpolation #note: nearest mode is already tested by swivel test #mitkAddCustomModuleTest(ResliceInterpolationIsLinear mitkImageVtkMapper2DResliceInterpolationPropertyTest # 1 #linear # ${MITK_DATA_DIR}/Pic3D.nrrd # -V # ${MITK_DATA_DIR}/RenderingTestData/ReferenceScreenshots/pic3dRefLinear.png #corresponding reference screenshot LINEAR #) #mitkAddCustomModuleTest(ResliceInterpolationIsCubic mitkImageVtkMapper2DResliceInterpolationPropertyTest # 3 #cubic # ${MITK_DATA_DIR}/Pic3D.nrrd # -V # ${MITK_DATA_DIR}/RenderingTestData/ReferenceScreenshots/pic3dRefCubic.png #corresponding reference screenshot CUBIC #) #End test reslice interpolation # Testing of the rendering of binary images #mitkAddCustomModuleTest(mitkImageVtkMapper2D_binaryTestImage640x480 mitkImageVtkMapper2DTest #test for standard Pic3D axial slice # ${MITK_DATA_DIR}/RenderingTestData/binaryImage.nrrd #input image to load in data storage # -V ${MITK_DATA_DIR}/RenderingTestData/ReferenceScreenshots/binaryImage640x480REF.png #corresponding reference screenshot #) #mitkAddCustomModuleTest(mitkImageVtkMapper2D_binaryTestImageWithRef640x480 mitkImageVtkMapper2DTest #test for standard Pic3D axial slice # ${MITK_DATA_DIR}/Pic3D.nrrd ${MITK_DATA_DIR}/RenderingTestData/binaryImage.nrrd #input image to load in data storage # -V ${MITK_DATA_DIR}/RenderingTestData/ReferenceScreenshots/binaryImageWithRef640x480REF.png #corresponding reference screenshot #) # End of binary image tests mitkAddCustomModuleTest(mitkSurfaceVtkMapper3DTest_TextureProperty mitkSurfaceVtkMapper3DTest ${MITK_DATA_DIR}/RenderingTestData/earth.jpg -V ${MITK_DATA_DIR}/RenderingTestData/ReferenceScreenshots/texturedSphere640x480REF.png #corresponding reference screenshot ) mitkAddCustomModuleTest(mitkImageVtkMapper2DTransferFunctionTest_Png2D-bw mitkImageVtkMapper2DTransferFunctionTest ${MITK_DATA_DIR}/Png2D-bw.png -V ${MITK_DATA_DIR}/RenderingTestData/ReferenceScreenshots/Png2D-bw-TransferFunctionRGBImage640x480REF.png #corresponding reference screenshot ) mitkAddCustomModuleTest(mitkImageVtkMapper2DOpacityTransferFunctionTest_Png2D-bw mitkImageVtkMapper2DOpacityTransferFunctionTest ${MITK_DATA_DIR}/Png2D-bw.png -V ${MITK_DATA_DIR}/RenderingTestData/ReferenceScreenshots/Png2D-bw-OpacityTransferFunctionRGBImage640x480REF.png #corresponding reference screenshot ) ############################## DISABLED TESTS mitkAddCustomModuleTest(mitkImageVtkMapper2DLookupTableTest_Png2D-bw mitkImageVtkMapper2DLookupTableTest ${MITK_DATA_DIR}/Png2D-bw.png -V ${MITK_DATA_DIR}/RenderingTestData/ReferenceScreenshots/Png2D-bw-LookupTableRGBImage640x480REF.png #corresponding reference screenshot ) #mitkAddCustomModuleTest(mitkImageTest_color2DImage mitkImageTest # ${MITK_DATA_DIR}/NrrdWritingTestImage.jpg #) #mitkAddCustomModuleTest(mitkNodeDependentPointSetInteractorTest mitkNodeDependentPointSetInteractorTest # ${MITK_DATA_DIR}/Pic3D.pic.gz ${MITK_DATA_DIR}/BallBinary30x30x30.pic.gz #) mitkAddCustomModuleTest(mitkPlaneGeometryDataMapper2DTest mitkPlaneGeometryDataMapper2DTest ${MITK_DATA_DIR}/Pic3D.nrrd #input image to load in data storage -V ${MITK_DATA_DIR}/RenderingTestData/ReferenceScreenshots/PlaneGeometryMapper640x480REF.png #corresponding reference screenshot ) SET_PROPERTY(TEST mitkRotatedSlice4DTest mitkImageVtkMapper2D_rgbaImage640x480 mitkImageVtkMapper2D_pic3d640x480 mitkImageVtkMapper2D_pic3dColorBlue640x480 mitkImageVtkMapper2D_pic3dLevelWindow640x480 mitkImageVtkMapper2D_pic3dSwivel640x480 mitkImageVtkMapper2DTransferFunctionTest_Png2D-bw # mitkImageVtkMapper2D_pic3dOpacity640x480 mitkSurfaceVtkMapper2DTest mitkSurfaceVtkMapper3DTest_TextureProperty mitkPointSetVtkMapper2D_Pic3DPointSetForPic3D640x480 mitkPointSetVtkMapper2D_openMeAlone640x480 mitkPointSetVtkMapper2D_openMeAloneGlyphType640x480 mitkPointSetVtkMapper2D_openMeAloneTransformed640x480 mitkPlaneGeometryDataMapper2DTest PROPERTY RUN_SERIAL TRUE) endif() # TARGET ${TESTDRIVER} diff --git a/Modules/IOExt/CMakeLists.txt b/Modules/IOExt/CMakeLists.txt index ccfb990d3c..61b51b291e 100644 --- a/Modules/IOExt/CMakeLists.txt +++ b/Modules/IOExt/CMakeLists.txt @@ -1,4 +1,4 @@ MITK_CREATE_MODULE(DEPENDS MitkDataTypesExt MitkMapperExt MitkSceneSerialization MitkLegacyIO - PACKAGE_DEPENDS PRIVATE ITK|ITKIOImageBase VTK|vtkIOPLY+vtkIOExport+vtkIOParallelXML + PACKAGE_DEPENDS PRIVATE ITK|ITKIOImageBase VTK|IOPLY+IOExport+IOParallelXML AUTOLOAD_WITH MitkCore ) diff --git a/Modules/ImageStatistics/CMakeLists.txt b/Modules/ImageStatistics/CMakeLists.txt index 73a49bc11d..532b38bdf4 100644 --- a/Modules/ImageStatistics/CMakeLists.txt +++ b/Modules/ImageStatistics/CMakeLists.txt @@ -1,10 +1,10 @@ MITK_CREATE_MODULE( DEPENDS MitkImageExtraction MitkPlanarFigure MitkMultilabel PACKAGE_DEPENDS PUBLIC ITK|ITKIOXML - PRIVATE ITK|ITKVTK+ITKConvolution + PRIVATE ITK|ITKVTK+ITKConvolution VTK|IOImage ) if(BUILD_TESTING) add_subdirectory(Testing) endif() diff --git a/Modules/MapperExt/CMakeLists.txt b/Modules/MapperExt/CMakeLists.txt index e3b7025b99..e118e06824 100644 --- a/Modules/MapperExt/CMakeLists.txt +++ b/Modules/MapperExt/CMakeLists.txt @@ -1,13 +1,14 @@ mitk_create_module( DEPENDS MitkDataTypesExt MitkLegacyGL + PACKAGE_DEPENDS PRIVATE VTK|CommonComputationalGeometry+CommonSystem ) if(TARGET ${MODULE_TARGET}) if(MITK_USE_OpenMP) target_link_libraries(${MODULE_TARGET} PUBLIC OpenMP::OpenMP_CXX) endif() if(BUILD_TESTING) add_subdirectory(test) endif() endif() diff --git a/Modules/MatchPointRegistration/CMakeLists.txt b/Modules/MatchPointRegistration/CMakeLists.txt index 97bb55792b..ca9798f6d0 100644 --- a/Modules/MatchPointRegistration/CMakeLists.txt +++ b/Modules/MatchPointRegistration/CMakeLists.txt @@ -1,25 +1,26 @@ MITK_CREATE_MODULE( INCLUDE_DIRS PUBLIC Rendering Helper algorithms DEPENDS MitkCore MitkSceneSerializationBase PACKAGE_DEPENDS PUBLIC MatchPoint + PRIVATE VTK|ImagingGeneral+ImagingHybrid ) if(TARGET ${MODULE_TARGET}) set(ALG_PROFILE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/algorithms) include(${MatchPoint_SOURCE_DIR}/CMake/mapFunctionCreateAlgorithmProfile.cmake) file(GLOB ALG_PROFILE_FILES LIST_DIRECTORIES false RELATIVE ${ALG_PROFILE_DIR} "${ALG_PROFILE_DIR}/*.profile") foreach(profile_file ${ALG_PROFILE_FILES}) get_filename_component(profile_name ${profile_file} NAME_WE) MESSAGE(STATUS "... generate MDRA profile ${profile_name} (from ${profile_file})...") CREATE_ALGORITHM_PROFILE(${profile_name} ${ALG_PROFILE_DIR}/${profile_file}) endforeach(profile_file) ADD_SUBDIRECTORY(autoload/IO) ADD_SUBDIRECTORY(deployment) if(BUILD_TESTING) ADD_SUBDIRECTORY(Testing) endif(BUILD_TESTING) endif() diff --git a/Modules/PlanarFigure/CMakeLists.txt b/Modules/PlanarFigure/CMakeLists.txt index af4c93bb9c..ca2b93bce7 100644 --- a/Modules/PlanarFigure/CMakeLists.txt +++ b/Modules/PlanarFigure/CMakeLists.txt @@ -1,10 +1,11 @@ MITK_CREATE_MODULE( INCLUDE_DIRS PRIVATE src/Algorithms src/DataManagement src/Interactions src/Rendering DEPENDS MitkLegacyGL MitkAnnotation + PACKAGE_DEPENDS PRIVATE VTK|RenderingContextOpenGL2 ) add_subdirectory(autoload/IO) if(BUILD_TESTING) add_subdirectory(test) endif() diff --git a/Modules/PlanarFigure/test/CMakeLists.txt b/Modules/PlanarFigure/test/CMakeLists.txt index d6f5cf2a16..c58498e56b 100644 --- a/Modules/PlanarFigure/test/CMakeLists.txt +++ b/Modules/PlanarFigure/test/CMakeLists.txt @@ -1,153 +1,153 @@ MITK_CREATE_MODULE_TESTS() if(TARGET ${TESTDRIVER}) - mitk_use_modules(TARGET ${TESTDRIVER} PACKAGES VTK|vtkTestingRendering) + mitk_use_modules(TARGET ${TESTDRIVER} PACKAGES VTK|TestingRendering) set(testcaseBasename mitkViewportRenderingTest) # set verbose to 1 to get a list of all defined test cases during CMake configuration set(verbose 0) # viewportTest(): # # 1. Sets up a scene with a DICOM image, several planar figures, an STL file # 2. Modifies the viewport of the VTK renderer to only a part of the render window # 3. Compares the rendering result against an expected version # # Parameters determine the size and position of the viewport and the render window # The expected result is mitkViewportRenderingTest_${testPostfix}.png # function(viewportTest testPostfix # postfix to uniquely identify the test case rwWidth rwHeight # "rw" = render window vpLeft vpBottom vpWidth vpHeight # "vp" = viewport # list of images/files for visualization ) set(data ${ARGN}) # use all ADDITIONAL parameters after vpHeight as filenames # transform the input parameters in required test parameters math(EXPR vpRight "${vpLeft} + ${vpWidth}") math(EXPR vpTop "${vpBottom} + ${vpHeight}") #message(STATUS "Testing viewport of ${vpWidth}x${vpHeight} at ${vpLeft},${vpBottom} in render window of size ${rwWidth}x${rwHeight} ('${testPostfix}')") # add the actual test mitkAddCustomModuleTest( mitkViewportRenderingTest_${testPostfix} mitkViewportRenderingTest ${rwWidth} ${rwHeight} ${vpLeft} ${vpBottom} ${vpRight} ${vpTop} ${data} -V ${MITK_DATA_DIR}/RenderingTestData/viewport/mitkViewportRenderingTest_${testPostfix}.png #corresponding reference screenshot ) set_property(TEST mitkViewportRenderingTest_${testPostfix} PROPERTY RUN_SERIAL TRUE) endfunction() function(getFirstCharacter string charVar) string(SUBSTRING ${string} 0 1 c) set(${charVar} ${c} PARENT_SCOPE) endfunction() # The following lines loop over several variations of aspect ratios for # - render window # - a viewport within this render window # - an input image (defines the input world geometry) # --------------------------------------------------------------------- # # Render window # - Square # - Landscape # - Portrait # # Viewport # - Square # - Landscape # - Portrait # # World / Image # - Square # - Landscape # - Portrait # foreach(renderWindowAspect Square Landscape Portrait) foreach(viewportAspect Square Landscape Portrait) foreach(worldAspect Square Landscape Portrait) getFirstCharacter(${renderWindowAspect} renderWindowAspectSymbol) getFirstCharacter(${viewportAspect} viewportAspectSymbol) getFirstCharacter(${worldAspect} worldAspectSymbol) # construct test case name from various aspect ratios set(testCaseShortname "r${renderWindowAspectSymbol}v${viewportAspectSymbol}w${worldAspectSymbol}") # construct test image name from aspect ratio set(testImage ${MITK_DATA_DIR}/RenderingTestData/viewport/input_${worldAspect}/SCSFREN.dcm) # nice DICOM name encoding and gray value test image set(testObjects ${MITK_DATA_DIR}/RenderingTestData/PlanarFigures/Line1.pf ${MITK_DATA_DIR}/RenderingTestData/PlanarFigures/Path1.pf ${MITK_DATA_DIR}/RenderingTestData/PlanarFigures/FourPointAngle1.pf ${MITK_DATA_DIR}/RenderingTestData/PlanarFigures/Rectangle1.pf ${MITK_DATA_DIR}/binary.stl ) # render window size if (renderWindowAspect STREQUAL Landscape) set(renderWindowWidth 600) else() set(renderWindowWidth 500) endif() if (renderWindowAspect STREQUAL Portrait) set(renderWindowHeight 600) else() set(renderWindowHeight 500) endif() # viewport size if (viewportAspect STREQUAL Landscape) set(viewportWidth 450) else() set(viewportWidth 300) endif() if (viewportAspect STREQUAL Portrait) set(viewportHeight 450) else() set(viewportHeight 300) endif() # world size if (worldAspect STREQUAL Portrait) set(worldWidth 300) set(worldHeight 420) elseif (worldAspect STREQUAL Landscape) set(worldWidth 420) set(worldHeight 300) else() set(worldWidth 512) set(worldHeight 512) endif() # Summary set(viewportX 30) set(viewportY 45) if (verbose) message(STATUS "(${testCaseShortname}) " "Render window ${renderWindowAspect} (${renderWindowWidth}x${renderWindowHeight}), " "Viewport ${viewportAspect} (${viewportWidth}x${viewportHeight}+${viewportX}+${viewportY}), " "World ${worldAspect} (${worldWidth}x${worldHeight})" ) endif() viewPortTest(${testCaseShortname} ${renderWindowWidth} ${renderWindowHeight} ${viewportX} ${viewportY} ${viewportWidth} ${viewportHeight} ${testImage} ${testObjects}) endforeach() endforeach() endforeach() endif() # endif TARGET ${TESTDRIVER} diff --git a/Modules/QtWidgets/CMakeLists.txt b/Modules/QtWidgets/CMakeLists.txt index 08c2333393..296a88008e 100644 --- a/Modules/QtWidgets/CMakeLists.txt +++ b/Modules/QtWidgets/CMakeLists.txt @@ -1,9 +1,9 @@ MITK_CREATE_MODULE( INCLUDE_DIRS PRIVATE resource # for xpm includes DEPENDS MitkPlanarFigure MitkAnnotation PACKAGE_DEPENDS - PUBLIC ITK|ITKIOImageBase VTK|vtkGUISupportQt+vtkRenderingQt Qt5|Widgets+OpenGL+Core + PUBLIC ITK|ITKIOImageBase VTK|GUISupportQt+RenderingQt Qt5|Widgets+OpenGL+Core SUBPROJECTS MITK-CoreUI ) add_subdirectory(test) diff --git a/Modules/QtWidgetsExt/CMakeLists.txt b/Modules/QtWidgetsExt/CMakeLists.txt index c2e295c41b..85fdc156a1 100644 --- a/Modules/QtWidgetsExt/CMakeLists.txt +++ b/Modules/QtWidgetsExt/CMakeLists.txt @@ -1,6 +1,6 @@ MITK_CREATE_MODULE( DEPENDS MitkAlgorithmsExt MitkQtWidgets PRIVATE MitkSceneSerializationBase PACKAGE_DEPENDS PUBLIC Qwt CTK|CTKWidgets - PRIVATE Qt5|Concurrent+Svg+Xml + PRIVATE Qt5|Concurrent+Svg+Xml VTK|IOImage ) diff --git a/Modules/Remeshing/CMakeLists.txt b/Modules/Remeshing/CMakeLists.txt index c3da914c8e..177531d9fe 100644 --- a/Modules/Remeshing/CMakeLists.txt +++ b/Modules/Remeshing/CMakeLists.txt @@ -1,7 +1,7 @@ mitk_create_module( DEPENDS MitkCore - PACKAGE_DEPENDS ACVD VTK|vtkIOPLY+vtkIOMINC + PACKAGE_DEPENDS ACVD VTK|IOPLY+IOMINC ) add_subdirectory(Testing) diff --git a/Modules/Segmentation/CMakeLists.txt b/Modules/Segmentation/CMakeLists.txt index 1ec269d597..1528dd107f 100644 --- a/Modules/Segmentation/CMakeLists.txt +++ b/Modules/Segmentation/CMakeLists.txt @@ -1,8 +1,9 @@ MITK_CREATE_MODULE( INCLUDE_DIRS Algorithms Controllers DataManagement Interactions Rendering SegmentationUtilities/BooleanOperations SegmentationUtilities/MorphologicalOperations DEPENDS MitkAlgorithmsExt MitkIpSegmentation MitkIpFunc MitkSurfaceInterpolation MitkGraphAlgorithms MitkContourModel MitkMultilabel PACKAGE_DEPENDS PUBLIC ITK|ITKBinaryMathematicalMorphology+ITKLabelVoting+ITKRegionGrowing+ITKFastMarching+ITKAnisotropicSmoothing+ITKWatersheds + PRIVATE VTK|ImagingGeneral ) add_subdirectory(Testing) diff --git a/Modules/ToFHardware/Testing/CMakeLists.txt b/Modules/ToFHardware/Testing/CMakeLists.txt index 99276c61d6..17c1070450 100644 --- a/Modules/ToFHardware/Testing/CMakeLists.txt +++ b/Modules/ToFHardware/Testing/CMakeLists.txt @@ -1,15 +1,15 @@ MITK_CREATE_MODULE_TESTS() if(TARGET ${TESTDRIVER}) - mitk_use_modules(TARGET ${TESTDRIVER} PACKAGES VTK|vtkTestingRendering) + mitk_use_modules(TARGET ${TESTDRIVER} PACKAGES VTK|TestingRendering) mitkAddCustomModuleTest(mitkPlayerLoadAndRenderDepthDataTest_KinectDepthImage #testname mitkPlayerLoadAndRenderDepthDataTest #testclassname Kinect_LiverPhantom_DistanceImage.nrrd #input image -V ${MITK_DATA_DIR}/ToF-Data/ReferenceScreenshots/Kinect_LiverPhantom_DistanceImage640x480REF.png #reference image ) mitkAddCustomModuleTest(mitkPlayerLoadAndRenderRGBDataTest_KinectRGBImage mitkPlayerLoadAndRenderRGBDataTest Kinect_LiverPhantom_RGBImage.nrrd -V ${MITK_DATA_DIR}/ToF-Data/ReferenceScreenshots/Kinect_LiverPhantom_RGBImage640x480REF.png) #rendering tests cannot run in parallel SET_PROPERTY(TEST mitkPlayerLoadAndRenderDepthDataTest_KinectDepthImage mitkPlayerLoadAndRenderRGBDataTest_KinectRGBImage PROPERTY RUN_SERIAL TRUE) endif() diff --git a/Plugins/org.mitk.gui.qt.moviemaker/CMakeLists.txt b/Plugins/org.mitk.gui.qt.moviemaker/CMakeLists.txt index d38a3d1797..041e907007 100644 --- a/Plugins/org.mitk.gui.qt.moviemaker/CMakeLists.txt +++ b/Plugins/org.mitk.gui.qt.moviemaker/CMakeLists.txt @@ -1,10 +1,10 @@ # The project name must correspond to the directory name of your plug-in # and must not contain periods. project(org_mitk_gui_qt_moviemaker) mitk_create_plugin( EXPORT_DIRECTIVE MOVIEMAKER_EXPORT EXPORTED_INCLUDE_SUFFIXES src MODULE_DEPENDS MitkQtWidgetsExt - PACKAGE_DEPENDS VTK|vtkTestingCore + PACKAGE_DEPENDS VTK|TestingCore+IOImage )