3d/imageio.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-2013 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_3d_3dimageui_hh
22 #define mia_3d_3dimageui_hh
23 
24 #include <set>
25 #include <vector>
26 #include <mia/core/ioplugin.hh>
27 #include <mia/core/iohandler.hh>
28 #include <mia/3d/image.hh>
29 
31 
32 
37 class EXPORT_3D C3DImageVector: public std::vector< std::shared_ptr<C3DImage >> ,
38  public CIOData {
39 public:
41  C3DImageVector *clone() const __attribute__((warn_unused_result));
42 
43 };
44 
47  static const char *data_descr;
48 };
54 
60 
65 typedef C3DImageIOPluginHandler::Instance::DataKey C3DImageDataKey;
66 
71 typedef C3DImageIOPluginHandler::Instance::PData P3DImageVector;
72 
78 struct EXPORT_3D C3DImageIOPluginHandlerTestPath {
79  C3DImageIOPluginHandlerTestPath();
80 };
82 
90 
99 P3DImage EXPORT_3D load_image3d(const std::string& filename);
100 
101 
109 template <>
110 inline P3DImage EXPORT_3D load_image<P3DImage>(const std::string& filename)
111 {
112  cvdebug() << "Load image " << filename << "\n";
113  return load_image3d(filename);
114 }
115 
124 bool EXPORT_3D save_image(const std::string& filename, P3DImage image);
125 
126 
134 bool EXPORT_3D save_image(const std::string& filename, C3DImage& image);
135 
136 
138 
139 #endif