SlicerRt / SlicerRT

Open-source toolkit for radiation therapy research, an extension of 3D Slicer. Features include DICOM-RT import/export, dose volume histogram, dose accumulation, external beam planning (TPS), structure comparison and morphology, isodose line/surface generation, etc.
https://slicerrt.org
128 stars 60 forks source link

Compilation error in plastimatch because of redefinition of DirectionType #219

Closed MichaelColonel closed 1 year ago

MichaelColonel commented 1 year ago

The typedef typedef itk::Matrix < double, 3, 3 > DirectionType; is defined twice: here and here, hence a compilation error.

Possible fix:

In file direction_cosines.h delete DirectionType definition and add itk_image.h header

....
#include "itk_image.h"
#include "plm_math.h"

#define DIRECTION_COSINES_IDENTITY_THRESH 1e-9
#define DIRECTION_COSINES_EQUALITY_THRESH 1e-9

namespace itk { template<class T, unsigned int NRows, unsigned int NColumns> class Matrix; }
//typedef itk::Matrix < double, 3, 3 > DirectionType;
....
MichaelColonel commented 1 year ago

Here is the Pull Request for possible Plastimatch fix.

MichaelColonel commented 1 year ago

Pull Request for Plastimatch update is #220.