# ---------------------------------------------------------------------
#
# Copyright (c) CREATIS (Centre de Recherche en Acquisition et Traitement de l'Image 
#                        pour la Sant�)
# Authors : Eduardo Davila, Frederic Cervenansky, Claire Mouton
# Previous Authors : Laurent Guigues, Jean-Pierre Roux
# CreaTools website : www.creatis.insa-lyon.fr/site/fr/creatools_accueil
#
#  This software is governed by the CeCILL-B license under French law and 
#  abiding by the rules of distribution of free software. You can  use, 
#  modify and/ or redistribute the software under the terms of the CeCILL-B 
#  license as circulated by CEA, CNRS and INRIA at the following URL 
#  http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html 
#  or in the file LICENSE.txt.
#
#  As a counterpart to the access to the source code and  rights to copy,
#  modify and redistribute granted by the license, users are provided only
#  with a limited warranty  and the software's author,  the holder of the
#  economic rights,  and the successive licensors  have only  limited
#  liability. 
#
#  The fact that you are presently reading this means that you have had
#  knowledge of the CeCILL-B license and that you accept its terms.
# ------------------------------------------------------------------------ */ 


INCLUDE_REGULAR_EXPRESSION("^.*$")
set(CMAKE_MFC_FLAG 2)

#===========================================================================
# CMAKE SETTINGS FOR BUILDING A BBTK PACKAGE
#===========================================================================

#===========================================================================
# THE NAME OF THE BBTK PACKAGE
SET(BBTK_PACKAGE_NAME creaMaracasVisu)
#===========================================================================



#===========================================================================
# IF IT IS A STANDALONE PROJECT UNCOMMENT NEXT LINE TO DECLARE YOUR PROJECT
# PROJECT(bb${BBTK_PACKAGE_NAME})
#===========================================================================

#===========================================================================
# PACKAGE AUTHOR
# !!! NO COMMA ALLOWED !!!
SET(${BBTK_PACKAGE_NAME}_AUTHOR "eduardo.davila [at] creatis.insa-lyon.fr")
#===========================================================================

#===========================================================================
# PACKAGE DESCRIPTION
SET(${BBTK_PACKAGE_NAME}_DESCRIPTION "Maracas library. LG : what does it provide ?")
#===========================================================================

#===========================================================================
# PACKAGE VERSION NUMBER 
SET(${BBTK_PACKAGE_NAME}_MAJOR_VERSION 1)
SET(${BBTK_PACKAGE_NAME}_MINOR_VERSION 0)
SET(${BBTK_PACKAGE_NAME}_BUILD_VERSION 0)
#===========================================================================


#===========================================================================
# UNCOMMENT EACH LIBRARY NEEDED (WILL BE FOUND AND USED AUTOMATICALLY)
 SET(${BBTK_PACKAGE_NAME}_USE_VTK  ON)
 SET(${BBTK_PACKAGE_NAME}_USE_ITK  ON)
# SET(${BBTK_PACKAGE_NAME}_USE_GDCM ON)
# SET(${BBTK_PACKAGE_NAME}_USE_GSMIS ON)
 SET(${BBTK_PACKAGE_NAME}_USE_WXWIDGETS ON)
#===========================================================================

#===========================================================================
# LIST HERE THE OTHER bbtk PACKAGES NEEDED
# (WILL BE FOUND AND USED AUTOMATICALLY)
SET(${BBTK_PACKAGE_NAME}_USE_PACKAGES 
  # std
  # wx
  # itk
  # vtk
  # ...
  )
#===========================================================================

#===========================================================================
# THE SOURCES OF THE PACKAGE
# EITHER UNCOMMENT NEXT LINE TO COMPILE ALL .cxx OF THE src DIRECTORY :
SET(${BBTK_PACKAGE_NAME}_COMPILE_ALL_CXX ON)
# ... OR LIST THE FILES TO COMPILE MANUALLY :
#SET(${BBTK_PACKAGE_NAME}_SOURCES
# LIST HERE THE FILES TO COMPILE TO BUILD THE LIB
# E.G. TO COMPILE "toto.cxx" ADD "toto" (NO EXTENSION)
# THE PATH MUST BE RELATIVE TO THE src FOLDER
#    )
#===========================================================================

#===========================================================================
# THE xml SOURCES OF THE PACKAGE
# EITHER UNCOMMENT NEXT LINE TO bbfy ALL .xml OF THE src DIRECTORY :
SET(${BBTK_PACKAGE_NAME}_COMPILE_ALL_XML ON)
# ... OR LIST THE FILES TO COMPILE MANUALLY :
#SET(${BBTK_PACKAGE_NAME}_XML_SOURCES
# LIST HERE THE FILES TO bbfy TO BUILD THE LIB
# E.G. TO bbfy "toto.xml" ADD "toto" (NO EXTENSION)
# THE PATH MUST BE RELATIVE TO THE src FOLDER
#    )
#===========================================================================

#===========================================================================
# THE SCRIPT-DEFINED BOXES OF THE PACKAGE (bbs)
# EITHER UNCOMMENT NEXT LINE TO INCLUDE ALL .bbs OF THE bbs/boxes DIRECTORY :
SET(${BBTK_PACKAGE_NAME}_INCLUDE_ALL_BBS_BOXES ON)
# ... OR LIST THE FILES TO INCLUDE MANUALLY :
# SET(${BBTK_PACKAGE_NAME}_BBS_BOXES
# LIST HERE THE bbs FILES TO INCLUDE 
# E.G. TO INCLUDE "boxes/bbtoto.bbs" ADD "boxes/bbtoto" (NO EXTENSION)
# !! THE PATH MUST BE RELATIVE TO THE bbs FOLDER !!
#)
#===========================================================================

#===========================================================================
# THE SCRIPT-DEFINED APPLICATIONS OF THE PACKAGE (bbs)
# EITHER UNCOMMENT NEXT LINE TO INCLUDE ALL .bbs OF THE bbs/appli DIRECTORY :
SET(${BBTK_PACKAGE_NAME}_INCLUDE_ALL_BBS_APPLI ON)
# ... OR LIST THE FILES TO INCLUDE MANUALLY :
# SET(${BBTK_PACKAGE_NAME}_BBS_APPLI
# LIST HERE THE bbs FILES TO INCLUDE 
# E.G. TO INCLUDE "appli/testToto.bbs" ADD "appli/testToto" (NO EXTENSION)
# !! THE PATH MUST BE RELATIVE TO THE bbs FOLDER !!
#)
#===========================================================================

#===========================================================================
SET(${BBTK_PACKAGE_NAME}_INCLUDE_DIRS
  # LIST HERE YOUR ADDITIONAL INCLUDE DIRECTORIES 
  # EXCEPT :
  #  - src
  #  - bbtk dirs
  #  - automatically handled libraries or packages : wx, vtk... (see above)
  #  - the dirs automatically set by other libraries found by FIND_PACKAGE
  )
#===========================================================================

#FIND_PATH( libIdo_DIR libidobin $ENV{LIBIDO_PATH} )
#FIND_PACKAGE(libIdo)
#INCLUDE_DIRECTORIES(${LIBIDO_INCLUDE_PATH})

  #===========================================================================
#  INCLUDE_DIRECTORIES(
#    # LIST HERE YOUR ADDITIONAL INCLUDE DIRECTORIES (EXCEPT BBTK'S)
#	../lib/maracasVisuLib/src/kernel
#	../lib/maracasVisuLib/include
#        ../lib/maracasVisuLib/src/kernel
#	../lib/maracasVisuLib/src/interface/wxWindows
#	../lib/maracasVisuLib/src/interface/wxWindows/Contour
#	../lib/maracasVisuLib/src/interface/wxWindows/widgets
#	../lib/maracasVisuLib/src/interface/wxWindows/widgets/pPlotter
#	../lib/maracasVisuLib/src/interface/wxWindows/widgets/manualContour
#	../lib/maracasVisuLib/src/interface/wxWindows/widgets/manualPaint
#	../lib/maracasVisuLib/src/interface/wxWindows/widgets/ThresholdImageView
#	../lib/maracasVisuLib/src/CutModule/interface
#	../lib/maracasVisuLib/src/CutModule/kernel
	
###    ${MaracasSrcDir}/ILPD/src/wxInterface
#    )
  #===========================================================================
 
#TODO for a nice VC++ we need to add header file...
#1SET(MARACASVISU_LIB_SRCS
#1  ${MaracasSrcDir}/manualContour.cpp
#1  ${MaracasSrcDir}/manualContour.h
#1  ${MaracasSrcDir}/Contour/ContourCrownWidget.cxx
#1  ${MaracasSrcDir}/Contour/ContourCrownWidget.h
#1  ${MaracasSrcDir}/Contour/ContourVOIWidget.cxx
#1  ${MaracasSrcDir}/Contour/ContourVOIWidget.h  
#1  ${MaracasSrcDir}/Contour/Propagation.cxx
#1  ${MaracasSrcDir}/Contour/Propagation.h
#1  ${MaracasSrcDir}/Contour/ExtractControlPoints2D.cxx
#1  ${MaracasSrcDir}/Contour/ExtractControlPoints2D.h
#1  ${MaracasSrcDir}/Contour/AutoControlPoints.cxx
#1  ${MaracasSrcDir}/Contour/AutoControlPoints.h
#1  ${MaracasSrcDir}/Contour/ContourPropagation.cxx
#1  ${MaracasSrcDir}/Contour/ContourPropagation.h
#1  ${MaracasSrcDir}/Contour/contoursIntersection.cxx
#1  ${MaracasSrcDir}/Contour/contoursIntersection.h
#1  ${MaracasSrcDir}/Contour/vectorFunctions.cxx
#1  ${MaracasSrcDir}/Contour/vectorFunctions.h
#  marDictionary.cxx
#  marDictionary.h
#  wxMaracas3DBrowser.cxx
#  wxMaracas3DBrowser.h
#  wxMaracasDataBrowser.cxx
#  wxMaracasDataBrowser.h
#  wxMaracasImageBrowser.cxx
#  wxMaracasImageBrowser.h
#1  ${MaracasSrcDir}/wxMaracasImageBrowser02.cxx
#1  ${MaracasSrcDir}/wxMaracasImageBrowser02.h
#1  ${MaracasSrcDir}/widgets/wxReadingPriorityPanel.cpp
#1  ${MaracasSrcDir}/widgets/wxReadingPriorityPanel.h
#  wxMaracasFrame02.cxx
#  wxMaracasFrame02.h

###  ${MaracasSrcDir}/wxILPDwithImage.cxx
###  ${MaracasSrcDir}/wxILPDwithImage.h

#  wxMaracasParametersDialog.cxx
#  wxMaracasParametersDialog.h
#  widgets/wxParametersDialog.cpp
#  widgets/wxParametersDialog.h
#  wxMaracasHelpDialog.cxx
#  wxMaracasHelpDialog.h
#  wxMaracasQuantification.cxx
#  wxMaracasQuantification.h
#1  ${MaracasSrcDir}/widgets/wxVTKRenderWindowInteractor.cxx
#1  ${MaracasSrcDir}/widgets/wxVTKRenderWindowInteractor.h
#  widgets/wxVTKRenderWindowInteractorEditContour.cxx
#  widgets/wxVTKRenderWindowInteractorEditContour.h
#  widgets/vtk3DSurfaceWidget.cxx
#  widgets/vtk3DSurfaceWidget.h
#  widgets/vtk3DQuantSurfaceWidget.cxx
#  widgets/vtk3DQuantSurfaceWidget.h
#  widgets/vtk2DQuantSliceWidget.cxx
#  widgets/vtk2DQuantSliceWidget.h
#  widgets/vtk3DSurfaceSTLWidget.cxx
#  widgets/vtk3DSurfaceSTLWidget.h
#  widgets/wxSurfaceSTLWidget.cxx
#  widgets/wxSurfaceSTLWidget.h
#  widgets/wxSurfaceWidget.cxx
#  widgets/wxSurfaceWidget.h
#1  ${MaracasSrcDir}/widgets/InterfaceVtkPanelWidgets.cxx
#1  ${MaracasSrcDir}/widgets/InterfaceVtkPanelWidgets.h
#  widgets/wxImageBrowserWdg.cxx
#  widgets/wxImageBrowserWdg.h
#  widgets/wxImageViewerWidget.cxx
#  widgets/wxImageViewerWidget.h
#1  ${MaracasSrcDir}/widgets/vtkClosePolyData.cxx
#1  ${MaracasSrcDir}/widgets/vtkClosePolyData.h
#  widgets/vtkImagePolyDataSeedConnectivity.cxx
#  widgets/vtkImagePolyDataSeedConnectivity.h
#  widgets/vtkInteractorStyleCutter.cxx
#  widgets/vtkInteractorStyleCutter.h
#  widgets/wxQuantificationWidget.cxx
#  widgets/wxQuantificationWidget.h
#1  ${MaracasSrcDir}/wxMaracasMPR.cxx
#1  ${MaracasSrcDir}/wxMaracasMPR.h
#  ${MaracasSrcDir}/wxMaracasEmptyPanel.cxx
#  ${MaracasSrcDir}/wxMaracasEmptyPanel.h
#  ${MaracasSrcDir}/widgets/wxEmptyPanelWidget.cxx
#  ${MaracasSrcDir}/widgets/wxEmptyPanelWidget.h
#  ${MaracasSrcDir}/wxMaracasEmptyPanel_2.cxx
#  ${MaracasSrcDir}/wxMaracasEmptyPanel_2.h
#  ${MaracasSrcDir}/widgets/wxEmptyPanelWidget_2.cxx
#  ${MaracasSrcDir}/widgets/wxEmptyPanelWidget_2.h
#1  ${MaracasSrcDir}/widgets/wxMPRWidget.cxx
#1  ${MaracasSrcDir}/widgets/wxMPRWidget.h
#1  ${MaracasSrcDir}/widgets/wxMPRBaseData.cxx
#1  ${MaracasSrcDir}/widgets/wxMPRBaseData.h
#1  ${MaracasSrcDir}/widgets/wxVtkBaseView.cxx
#1  ${MaracasSrcDir}/widgets/wxVtkBaseView.h
#1  ${MaracasSrcDir}/widgets/wxMaracas_ViewerWidget.h 
#1  ${MaracasSrcDir}/widgets/wxMaracas_ViewerWidget.cxx
#1  ${MaracasSrcDir}/widgets/wxMaracas_N_ViewersWidget.h
#1  ${MaracasSrcDir}/widgets/wxMaracas_N_ViewersWidget.cxx
#  wxMaracasProcessingCT.cxx
#  wxMaracasProcessingCT.h
#  widgets/wxProcessingCTWidget.cxx
#  widgets/wxProcessingCTWidget.h
#  wxMaracasQuantificationCT.cxx
#  wxMaracasQuantificationCT.h
#  widgets/wxQuantificationWidgetCT.cxx
#  widgets/wxQuantificationWidgetCT.h
#  widgets/wxQuantificationWidget_base.cxx
#  widgets/wxQuantificationWidget_base.h
#  wxMaracasEmptyPanel_3.cxx
#  wxMaracasEmptyPanel_3.h
#  widgets/wxEmptyPanel_3_Widget.cxx
#  widgets/wxEmptyPanel_3_Widget.h
#1  ${MaracasSrcDir}/wxMaracas_ManualTree_MPR.cxx
#1  ${MaracasSrcDir}/wxMaracas_ManualTree_MPR.h
#1  ${MaracasSrcDir}/widgets/wxManualTree_MPRWidget.cxx
#1  ${MaracasSrcDir}/widgets/wxManualTree_MPRWidget.h
#  widgets/wxManualRegistration3D.cxx
#  widgets/wxManualRegistration3D.h
#1  ${MaracasSrcDir}/res/wxInterface.rc
#1  ${MaracasSrcDir}/widgets/ContourView.h
#1  ${MaracasSrcDir}/widgets/ContourView.cxx
#1  ${MaracasSrcDir}/widgets/PointView.h
#1  ${MaracasSrcDir}/widgets/PointView.cxx
#1  ${MaracasSrcDir}/widgets/LineView.h
#1  ${MaracasSrcDir}/widgets/LineView.cxx
#  wxMaracasPathology_01.cxx
#  wxMaracasPathology_01.h
#  widgets/wxPathologyWidget_01.cxx
#  widgets/wxPathologyWidget_01.h
#  widgets/wxSTLWidget_02.cxx
#  widgets/wxSTLWidget_02.h
#  widgets/wxSTLWidget_03.cxx
#  widgets/wxSTLWidget_03.h
#1  ${MaracasSrcDir}/widgets/UtilVtk3DGeometriSelection.cxx
#1  ${MaracasSrcDir}/widgets/UtilVtk3DGeometriSelection.h
#  manualContourContainer.cxx
#  manualContourContainer.h
# wxMaracas_ManualSegmentation_MPR.cxx
#  wxMaracas_ManualSegmentation_MPR.h
#  widgets/wxManualSegmentation_MPRWidget.cxx
#  widgets/wxManualSegmentation_MPRWidget.h
#  wxMaracas_SegmentationFM3D.cxx
#  wxMaracas_SegmentationFM3D.h
#  widgets/wxSegmentationFM3DWidget.cxx
#  widgets/wxSegmentationFM3DWidget.h
#  wxMaracas_ManualContour_Panel.cxx
#  wxMaracas_ManualContour_Panel.h

  
#####pPlotter classes
#1  ${MaracasSrcDir}/widgets/pPlotter/HistogramDialog.cxx
#1  ${MaracasSrcDir}/widgets/pPlotter/HistogramDialog.h
#1  ${MaracasSrcDir}/widgets/pPlotter/HistogramWidget.cxx
#1  ${MaracasSrcDir}/widgets/pPlotter/HistogramWidget.h
#1  ${MaracasSrcDir}/widgets/pPlotter/pHistogram.cxx
#1  ${MaracasSrcDir}/widgets/pPlotter/pHistogram.h
#1  ${MaracasSrcDir}/widgets/pPlotter/mBarRange.cxx
#1  ${MaracasSrcDir}/widgets/pPlotter/mBarRange.h
#1  ${MaracasSrcDir}/widgets/pPlotter/pLogicalFunction.cxx
#1  ${MaracasSrcDir}/widgets/pPlotter/pLogicalFunction.h
#1  ${MaracasSrcDir}/widgets/pPlotter/LogicalColorBar.cxx
#1  ${MaracasSrcDir}/widgets/pPlotter/LogicalColorBar.h
#1  ${MaracasSrcDir}/widgets/pPlotter/pGraphicalFunction.h
#1  ${MaracasSrcDir}/widgets/pPlotter/pGraphicalFunction.cxx
#1  ${MaracasSrcDir}/widgets/pPlotter/pFunctionPoint.cxx
#1  ${MaracasSrcDir}/widgets/pPlotter/pFunctionPoint.h
#1  ${MaracasSrcDir}/widgets/pPlotter/pPlotterWindow.cxx
#1  ${MaracasSrcDir}/widgets/pPlotter/pPlotterWindow.h
#1  ${MaracasSrcDir}/widgets/pPlotter/pPlotterLayer.cxx
#1  ${MaracasSrcDir}/widgets/pPlotter/pPlotterLayer.h
#1  ${MaracasSrcDir}/widgets/pPlotter/pPlotterScaleX.h
#1  ${MaracasSrcDir}/widgets/pPlotter/pPlotterScaleX.cxx
#1 ${MaracasSrcDir}/widgets/pPlotter/pPlotterScaleY.h
#1  ${MaracasSrcDir}/widgets/pPlotter/pPlotterScaleY.cxx
#1  ${MaracasSrcDir}/widgets/pPlotter/pColorBar.h
#1  ${MaracasSrcDir}/widgets/pPlotter/pColorBar.cxx
#1  ${MaracasSrcDir}/widgets/pPlotter/pFigure.h
#1  ${MaracasSrcDir}/widgets/pPlotter/pFigure.cxx
#1  ${MaracasSrcDir}/widgets/pPlotter/pColorPoint.h
#1  ${MaracasSrcDir}/widgets/pPlotter/pColorPoint.cxx
#1  ${MaracasSrcDir}/widgets/pPlotter/pPlotter.h
#1  ${MaracasSrcDir}/widgets/pPlotter/pPlotter.cxx
#1  ${MaracasSrcDir}/widgets/pPlotter/mathplot.cxx
#1  ${MaracasSrcDir}/widgets/pPlotter/mathplot.h
#1  ${MaracasSrcDir}/widgets/pPlotter/MaximumsDialog.cxx
#1 ${MaracasSrcDir}/widgets/pPlotter/MaximumsDialog.h
#1  ${MaracasSrcDir}/widgets/pPlotter/Histogram.cxx
#1  ${MaracasSrcDir}/widgets/pPlotter/Histogram.h

###
#1  ${MaracasSrcDir}/../../../include/matrix.h
#1  ${MaracasSrcDir}/../../kernel/marImageData.cpp
#1  ${MaracasSrcDir}/../../kernel/marImageData.h
#1  ${MaracasSrcDir}/../../kernel/marDicomBase.cpp
#1  ${MaracasSrcDir}/../../kernel/marDicomBase.h
#1  ${MaracasSrcDir}/../../kernel/marGdcmDicom.cpp
#1  ${MaracasSrcDir}/../../kernel/marGdcmDicom.h
#1  ${MaracasSrcDir}/../../kernel/marObject.cpp
#1  ${MaracasSrcDir}/../../kernel/marObject.h
#1  ${MaracasSrcDir}/../../kernel/volume.cxx
#1  ${MaracasSrcDir}/../../kernel/volume.hxx
#1  ${MaracasSrcDir}/../../kernel/marParameters.cpp
#1  ${MaracasSrcDir}/../../kernel/marParameters.h
#1  ${MaracasSrcDir}/../../kernel/marDynData.cpp
#1  ${MaracasSrcDir}/../../kernel/marDynData.h

#1)

#1ADD_LIBRARY(maracasvisu STATIC  ${MARACASVISU_LIB_SRCS} )
#1TARGET_LINK_LIBRARIES(maracasvisu
#1  ${BBP_WXWIDGETS_LIBRARIES}
#1  vtkCommon  vtkFiltering  vtkGraphics   vtkImaging  vtkRendering vtkHybrid
#1  vtkWidgets vtkVolumeRendering vtkHybrid 
#1  #vtkIO 
#1  ${LIBIDO_LIBRARIES}
###  vtkgdcm
#1)

#===========================================================================
SET(${BBTK_PACKAGE_NAME}_LIBS 
  # LIST HERE THE ADDITIONAL LIBS TO LINK AGAINST
  # EXCEPT : the same libs than for INCLUDE_DIRS 
###  ${MYSQL_LIBRARIES}

  ${OpenMP_libomp_LIBRARY_crea}

  creaMaracasVisu

  BaseVolumeRenderer
  BaseSurfaceRenderer
  GUIWxSurfaceRenderer
  GUIWxVolumeRenderer
  KernelViewerWidgets
  KernelVolumeRenderer
  KernelSurfaceRenderer

  #creaMaracasVisu_CutModule_interface
  #creaMaracasVisu_CutModule_kernel
###  ILPDModel.lib
###  ILPDInterface
###  ILPDcontrolerInterface


)
#===========================================================================

#===========================================================================
# SET TO TRUE TO HAVE INFORMATION ON LIBRARIES FOUND DURING CMAKE CONFIGURE
SET(FIND_PACKAGE_VERBOSE TRUE)
#===========================================================================

#===========================================================================
# END OF USER SECTION
#===========================================================================





#===========================================================================
# Include configuration script
INCLUDE(Configure.cmake)
#===========================================================================

#===========================================================================
# EOF
#===========================================================================

### ADD_SUBDIRECTORY( ../../src/interface/wxWindows/ILPD ILPD )
