Skip to content

Commit

Permalink
feat(compare-images): build native pipeline
Browse files Browse the repository at this point in the history
Add test images from ITKImageCompare module test.
  • Loading branch information
thewtex committed Aug 21, 2023
1 parent 1dbda9d commit 195dddf
Show file tree
Hide file tree
Showing 4 changed files with 53 additions and 0 deletions.
15 changes: 15 additions & 0 deletions packages/compare-images/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
cmake_minimum_required(VERSION 3.16)
project(itkwasm-dicom)

set(CMAKE_CXX_STANDARD 17)

find_package(ITK REQUIRED
COMPONENTS
WebAssemblyInterface
ITKImageIntensity
ITKTestKernel
)
include(${ITK_USE_FILE})

add_executable(compare-images compare-images.cxx)
target_link_libraries(compare-images PUBLIC ${ITK_LIBRARIES})
38 changes: 38 additions & 0 deletions packages/compare-images/compare-images.cxx
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
/*=========================================================================
* 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.
*
*=========================================================================*/

#include "itkPipeline.h"
#include "itkInputImage.h"
#include "itkOutputImage.h"
#include "itkOutputTextStream.h"

#include "itkImage.h"
#include "itkRescaleIntensityImageFilter.h"
#include "itkExtractImageFilter.h"
#include "itkTestingComparisonImageFilter.h"

#define ITK_TEST_DIMENSION_MAX 6

int main(int argc, char * argv[])
{
itk::wasm::Pipeline pipeline("compare-images", "Compare images with a tolerance for regression testing.", argc, argv);

ITK_WASM_PARSE(pipeline);

return EXIT_SUCCESS;
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 195dddf

Please sign in to comment.