MeVisLab Toolbox Reference
mlImageFormatLoad.h
Go to the documentation of this file.
1/*************************************************************************************
2**
3** Copyright 2007, MeVis Medical Solutions AG
4**
5** The user may use this file in accordance with the license agreement provided with
6** the Software or, alternatively, in accordance with the terms contained in a
7** written agreement between the user and MeVis Medical Solutions AG.
8**
9** For further information use the contact form at https://www.mevislab.de/contact
10**
11**************************************************************************************/
12
13#ifndef ML_IMAGE_FORMAT_LOAD_H
14#define ML_IMAGE_FORMAT_LOAD_H
15
16
20
21#include "MLImageFormatSystem.h"
22
23// ML includes
24#include "mlModuleIncludes.h"
25
26#include "mlDataCompressor.h"
27
28#include "mlImageFormatIOBase.h"
29
30
32
34class MLImageFormat;
35
36// ----------------------------------------------------------
39// ----------------------------------------------------------
41{
42public:
43
46 Off = 0,
49
50 NumApplyModes
51 };
52
55
58
59protected:
60
61 // ----------------------------------------------------------
64 // ----------------------------------------------------------
66 virtual void _open();
67
69 virtual void _close();
71
72 // ----------------------------------------------------------
75 // ----------------------------------------------------------
77 void activateAttachments() override;
78
80 void handleNotification (Field *field) override;
82
83 // ----------------------------------------------------------
86 // ----------------------------------------------------------
89
96
98
99private:
100
101 // ----------------------------------------------------------
104 // ----------------------------------------------------------
106 MLImageFormat *_loader;
107
109 EnumField *_applyModeFld;
110
112 NotifyField *_closeFld;
113
115 NotifyField *_openFld;
116
120 BoolField *_suppressCheckSumTestsFld;
122
125};
126
127
129
130#endif // __mlImageFormatLoad_H
131
132
#define MLIMAGEFORMAT_EXPORT
Global and OS specific declarations for the MLImageFormat project.
Field to encapsulate a boolean value.
Definition mlFields.h:58
Field to encapsulate an enumerated value.
Definition mlFields.h:195
Base class for all fields used in the ML.
Definition mlField.h:73
IO base class to manage/save/load/modify .mlimage files and to derive specific save,...
ML module class to load an ML PagedImage from a file of type MLImageFormat with .mlimage suffix.
ApplyModes
Modes how module reacts on parameter changes.
@ AutoApply
Updates loaded image on all parameter changes.
@ AutoClear
Invalidates loaded image on each change.
virtual void _close()
Closes file and deletes loader instance.
MLImageFormatLoad()
Constructor.
void handleNotification(Field *field) override
Handle field changes of the field field.
void activateAttachments() override
Update internal module state after load or clone.
void calculateOutputImageProperties(int outputIndex, PagedImage *outputImage) override
Sets properties of the output image at output outIndex.
~MLImageFormatLoad() override
Destructor, closes file if still not done.
void calculateOutputSubImage(SubImage *outSubImg, int outIndex, SubImage *inSubImgs) override
Calculates page outSubImg of output image with index outIndex by using inSubimgs.
virtual void _open()
Create loader instance, opens file and provide it at module output.
File format class to store, load, and modify a PagedImage in a file.
Field without value for notifications.
Definition mlFields.h:659
Class which represents an image, which manages properties of an image and image data which is located...
This class manages/represents a rectangular 6d image region which is organized linearly in memory.
Definition mlSubImage.h:75
#define ML_MODULE_CLASS_HEADER(className)
Like ML_CLASS_HEADER for the usage of derived classes from Module.
Target mlrange_cast(Source arg)
Generic version of checked ML casts.
@ Off
Module does not react on input change, output WEM remains.