DGtal
2.2.0
Toggle main menu visibility
Loading...
Searching...
No Matches
ITKIOTrait.h
1
16
17
#pragma once
18
30
31
#if defined(ITKIOTrait_RECURSES)
32
#error Recursive header files inclusion detected in ITKIOTrait.h
33
#else
// defined(ITKIOTrait_RECURSES)
35
#define ITKIOTrait_RECURSES
36
37
#if !defined ITKIOTrait_h
39
#define ITKIOTrait_h
40
41
#include "DGtal/base/BasicFunctors.h"
42
43
namespace
DGtal
44
{
48
[[maybe_unused]]
const
auto
ITK_IO_IMAGE_EXT
= {
"nii"
,
"gz"
,
"mha"
,
"mhd"
,
"tiff"
,
"nrrd"
,
49
"tif"
,
"pic"
,
"mnc"
};
50
51
53
// class ITKIOTrait
60
template
<
typename
Value>
61
struct
ITKIOTrait
62
{
63
typedef
Value
ValueOut
;
// Associated ITK image value type
64
typedef
functors::Cast<ValueOut>
DefaultWriteFunctor
;
// Default functor used by ITKWriter
65
typedef
functors::Cast<Value>
DefaultReadFunctor
;
// Default functor used by ITKReader
66
67
private
:
68
73
ITKIOTrait
();
74
ITKIOTrait
(
const
ITKIOTrait
& other);
75
ITKIOTrait
&
operator=
(
const
ITKIOTrait
& other);
76
77
78
};
// end of struct ITKIOTrait
79
80
// specialization
81
template
<>
82
struct
ITKIOTrait
<bool>
83
{
84
typedef
unsigned
char
ValueOut
;
85
typedef
functors::Cast<unsigned char>
DefaultWriteFunctor
;
86
typedef
functors::Cast<bool>
DefaultReadFunctor
;
87
};
88
89
}
// namespace DGtal
90
91
92
#endif
// !defined ITKIOTrait_h
93
94
#undef ITKIOTrait_RECURSES
95
#endif
// else defined(ITKIOTrait_RECURSES)
DGtal
DGtal is the top-level namespace which contains all DGtal functions and types.
Definition
ClosedIntegerHalfPlane.h:49
DGtal::ITK_IO_IMAGE_EXT
const auto ITK_IO_IMAGE_EXT
Definition
ITKIOTrait.h:48
DGtal::ITKIOTrait< bool >::ValueOut
unsigned char ValueOut
Definition
ITKIOTrait.h:84
DGtal::ITKIOTrait< bool >::DefaultReadFunctor
functors::Cast< bool > DefaultReadFunctor
Definition
ITKIOTrait.h:86
DGtal::ITKIOTrait< bool >::DefaultWriteFunctor
functors::Cast< unsigned char > DefaultWriteFunctor
Definition
ITKIOTrait.h:85
DGtal::ITKIOTrait::ITKIOTrait
ITKIOTrait()
DGtal::ITKIOTrait::DefaultWriteFunctor
functors::Cast< ValueOut > DefaultWriteFunctor
Definition
ITKIOTrait.h:64
DGtal::ITKIOTrait::DefaultReadFunctor
functors::Cast< Value > DefaultReadFunctor
Definition
ITKIOTrait.h:65
DGtal::ITKIOTrait::operator=
ITKIOTrait & operator=(const ITKIOTrait &other)
DGtal::ITKIOTrait::ITKIOTrait
ITKIOTrait(const ITKIOTrait &other)
DGtal::ITKIOTrait::ValueOut
Value ValueOut
Definition
ITKIOTrait.h:63
DGtal::Value
DGtal::functors::Cast
Aim: Define a simple functor using the static cast operator.
Definition
BasicFunctors.h:394
src
DGtal
io
ITKIOTrait.h
Generated on
for DGtal by
1.18.0