open_iA 2023.04
A tool for the visual analysis and processing of volumetric datasets, with a focus on industrial computed tomography.
|
Default GUI runner for an iAFilter. More...
#include <iAFilterRunnerGUI.h>
Signals | |
void | finished () |
Signal which by default (in the default ConnectThreadSignals) is connected to be emitted at the end of the filter thread run. | |
Public Member Functions | |
virtual bool | askForParameters (std::shared_ptr< iAFilter > filter, QVariantMap ¶mValues, iAMdiChild *sourceMdi, iAMainWindow *mainWnd, bool askForAdditionalInput) |
Prompts the user to adapt the parameters to his needs for the current filter run. | |
virtual void | filterGUIPreparations (std::shared_ptr< iAFilter > filter, iAMdiChild *mdiChild, iAMainWindow *mainWnd, QVariantMap const ¶ms) |
do any potentially necessary GUI preparations (directly before the filter is run) | |
virtual QVariantMap | loadParameters (std::shared_ptr< iAFilter > filter, iAMdiChild *sourceMdi) |
Loads parameters from the platform-specific store. | |
virtual void | run (std::shared_ptr< iAFilter > filter, iAMainWindow *mainWnd) |
Main run method. | |
virtual void | storeParameters (std::shared_ptr< iAFilter > filter, QVariantMap ¶mValues) |
Store parameters in the platform-specific store. | |
Static Public Member Functions | |
static std::shared_ptr< iAFilterRunnerGUI > | create () |
Method to create an instance of this runner. | |
Default GUI runner for an iAFilter.
For the given descendant of iAFilter, this method loads its settings from the platform-specific settings store (Registry under Windows, .config folder under Unix, ...). Then it shows a dialog to the user to change these parameters. Afterwards it checks the parameters with the given filter. If they are ok, it stores them back to the settings store. Subsequently it creates a thread for the given filter, assigns the slots required for progress indication, final display and cleanup, and finally it runs the filter with the parameters.
|
virtual |
Prompts the user to adapt the parameters to his needs for the current filter run.
filter | the filter that should be run |
paramValues | the parameter values as loaded from the platform-specific settings store |
sourceMdi | the mdi child that is the main image source for this filter |
mainWnd | access to the main window (as parent for GUI windows) |
askForAdditionalInput | whether the parameter dialog should also ask for additional inputs if the filter requires more than 1 |
|
static |
Method to create an instance of this runner.
If you override this class, don't forget to create your own Create method (called from the factory template), otherwise still an iAFilterRunnerGUI will be created!
|
virtual |
do any potentially necessary GUI preparations (directly before the filter is run)
|
signal |
Signal which by default (in the default ConnectThreadSignals) is connected to be emitted at the end of the filter thread run.
|
virtual |
Loads parameters from the platform-specific store.
filter | the filter for which to load the parameters |
sourceMdi | the mdi child which was active when the filter was started. Not used in the standard implementation, but may be used by overriding classes to access properties of the input file, e.g. in the extract image filter it is used to get the size of the input image. |
|
virtual |
Main run method.
Calls all the other (non-static) methods in this class. Override only if you want to change the whole way the filter running works; typically you will only want to override one of the methods below
filter | the filter to run |
mainWnd | access to the main window |
TODO: find way to check parameters already in iAParameterDlg (before closing)
|
virtual |
Store parameters in the platform-specific store.
filter | the filter for which to store the parameters |
paramValues | the parameters and their values |