Skip to content

Commit 89a7300

Browse files
committed
STYLE: address unused variable warnings.
Types and variables that were unused were removed to avoid compiler warnings.
1 parent 4f177b2 commit 89a7300

File tree

3 files changed

+11
-8
lines changed
  • src
    • Core/Transform/GlobalRegistrationTwoImagesBSpline
    • Filtering
      • LabelMap/ShapeAttributesForBinaryImage
      • Thresholding/DemonstrateThresholdAlgorithms

3 files changed

+11
-8
lines changed

src/Core/Transform/GlobalRegistrationTwoImagesBSpline/Code.cxx

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@
3030
#include "itkImageFileWriter.h"
3131
#include "itkResampleImageFilter.h"
3232
#include "itkCastImageFilter.h"
33-
#include "itkSquaredDifferenceImageFilter.h"
3433

3534
#ifdef ENABLE_QUICKVIEW
3635
# include "QuickView.h"
@@ -42,9 +41,9 @@ using PixelType = float;
4241
using ImageType = itk::Image<PixelType, ImageDimension>;
4342

4443
static void
45-
CreateEllipseImage(ImageType::Pointer image);
44+
CreateEllipseImage(const ImageType::Pointer & image);
4645
static void
47-
CreateCircleImage(ImageType::Pointer image);
46+
CreateCircleImage(const ImageType::Pointer & image);
4847

4948
int
5049
main(int itkNotUsed(argc), char * itkNotUsed(argv)[])
@@ -252,7 +251,7 @@ main(int itkNotUsed(argc), char * itkNotUsed(argv)[])
252251
}
253252

254253
void
255-
CreateEllipseImage(ImageType::Pointer image)
254+
CreateEllipseImage(const ImageType::Pointer & image)
256255
{
257256
using EllipseType = itk::EllipseSpatialObject<ImageDimension>;
258257

@@ -300,7 +299,7 @@ CreateEllipseImage(ImageType::Pointer image)
300299
}
301300

302301
void
303-
CreateCircleImage(ImageType::Pointer image)
302+
CreateCircleImage(const ImageType::Pointer & image)
304303
{
305304
using EllipseType = itk::EllipseSpatialObject<ImageDimension>;
306305

src/Filtering/LabelMap/ShapeAttributesForBinaryImage/Code.cxx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@
2222

2323
template <typename TImage>
2424
static void
25-
CreateImage(TImage * const image);
25+
CreateImage(TImage * image);
2626

2727
int
28-
main(int argc, char * argv[])
28+
main(int argc, char * [])
2929
{
3030
constexpr unsigned int Dimension = 2;
3131
using PixelType = unsigned char;

src/Filtering/Thresholding/DemonstrateThresholdAlgorithms/Code.cxx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,9 +51,13 @@ main(int argc, char * argv[])
5151
}
5252
#ifdef ENABLE_QUICKVIEW
5353
using InputPixelType = short;
54-
using OutputPixelType = unsigned char;
5554

5655
using InputImageType = itk::Image<InputPixelType, 2>;
56+
57+
const auto input = itk::ReadImage<InputImageType>(argv[1]);
58+
59+
#ifdef ENABLE_QUICKVIEW
60+
using OutputPixelType = unsigned char;
5761
using OutputImageType = itk::Image<OutputPixelType, 2>;
5862

5963
using LiFilterType = itk::LiThresholdImageFilter<InputImageType, OutputImageType>;

0 commit comments

Comments
 (0)