[mitk-users] mitk project vector field visualization

2021-04-09 Thread Floca, Ralf Omar
Hi Julian,

you are right a visualization of vector fields is possible but currently 
somewhat hidden.

You can find the needed code for vector field visualization in the 
MatchPointRegistration modul.

It is done by the mapper classes MITKRegistrationWrapperMapper2D and 
MITKRegistrationWrapperMapper3D.

Those classes visualize instances of mitk::MAPRegistrationWrapper.
mitk::MAPRegistrationWrapper is basically a wrapper around itk::Transforms with 
a lot of higher level functionality.
So if you have an itk::Transform (this would also work with an itk::Image with 
vectors as there is an itk transform wrapper for that), you could pack it into 
a MatchPoint registration instance.

The very heart of the glyph field generation can be found in mitk:: 
Generate3DDeformationGlyph(...) 
(../Modules/MatchPointRegistration/src/Rendering/mitkRegVisHelper.cpp). Here, 
based on a passed transform and a given geometry, the glyph field is 
constructed.

How you alter/change the visualization is demonstrated in the plugin 
org.mitk.ui.qt.matchpoint.visualizer.

Hope that helps a bit.

Best,
Ralf 

--
Message: 2
Date: Thu, 8 Apr 2021 13:32:40 +0200
From: Julian Kuhm 
To: mitk-users@lists.sourceforge.net
Subject: [mitk-users] mitk project vector field visualization
Message-ID: 
Content-Type: text/plain; charset=utf-8; format=flowed

Hi everyone,

When I look at your project site and specifically inspect the image
here: 
https://www.mitk.org/w/images/thumb/3/34/Projects%24Lung.png/225px-Projects%24Lung.png

I can see you are working on a project (dynamic analysis of respiratory
movement) to visualize lung motion with a quiver overlay. Is this functionality 
of depicting motion vector fields somewhere available? Do you offer the mapper 
for the visualization of the vectors?

Best regards,

Julian




--



--

Subject: Digest Footer

___
mitk-users mailing list
mitk-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mitk-users


--

End of mitk-users Digest, Vol 179, Issue 4
**


smime.p7s
Description: S/MIME cryptographic signature
___
mitk-users mailing list
mitk-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mitk-users


Re: [mitk-users] PluginGenerator and ProjectTemplate

2021-04-09 Thread Dinkelacker, Stefan
Hi,


the project template (or generally speaking an "MITK extension") can be built 
just like plain MITK, there is nothing extra or separate script/code paths in 
our build scripts. That's the cool thing about the project template/MITK 
extensions. It mirrors the MITK directory structure and all the magic happens 
within the MITK build system, not the project template build system. It 
basically works by following path and filename conventions. It is virtually 
like forking the MITK repository and adding dependencies, modules, plugins, 
applications, and build configurations right to the MITK repo, but with the 
advantage that you do not have to touch the original repo but have an extra 
directory/repo for your own stuff that is "mounted" into the MITK directory.


Notice that the project template is full of examples/demos that you do not need 
for your own stuff. Their purpose is to show how things are supposed to be done 
and that it is just like you would do stuff right in the MITK directory. One of 
the examples is that even the configurations of a few MITK-dependencies like 
ITK can be modified from an extension [1]. And this is why MITK was basically 
rebuilt completely when you added the ProjectTemplate itself to 
MITK_EXTENSION_DIRS since ITK as a core dependency needed a rebuild.


Since you already have all your stuff and just want to migrate, start with an 
empty directory instead of the project template and just use the project 
template as an example-based manual/inspiration.


For example, a minimum start could be to simple create a Modules folder, put a 
ModuleList.cmake in it and reference your first module [2]. That's all you need 
to add a module to MITK. When you then add your root directory to 
MITK_EXTENSION_DIRS (you can also do this in the MITK-build, not only in the 
MITK-superbuild as long as you do not change anything on superbuild-level), 
MITK will look for a Modules/ModuleList.cmake files not only in its own root 
directory but in all extension dirs and handle it just like its own 
Modules/ModuleList.cmake file.


Best,

Stefan


[1] 
https://github.com/MITK/MITK-ProjectTemplate/blob/master/CMakeExternals/Customization/ITK.cmake

[2] https://github.com/MITK/MITK-ProjectTemplate/tree/master/Modules



Von: Nil Goyette 
Gesendet: Freitag, 9. April 2021 04:19
An: Dinkelacker, Stefan
Cc: mitk-users@lists.sourceforge.net
Betreff: Re: [mitk-users] PluginGenerator and ProjectTemplate

Hi Stefan,
I'm still unable to generate the solution, with Qt5.12 or Qt5.15, with or 
without a reference to MitkAppUtil, with or without a 
"find_package(Qt5WebEngine REQUIRED)".. I get the same error as before.
This being said, I think I need to clarify the framework/library thing before 
we go further. If I understand correctly:

  *   MITK as a framework. Should use the ProjectTemplate and link to this 
template in the MITK superbuild.
  *   MITK as a library.. Use our own cmake and link to MITK build dir.

In our case, we use the standard MITK UI and features, we pick some useful MITK 
plugins and add some of our own. This is a "framework" usage, right? I tried 
the ProjectTemplate approach once and what I really disliked is that it 
recompiled MITK in full when I told cmake the MITK_EXTENSION_DIRS to my 
project. This is not compatible with our build system where we build MITK once 
and use the build artifacts to build our own project fast. Do you have a 
solution for this?
Nil

Le mer. 7 avr. 2021, à 06 h 59, Dinkelacker, Stefan 
mailto:s.dinkelac...@dkfz-heidelberg.de>> a 
écrit :

Hi,


my first guess is that your executable is infected with this dependency from 
MitkAppUtil, which has a PUBLIC package dependency to WebEngine. Usually CMake 
is right in its assumptions regarding find_package(). So a first step would be 
to do a manual find_package for WebEngine and continue from there. If it still 
cannot be found, but other components of Qt were found, double-check your 
installation and maybe manually look for the Config.cmake file in the lib/cmake 
subfolder of your Qt installation. Since you seem to use MITK as library it is 
hard to make better guesses at the moment. I also did not use Qt 5.15 yet, only 
5.12.


Best,

Stefan


Von: Nil Goyette mailto:nil.goye...@imeka.ca>>
Gesendet: Dienstag, 6. April 2021 17:21
An: Dinkelacker, Stefan
Cc: mitk-users@lists.sourceforge.net
Betreff: Re: [mitk-users] PluginGenerator and ProjectTemplate

Hi Stefan,

My module wasn't found because I included "MitkTestingHelper" in the wrong 
place. There was no useful error message so I had to guess it.
But now I have another problem and you may be able to help me. The CMake 
Configure part is ok, but when I click on Generate, I get this error

CMake Error at 
C:/Imeka/mitk/CMake/mitkFunctionCreateBlueBerryApplication.cmake:88 
(add_executable):
Target "MI-Brain" links to target "Qt5::WebEngine" but the