SourceXtractorPlusPlus 0.19
SourceXtractor++, the next generation SExtractor
Loading...
Searching...
No Matches
ImageSource.h
Go to the documentation of this file.
1
18/*
19 * ImageSource.h
20 *
21 * Created on: Feb 14, 2018
22 * Author: mschefer
23 */
24
25#ifndef _SEFRAMEWORK_IMAGE_IMAGESOURCE_H_
26#define _SEFRAMEWORK_IMAGE_IMAGESOURCE_H_
27
28#include <boost/variant.hpp>
29
32
33namespace SourceXtractor {
34
41 typedef boost::variant<bool, char, int64_t, double, std::string> value_t;
42
44
47};
48
54public:
55
57
58 virtual ~ImageSource() = default;
59
61 virtual std::string getRepr() const = 0;
62
63 virtual void saveTile(ImageTile& tile) = 0;
64 virtual std::shared_ptr<ImageTile> getImageTile(int x, int y, int width, int height) const = 0;
65
66
68 virtual int getWidth() const = 0;
69
71 virtual int getHeight() const = 0;
72
73 virtual ImageTile::ImageType getType() const = 0;
74
79
80 virtual void setMetadata(const std::string& key, const MetadataEntry& value) {
81 m_metadata[key] = value;
82 }
83
84private:
86};
87
88} // namespace SourceXtractor
89
90#endif /* _SEFRAMEWORK_IMAGE_IMAGESOURCE_H_ */
std::shared_ptr< DependentParameter< std::shared_ptr< EngineParameter > > > x
std::shared_ptr< DependentParameter< std::shared_ptr< EngineParameter > > > y
virtual std::shared_ptr< ImageTile > getImageTile(int x, int y, int width, int height) const =0
virtual ImageTile::ImageType getType() const =0
virtual void saveTile(ImageTile &tile)=0
std::map< std::string, MetadataEntry > m_metadata
Definition: ImageSource.h:85
virtual int getHeight() const =0
Returns the height of the image in pixels.
virtual const std::map< std::string, MetadataEntry > & getMetadata() const
Definition: ImageSource.h:78
virtual void setMetadata(const std::string &key, const MetadataEntry &value)
Definition: ImageSource.h:80
virtual int getWidth() const =0
Returns the width of the image in pixels.
virtual std::string getRepr() const =0
Human readable representation of this source.
virtual ~ImageSource()=default
std::map< std::string, std::string > m_extra
Additional metadata about the entry: i.e. comments.
Definition: ImageSource.h:46
boost::variant< bool, char, int64_t, double, std::string > value_t
Definition: ImageSource.h:41