My Project
2d/filter.hh
Go to the documentation of this file.
1/* -*- mia-c++ -*-
2 *
3 * This file is part of MIA - a toolbox for medical image analysis
4 * Copyright (c) Leipzig, Madrid 1999-2017 Gert Wollny
5 *
6 * MIA is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 3 of the License, or
9 * (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with MIA; if not, see <http://www.gnu.org/licenses/>.
18 *
19 */
20
21#ifndef mia_2d_filter_hh
22#define mia_2d_filter_hh
23
24#include <mia/2d/image.hh>
25#include <mia/core/factory.hh>
26#include <mia/core/filter.hh>
29
31
37
43
48typedef std::shared_ptr<C2DFilter > P2DFilter;
49
55
59
63inline P2DFilter produce_2dimage_filter(const char *descr)
64{
65 return C2DFilterPluginHandler::instance().produce(descr);
66}
67
68
83P2DImage EXPORT_2D run_filter_chain(P2DImage image, size_t nfilters, const char *filters[])
84__attribute__((deprecated));
85
94P2DImage EXPORT_2D run_filter_chain(P2DImage image, const std::vector<const char *>& filters);
95
103P2DImage EXPORT_2D run_filter(const C2DImage& image, const char *filter);
104
112inline P2DImage EXPORT_2D run_filter(P2DImage image, const char *filter)
113{
114 return run_filter(*image, filter);
115}
116
117
125typedef std::shared_ptr<C2DImageCombiner> P2DImageCombiner;
127
128
133
135{
136public:
138};
139
140
142
143
144#endif
P2DFilter produce_2dimage_filter(const char *descr)
Definition: 2d/filter.hh:63
THandlerSingleton< TFactoryPluginHandler< C2DImageCombinerPlugin > > C2DImageCombinerPluginHandler
Plugin handler for image combiner plugins.
Definition: 2d/filter.hh:131
std::shared_ptr< C2DImageCombiner > P2DImageCombiner
Definition: 2d/filter.hh:125
TFactory< C2DImageCombiner > C2DImageCombinerPlugin
Definition: 2d/filter.hh:126
FACTORY_TRAIT(C2DImageCombinerPluginHandler)
C2DImage::Pointer P2DImage
Shared pointer representation of the 2D Image.
Definition: 2d/image.hh:120
This is the base class for 2D images that can hold generic pixel data.
Definition: 2d/image.hh:48
Generic image filter plugin base.
Definition: core/filter.hh:186
Generic interface class to data filters.
Definition: core/filter.hh:87
This is tha base of all plugins that create "things", like filters, cost functions time step operator...
Definition: factory.hh:51
create and use a chain of filters
Definition: filter_chain.hh:41
the singleton that a plug-in handler really is
Definition: handler.hh:159
static const T & instance()
#define EXPORT_2D
Definition: defines2d.hh:37
#define NS_MIA_BEGIN
conveniance define to start the mia namespace
Definition: defines.hh:33
#define NS_MIA_END
conveniance define to end the mia namespace
Definition: defines.hh:36
TFilterChain< C2DFilterPluginHandler > C2DImageFilterChain
Definition: 2d/filter.hh:73
P2DImage EXPORT_2D run_filter_chain(P2DImage image, size_t nfilters, const char *filters[]) __attribute__((deprecated))
std::shared_ptr< C2DFilter > P2DFilter
Definition: 2d/filter.hh:48
TImageCombiner< C2DImage > C2DImageCombiner
2D Image combiner
Definition: 2d/filter.hh:124
static F::result_type filter(const F &f, const B &b)
Definition: core/filter.hh:258
P2DImage EXPORT_2D run_filter(const C2DImage &image, const char *filter)
THandlerSingleton< TFactoryPluginHandler< C2DFilterPlugin > > C2DFilterPluginHandler
Definition: 2d/filter.hh:54
TDataFilterPlugin< C2DImage > C2DFilterPlugin
Definition: 2d/filter.hh:42
TDataFilter< C2DImage > C2DFilter
Definition: 2d/filter.hh:36