After this is rerun cmake (version 3.10) and configured the build with Module_ITKOBBLabelMap=ON.
Clicked Configure, then Generate.
When I opened the solution file in VS2015 the external module is listed as project ‘ITKOBBLabelMap-all’. I built the project. The build was successful (at least what VS said).
Once I open a file from the module. I got errors because of missing header files for ITK modules. For example in “itkBoundingBoxImageLabelMapFilter.h” “itkInPlaceLabelMapFilter.h” could not be found. I checked the project configurations and neither include paths (except from the standard paths are set) nor libs were set/linked.
When I set up an own project with the module the headers are found (CMakeLists.txt and testfile.cxx below). But if I want to build it the same errors are shown as before.
Unfortunately External Module Wikipage does not provide more information.
Maybe the CMakeLists file of the external module is not up-to-date or did i miss a step?
(I am using Windows 10, 64bit, cmake-gui, VS2015)
I scanned through the proposed additions but I didnt find anything helpful.
After incorporating your change in the CMakeLists.txt the errors still exist.
By running the WhatModulesITK.py script the result was that I need one module since I have only a single include.
interestingly if I use the right-click to open the itkobb-include files using the dropdown menu it works in my test example but not in the ITK-project with the external module.
That is my module I worked on quite a few years ago at this point. Has not been updated much, and the documentation was thin to say the least.
The computations for the Oriented Bounding Box has been integrated in ITK as part of the LabelShapObject computed in the ShapeLabelMapFilter which is utilized by the convenient LabelImageToShapLabelMapFilter. This method has been improved for performance, and accuracy along with now being thoroughly tested with non-trivial oriented images.
The one filter you utilized, OrientedBoundingBoxImageLabelMapFilter, utilizes that above it formation to resample into original image in to oriented smaller images. This has not been incorporated into ITK (yet?). But it’s fairly trivial to just use the ResampleImageFilter.
There is also a SimpleITK note book which demonstrates this usage:
I have a rather simple question regarding external modules as well. I’m interested in using the code for Label object representation and manipulation with ITK. However, when I download the source code, place it in ITK/Modules/External and rerun CMake, I don’t see any flag to turn on this particular module. Could you please help me with this?