Mercurial > hg > orthanc-stone
diff Framework/Toolbox/DicomStructureSet.cpp @ 1006:4f28d9459e31 toa2019092001
Fixed unit tests and deprecated classes according to last API changes. UT all run ok.
author | Benjamin Golinvaux <bgo@osimis.io> |
---|---|
date | Fri, 20 Sep 2019 12:13:10 +0200 |
parents | 50e5acf5553b |
children | 53cc787bd7bc |
line wrap: on
line diff
--- a/Framework/Toolbox/DicomStructureSet.cpp Fri Sep 20 12:01:20 2019 +0200 +++ b/Framework/Toolbox/DicomStructureSet.cpp Fri Sep 20 12:13:10 2019 +0200 @@ -81,7 +81,7 @@ } } -#ifdef USE_OLD_SJO_CUT_CODE +#ifdef USE_BOOST_UNION_FOR_POLYGONS static BoostPolygon CreateRectangle(float x1, float y1, float x2, float y2) @@ -803,7 +803,7 @@ } } -#ifdef USE_OLD_SJO_CUT_CODE +#ifdef USE_BOOST_UNION_FOR_POLYGONS bool DicomStructureSet::ProjectStructure(std::vector< std::vector<Point2D> >& polygons, const Structure& structure, const CoordinateSystem3D& slice) const @@ -813,7 +813,7 @@ const CoordinateSystem3D& slice) const #endif { -#ifdef USE_OLD_SJO_CUT_CODE +#ifdef USE_BOOST_UNION_FOR_POLYGONS polygons.clear(); #else segments.clear(); @@ -831,7 +831,7 @@ { if (polygon->IsOnSlice(slice)) { -#ifdef USE_OLD_SJO_CUT_CODE +#ifdef USE_BOOST_UNION_FOR_POLYGONS polygons.push_back(std::vector<Point2D>()); for (Points::const_iterator p = polygon->GetPoints().begin(); @@ -882,7 +882,7 @@ #if 1 // Sagittal or coronal projection -#ifdef USE_OLD_SJO_CUT_CODE +#ifdef USE_BOOST_UNION_FOR_POLYGONS std::vector<BoostPolygon> projected; #else // this will contain the intersection of the polygon slab with @@ -909,7 +909,7 @@ static_cast<float>(y2)),curZ)); } } -#ifndef USE_OLD_SJO_CUT_CODE +#ifndef USE_BOOST_UNION_FOR_POLYGONS // projected contains a set of rectangles specified by two opposite // corners (x1,y1,x2,y2) // we need to merge them