MeVisLab Toolbox Reference
Loading...
Searching...
No Matches
mlManagedSubImage.h
Go to the documentation of this file.
1/*************************************************************************************
2**
3** Copyright 2009, 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_MANAGED_SUB_IMAGE_H
14#define ML_MANAGED_SUB_IMAGE_H
15
16// Local includes
18
19// ML includes
20#include <mlSubImage.h>
21
23
27
31{
32public:
35
38 {
39 SubImage::operator=(si);
40 return *this;
41 }
42
45 {
46 free();
47 };
48
53 void* takeData()
54 {
55 void* data = getData();
56 setData(nullptr);
57 return data;
58 }
59};
60
61
63
64#endif
ManagedSubImage is derived from SubImage and frees its allocated memory automatically when it is dest...
ManagedSubImage()
Constructor.
ManagedSubImage & operator=(const SubImage &si)
Copy operator from SubImage.
~ManagedSubImage() override
Destruct the object and freeing the memory.
void * takeData()
Returns the data pointer and set the internal data to NULL (so it passes the ownership of the data to...
This class manages/represents a rectangular 6D image region that is organized linearly in memory.
Definition mlSubImage.h:75
Target mlrange_cast(Source arg)
Generic version of checked ML casts.