YARP  2.3.68+220-20170323.2+git4955ef0
Yet Another Robot Platform
ImageFile.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2007 RobotCub Consortium
3  * Authors: Lorenzo Natale and Paul Fitzpatrick
4  * CopyPolicy: Released under the terms of the LGPLv2.1 or later, see LGPL.TXT
5  */
6 
7 
8 #ifndef YARP_SIG_IMAGEFILE_H
9 #define YARP_SIG_IMAGEFILE_H
10 
11 #include <yarp/os/ConstString.h>
12 #include <yarp/sig/Image.h>
13 
14 namespace yarp {
15  namespace sig{
21  namespace file {
22  enum
23  {
29  };
30 
31  // PPM/PGM format
32  bool YARP_sig_API read(ImageOf<PixelRgb>& dest,
33  const yarp::os::ConstString& src);
34  bool YARP_sig_API read(ImageOf<PixelBgr>& dest,
35  const yarp::os::ConstString& src);
36  bool YARP_sig_API read(ImageOf<PixelRgba>& dest,
37  const yarp::os::ConstString& src);
38  bool YARP_sig_API read(ImageOf<PixelMono>& dest,
39  const yarp::os::ConstString& src);
40 
41  // plain text format
42  bool YARP_sig_API read(ImageOf<PixelFloat>& dest,
43  const yarp::os::ConstString& src);
44 
45  // PPM/PGM format
46  bool YARP_sig_API write(const ImageOf<PixelRgb>& src,
48  bool YARP_sig_API write(const ImageOf<PixelBgr>& src,
50  bool YARP_sig_API write(const ImageOf<PixelRgba>& src,
52  bool YARP_sig_API write(const ImageOf<PixelMono>& src,
54 
55  // plain text format
56  bool YARP_sig_API write(const ImageOf<PixelFloat>& src,
58 
59  bool YARP_sig_API write(const Image& src,
61  }
62  }
63 }
64 
65 #endif // YARP_SIG_IMAGEFILE_H
virtual YARP_SSIZE_T read(const Bytes &b)
* dest
Definition: ImageCopy.cpp:72
The main, catch-all namespace for YARP.
A string with almost the same api as std::string.
Definition: ConstString.h:44
Base class for storing images.
Definition: Image.h:48
virtual void write(const Bytes &b)