Visual Servoing Platform version 3.6.0
Loading...
Searching...
No Matches
vpImageIoBackend.h
1/*
2 * ViSP, open source Visual Servoing Platform software.
3 * Copyright (C) 2005 - 2023 by Inria. All rights reserved.
4 *
5 * This software is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
9 * See the file LICENSE.txt at the root directory of this source
10 * distribution for additional information about the GNU GPL.
11 *
12 * For using ViSP with software that can not be combined with the GNU
13 * GPL, please contact Inria about acquiring a ViSP Professional
14 * Edition License.
15 *
16 * See https://visp.inria.fr for more information.
17 *
18 * This software was developed at:
19 * Inria Rennes - Bretagne Atlantique
20 * Campus Universitaire de Beaulieu
21 * 35042 Rennes Cedex
22 * France
23 *
24 * If you have questions regarding the use of this file, please contact
25 * Inria at visp@inria.fr
26 *
27 * This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
28 * WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
29 *
30 * Description:
31 * Backend functions implementation for image I/O operations.
32 */
33
39#ifndef _vpImageIoBackend_h_
40#define _vpImageIoBackend_h_
41
42#include <visp3/core/vpImage.h>
43
44// Portable FloatMap format (PFM)
45// Portable Graymap format (PGM)
46// Portable Pixmap format (PPM)
47void vp_writePFM(const vpImage<float> &I, const std::string &filename);
48void vp_writePFM_HDR(const vpImage<float> &I, const std::string &filename);
49void vp_writePFM_HDR(const vpImage<vpRGBf> &I, const std::string &filename);
50void vp_writePGM(const vpImage<unsigned char> &I, const std::string &filename);
51void vp_writePGM(const vpImage<short> &I, const std::string &filename);
52void vp_writePGM(const vpImage<vpRGBa> &I, const std::string &filename);
53void vp_readPFM(vpImage<float> &I, const std::string &filename);
54void vp_readPFM_HDR(vpImage<float> &I, const std::string &filename);
55void vp_readPFM_HDR(vpImage<vpRGBf> &I, const std::string &filename);
56void vp_readPGM(vpImage<unsigned char> &I, const std::string &filename);
57void vp_readPGM(vpImage<vpRGBa> &I, const std::string &filename);
58void vp_readPPM(vpImage<unsigned char> &I, const std::string &filename);
59void vp_readPPM(vpImage<vpRGBa> &I, const std::string &filename);
60void vp_writePPM(const vpImage<unsigned char> &I, const std::string &filename);
61void vp_writePPM(const vpImage<vpRGBa> &I, const std::string &filename);
62
63// libjpeg
64void readJPEGLibjpeg(vpImage<unsigned char> &I, const std::string &filename);
65void readJPEGLibjpeg(vpImage<vpRGBa> &I, const std::string &filename);
66
67void writeJPEGLibjpeg(const vpImage<unsigned char> &I, const std::string &filename, int quality);
68void writeJPEGLibjpeg(const vpImage<vpRGBa> &I, const std::string &filename, int quality);
69
70// libpng
71void readPNGLibpng(vpImage<unsigned char> &I, const std::string &filename);
72void readPNGLibpng(vpImage<vpRGBa> &I, const std::string &filename);
73
74void writePNGLibpng(const vpImage<unsigned char> &I, const std::string &filename);
75void writePNGLibpng(const vpImage<vpRGBa> &I, const std::string &filename);
76
77// OpenCV
78void readOpenCV(vpImage<unsigned char> &I, const std::string &filename);
79void readOpenCV(vpImage<vpRGBa> &I, const std::string &filename);
80void readOpenCV(vpImage<float> &I, const std::string &filename);
81void readOpenCV(vpImage<vpRGBf> &I, const std::string &filename);
82
83void writeOpenCV(const vpImage<unsigned char> &I, const std::string &filename, int quality);
84void writeOpenCV(const vpImage<vpRGBa> &I, const std::string &filename, int quality);
85void writeOpenCV(const vpImage<float> &I, const std::string &filename);
86void writeOpenCV(const vpImage<vpRGBf> &I, const std::string &filename);
87
88// Simd lib
89void readSimdlib(vpImage<unsigned char> &I, const std::string &filename);
90void readSimdlib(vpImage<vpRGBa> &I, const std::string &filename);
91
92// TinyEXR lib
93#if (VISP_CXX_STANDARD >= VISP_CXX_STANDARD_11)
94void readEXRTiny(vpImage<float> &I, const std::string &filename);
95void readEXRTiny(vpImage<vpRGBf> &I, const std::string &filename);
96#endif
97
98void writeJPEGSimdlib(const vpImage<unsigned char> &I, const std::string &filename, int quality);
99void writeJPEGSimdlib(const vpImage<vpRGBa> &I, const std::string &filename, int quality);
100
101void writePNGSimdlib(const vpImage<unsigned char> &I, const std::string &filename);
102void writePNGSimdlib(const vpImage<vpRGBa> &I, const std::string &filename);
103
104// stb lib
105void readStb(vpImage<unsigned char> &I, const std::string &filename);
106void readStb(vpImage<vpRGBa> &I, const std::string &filename);
107
108void writeJPEGStb(const vpImage<unsigned char> &I, const std::string &filename, int quality);
109void writeJPEGStb(const vpImage<vpRGBa> &I, const std::string &filename, int quality);
110
111void writePNGStb(const vpImage<unsigned char> &I, const std::string &filename);
112void writePNGStb(const vpImage<vpRGBa> &I, const std::string &filename);
113
114// TinyEXR lib
115#if (VISP_CXX_STANDARD >= VISP_CXX_STANDARD_11)
116void writeEXRTiny(const vpImage<float> &I, const std::string &filename);
117void writeEXRTiny(const vpImage<vpRGBf> &I, const std::string &filename);
118#endif
119
120#endif
Definition of the vpImage class member functions.
Definition vpImage.h:135