From 1ada4361449e88bf02a0b92c8d4ab779fe8d4466 Mon Sep 17 00:00:00 2001 From: Matt McCormick Date: Tue, 1 Nov 2022 23:20:23 -0400 Subject: [PATCH] build: Remove SupportInputImageTypesNoVectorImage No longer needed following #679. --- .../itkSupportInputImageTypesNoVectorImage.h | 182 ------------------ src/core/InterfaceTypes.ts | 2 +- ...itkSupportInputImageTypesNoVectorImage.cxx | 77 -------- .../median-filter-test.cxx | 4 +- 4 files changed, 3 insertions(+), 262 deletions(-) delete mode 100644 include/itkSupportInputImageTypesNoVectorImage.h delete mode 100644 src/itkSupportInputImageTypesNoVectorImage.cxx diff --git a/include/itkSupportInputImageTypesNoVectorImage.h b/include/itkSupportInputImageTypesNoVectorImage.h deleted file mode 100644 index 3502c765d..000000000 --- a/include/itkSupportInputImageTypesNoVectorImage.h +++ /dev/null @@ -1,182 +0,0 @@ -/*========================================================================= - * - * Copyright NumFOCUS - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0.txt - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - *=========================================================================*/ -#ifndef itkSupportInputImageTypesNoVectorImage_h -#define itkSupportInputImageTypesNoVectorImage_h -#include "itkPipeline.h" -#include "itkWASMPixelTypeFromIOPixelEnum.h" -#include "itkWASMComponentTypeFromIOComponentEnum.h" -#include "itkDefaultConvertPixelTraits.h" -#include "itkWASMMapComponentType.h" -#include "itkWASMMapPixelType.h" - -#include "itkImage.h" -#include "itkVectorImage.h" -#include "itkImageIOBase.h" -#include "itkImageIOFactory.h" - -namespace itk -{ - -namespace wasm -{ - -struct InterfaceImageTypeNoVectorImage -{ - unsigned int dimension{2}; - std::string componentType{"uint8"}; - std::string pixelType{"Scalar"}; - unsigned int components{1}; -}; - -bool lexical_cast(const std::string &input, InterfaceImageTypeNoVectorImage & imageType); - -/** \class SupportInputImageTypesNoVectorImage - * - * \brief Instantiatiate a Pipeline functor over multiple pixel types and dimensions and match to the input image type. - * - * Instantiate the PipelineFunctor (function object) over multiple pixel types and image dimensions. - * If the input image matches these pixel types or dimensions, use the compile-time optimized pipeline for that image type. - * Otherwise, exit the pipeline with an error identifying the unsupported image type. - * - * Example usage: - * -``` -template -class PipelineFunctor -{ -public: - int operator()(itk::wasm::Pipeline & pipeline) - { - using ImageType = TImage; - - using InputImageType = itk::wasm::InputImage; - InputImageType inputImage; - pipeline.add_option("input-image", inputImage, "The input image")->required(); -``` -[...] - -``` -int -main(int argc, char * argv[]) -{ - itk::wasm::Pipeline pipeline("support-multiple", "Test supporting multiple input image types", argc, argv); - - // Supports the pixels types uint8_t, float - // Supports the image dimensions 2, 3 - return itk::wasm::SupportInputImageTypesNoVectorImage - ::Dimensions<2U,3U>("input-image", pipeline); -} -``` - * - * \ingroup WebAssemblyInterface - */ -template