00001 # ifndef ImageArgs_h
00002 # define ImageArgs_h ImageArgs_h
00003
00004 # include "Root.h"
00005 # include "Coord.h"
00006
00007 namespace Conjecture {
00008 class Image;
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033 class ImageArgs : public Root {
00034
00035 public:
00041 ImageArgs(uint8_t magnification = 1, uint16_t threshold = 0, uint16_t quantize = 0, uint8_t filter = 0, uint8_t dustsize = 0);
00042
00043 uint8_t magnification() const { return this->_magnification; }
00044 uint16_t threshold() const { return this->_threshold; }
00045 uint16_t quantize() const { return this->_quantize; }
00046 uint8_t filter() const { return this->_filter; }
00047 uint8_t dustsize() const { return this->_dustsize; }
00048
00049 uint8_t& magnification() { return this->_magnification; }
00050 uint16_t& threshold() { return this->_threshold; }
00051 uint16_t& quantize() { return this->_quantize; }
00052 uint8_t& filter() { return this->_filter; }
00053 uint8_t& dustsize() { return this->_dustsize; }
00054
00064 uint16_t apply(const Image* image, const Coord& pos) const;
00065
00074 static const uint16_t MaxVal;
00075 static const uint16_t MinVal;
00076
00077 private:
00087 uint8_t _magnification;
00088
00095 uint16_t _threshold;
00096
00105 uint16_t _quantize;
00106
00115 uint8_t _filter;
00116
00122 uint8_t _dustsize;
00123
00128 std::string str() const;
00129 };
00130 };
00131
00132 # endif // ImageArgs_h
00133