From 3187fc84a6033af4abea4a0e7e488d8a9d493090 Mon Sep 17 00:00:00 2001 From: johan Date: Sat, 31 Aug 2013 14:36:54 +0200 Subject: [PATCH 01/12] Doxygen comments added --- include/jsonserver/JsonServer.h | 23 ++++++++++ include/utils/ColorTransform.h | 26 ++++++++++- include/utils/HsvTransform.h | 21 +++++++++ include/utils/jsonschema/JsonSchemaChecker.h | 45 +++++++++++++------ include/xbmcvideochecker/XBMCVideoChecker.h | 13 +++++- libsrc/jsonserver/JsonClientConnection.h | 47 ++++++++++++++++++++ src/hyperion-remote/CustomParameter.h | 9 ++-- src/hyperion-remote/JsonConnection.h | 39 ++++++++++++---- 8 files changed, 195 insertions(+), 28 deletions(-) diff --git a/include/jsonserver/JsonServer.h b/include/jsonserver/JsonServer.h index c14a6176..b072b6e3 100644 --- a/include/jsonserver/JsonServer.h +++ b/include/jsonserver/JsonServer.h @@ -12,25 +12,48 @@ class JsonClientConnection; +/// +/// This class creates a TCP server which accepts connections wich can then send +/// in JSON encoded commands. This interface to Hyperion is used by hyperion-remote +/// to control the leds +/// class JsonServer : public QObject { Q_OBJECT public: + /// + /// \brief JsonServer constructor + /// \param hyperion Hyperion instance + /// \param port port number on which to start listening for connections + /// JsonServer(Hyperion * hyperion, uint16_t port = 19444); ~JsonServer(); + /// + /// \return the port number on which this TCP listens for incoming connections + /// uint16_t getPort() const; private slots: + /// + /// \brief Slot which is called when a client tries to create a new connection + /// void newConnection(); + /// + /// \brief Slot which is called when a client closes a connection + /// \param The Connection object which is being closed + /// void closedConnection(JsonClientConnection * connection); private: + /// Hyperion instance Hyperion * _hyperion; + /// The TCP server object QTcpServer _server; + /// List with open connections QSet _openConnections; }; diff --git a/include/utils/ColorTransform.h b/include/utils/ColorTransform.h index 79b75fa9..0373ceda 100644 --- a/include/utils/ColorTransform.h +++ b/include/utils/ColorTransform.h @@ -15,29 +15,53 @@ class ColorTransform { public: + /// @brief Default constructor ColorTransform(); + + /// @brief Constructor + /// @param threshold + /// @param gamma + /// @param blacklevel + /// @param whitelevel ColorTransform(double threshold, double gamma, double blacklevel, double whitelevel); + + /// @brief Destructor ~ColorTransform(); + /// @return The current threshold value double getThreshold() const; + + /// @param threshold New threshold value void setThreshold(double threshold); + /// @return The current gamma value double getGamma() const; + + /// @param gamma New gamma value void setGamma(double gamma); + /// @return The current blacklevel value double getBlacklevel() const; + + /// @param blacklevel New blacklevel value void setBlacklevel(double blacklevel); + /// @return The current whitelevel value double getWhitelevel() const; + + /// @param whitelevel New whitelevel value void setWhitelevel(double whitelevel); - /// get the transformed value for the given byte value + /// @brief Transform the given byte value + /// @param input The input color byte + /// @return The transformed byte value uint8_t transform(uint8_t input) const { return _mapping[input]; } private: + /// @brief (re)-initilize the color mapping void initializeMapping(); private: diff --git a/include/utils/HsvTransform.h b/include/utils/HsvTransform.h index 14be2f21..05e0b2cc 100644 --- a/include/utils/HsvTransform.h +++ b/include/utils/HsvTransform.h @@ -3,19 +3,40 @@ // STL includes #include +/// +/// \brief Color transformation to adjust the saturation and value of a RGB color value +/// class HsvTransform { public: + /// Default constructor HsvTransform(); + + /// @brief Constructor + /// @param saturationGain + /// @param valueGain HsvTransform(double saturationGain, double valueGain); + + /// Destructor ~HsvTransform(); + /// @param saturationGain New saturationGain void setSaturationGain(double saturationGain); + + /// @return The current Saturation gain double getSaturationGain() const; + /// @param valueGain New Value gain void setValueGain(double valueGain); + + /// @return The current value gain double getValueGain() const; + /// @brief Apply the transform the the given RGB values. + /// @param red The red color component + /// @param green The green color component + /// @param blue The blue color component + /// @note The values are updated in place. void transform(uint8_t & red, uint8_t & green, uint8_t & blue) const; /// integer version of the conversion are faster, but a little less accurate diff --git a/include/utils/jsonschema/JsonSchemaChecker.h b/include/utils/jsonschema/JsonSchemaChecker.h index 18a33fe7..4f02bcf5 100644 --- a/include/utils/jsonschema/JsonSchemaChecker.h +++ b/include/utils/jsonschema/JsonSchemaChecker.h @@ -7,30 +7,47 @@ // jsoncpp includes #include -/** - * JsonSchemaChecker is a very basic implementation of json schema. - * The json schema definition draft can be found at - * http://tools.ietf.org/html/draft-zyp-json-schema-03 - * - * The following keywords are supported: - * - type - * - required - * - properties - * - items - * - enum - * - minimum - * - maximum - */ + +/// JsonSchemaChecker is a very basic implementation of json schema. +/// The json schema definition draft can be found at +/// http://tools.ietf.org/html/draft-zyp-json-schema-03 +/// +/// The following keywords are supported: +/// - type +/// - required +/// - properties +/// - items +/// - enum +/// - minimum +/// - maximum +/// - addtionalProperties +/// - minItems +/// - maxItems +/// +/// And the non-standard: +/// - dependencies class JsonSchemaChecker { public: JsonSchemaChecker(); virtual ~JsonSchemaChecker(); + /// + /// @param The schema to use + /// @return true upon succes + /// bool setSchema(const Json::Value & schema); + /// + /// @brief Validate a JSON structure + /// @param The JSON value to check + /// @return true when the arguments is valid according to the schema + /// bool validate(const Json::Value & value); + /// + /// @return A list of error messages + /// const std::list & getMessages() const; private: diff --git a/include/xbmcvideochecker/XBMCVideoChecker.h b/include/xbmcvideochecker/XBMCVideoChecker.h index 5541d399..106baf07 100644 --- a/include/xbmcvideochecker/XBMCVideoChecker.h +++ b/include/xbmcvideochecker/XBMCVideoChecker.h @@ -14,8 +14,8 @@ // Hyperion includes #include -/// Check if XBMC is playing something. When it does not, this class will send all black data Hyperion to -/// override (grabbed) data with a lower priority +/// This class will check if XBMC is playing something. When it does not, this class will send all black data to Hyperion. +/// This allows grabbed screen data to be overriden while in the XBMC menus. /// /// Note: The json TCP server needs to be enabled manually in XBMC in System/Settings/Network/Services class XBMCVideoChecker : public QObject @@ -23,13 +23,22 @@ class XBMCVideoChecker : public QObject Q_OBJECT public: + /// @Constructor + /// @param address Netwrok address of the XBMC instance + /// @param port Port number to use (XBMC default = 9090) + /// @param interval The interval at which XBMC is polled + /// @param hyperion The Hyperion instance + /// @param priority The priority at which to send the all black data XBMCVideoChecker(const std::string & address, uint16_t port, uint64_t interval, Hyperion * hyperion, int priority); + /// \brief Start polling XBMC void start(); private slots: + /// \brief Send a request to XBMC void sendRequest(); + /// @brief receive a reply from XBMC void receiveReply(); private: diff --git a/libsrc/jsonserver/JsonClientConnection.h b/libsrc/jsonserver/JsonClientConnection.h index 25807cc2..6bae1918 100644 --- a/libsrc/jsonserver/JsonClientConnection.h +++ b/libsrc/jsonserver/JsonClientConnection.h @@ -18,36 +18,83 @@ class ImageProcessor; +/// @brief The Connection object created by \a JsonServer when a new connection is establshed +/// class JsonClientConnection : public QObject { Q_OBJECT public: + /// @brief Constructor + /// @param socket The Socket object for this connection + /// @param hyperion The Hyperion server JsonClientConnection(QTcpSocket * socket, Hyperion * hyperion); + + /// @brief Destructor ~JsonClientConnection(); signals: + /// @brief Signal which is emitted when the connection is being closed + /// @param connection This connection object void connectionClosed(JsonClientConnection * connection); private slots: + /// @brief Slot called when new data has arrived void readData(); + + /// @brief Slot called when this connection is being closed void socketClosed(); private: + /// @brief Handle an incoming JSON message + /// @param message the incoming message as string void handleMessage(const std::string & message); + + /// @brief Handle an incoming JSON Color message + /// @param message the incoming message void handleColorCommand(const Json::Value & message); + + /// @brief Handle an incoming JSON Image message + /// @param message the incoming message void handleImageCommand(const Json::Value & message); + + /// @brief Handle an incoming JSON Server info message + /// @param message the incoming message void handleServerInfoCommand(const Json::Value & message); + + /// @brief Handle an incoming JSON Clear message + /// @param message the incoming message void handleClearCommand(const Json::Value & message); + + /// @brief Handle an incoming JSON Clearall message + /// @param message the incoming message void handleClearallCommand(const Json::Value & message); + + /// @brief Handle an incoming JSON Transform message + /// @param message the incoming message void handleTransformCommand(const Json::Value & message); + + /// @brief Handle an incoming JSON message of unknown type + /// @param message the incoming message void handleNotImplemented(); + /// @brief Send a message to the connected client + /// @param message The JSON message to send void sendMessage(const Json::Value & message); + + /// @brief Send a standard reply indicating success void sendSuccessReply(); + + /// @brief Send an error message back to the client + /// @param error String describing the error void sendErrorReply(const std::string & error); private: + /// @brief Check if a JSON messag is valid according to a given JSON schema + /// @param message JSON message which need to be checked + /// @param schemaResource Qt esource identifier with the JSON schema + /// @param errors Output error message + /// @return true if message conforms the given JSON schema bool checkJson(const Json::Value & message, const QString &schemaResource, std::string & errors); private: diff --git a/src/hyperion-remote/CustomParameter.h b/src/hyperion-remote/CustomParameter.h index 1292e3a8..a9a65242 100644 --- a/src/hyperion-remote/CustomParameter.h +++ b/src/hyperion-remote/CustomParameter.h @@ -10,11 +10,14 @@ // hyperion-remote includes #include "ColorTransformValues.h" - +/// Data parameter for a color typedef vlofgren::PODParameter ColorParameter; -typedef vlofgren::PODParameter ImageParameter; -typedef vlofgren::PODParameter TransformParameter; +/// Data parameter for an image +typedef vlofgren::PODParameter ImageParameter; + +/// Data parameter for color transform values (list of three values) +typedef vlofgren::PODParameter TransformParameter; namespace vlofgren { template<> diff --git a/src/hyperion-remote/JsonConnection.h b/src/hyperion-remote/JsonConnection.h index 025d7e4a..8a2c7a18 100644 --- a/src/hyperion-remote/JsonConnection.h +++ b/src/hyperion-remote/JsonConnection.h @@ -19,26 +19,44 @@ class JsonConnection { public: + /// @brief COnstructor + /// @param address The address of the Hyperion server (for example "192.168.0.32:19444) + /// @param printJson Boolean indicating if the sent and received json is written to stdout JsonConnection(const std::string & address, bool printJson); + + /// @brief Destructor ~JsonConnection(); - /// Set all leds to the specified color + /// @brief Set all leds to the specified color + /// @param color The color + /// @param priority The priority + /// @param duration The duration in milliseconds void setColor(QColor color, int priority, int duration); - /// Set the leds according to the given image (assume the image is stretched to the display size) + /// @brief Set the leds according to the given image (assume the image is stretched to the display size) + /// @param image The image + /// @param priority The priority + /// @param duration The duration in milliseconds void setImage(QImage image, int priority, int duration); - /// Retrieve a list of all occupied priority channels + /// @brief Retrieve a list of all occupied priority channels + /// @return String with the server info QString getServerInfo(); - /// Clear the given priority channel + /// @brief Clear the given priority channel + /// @param priority The priority void clear(int priority); - /// Clear all priority channels + /// @brief Clear all priority channels void clearAll(); - /// Set the color transform of the leds - /// Note that providing a NULL will leave the settings on the server unchanged + /// @brief Set the color transform of the leds + /// @note Note that providing a NULL will leave the settings on the server unchanged + /// @param saturation The HSV saturation gain + /// @param value The HSV value gain + /// @param threshold The threshold + /// @param blacklevel The blacklevel + /// @param whitelevel The whitelevel void setTransform( double * saturation, double * value, @@ -48,9 +66,14 @@ public: ColorTransformValues * whitelevel); private: - /// Send a json command message and receive its reply + /// @brief Send a json command message and receive its reply + /// @param message The message to send + /// @return The returned reply Json::Value sendMessage(const Json::Value & message); + /// @brief Parse a reply message + /// @param reply The received reply + /// @return true if the reply indicates success bool parseReply(const Json::Value & reply); private: From d2d7265f026424ab23766ec199d7d113e89fd5cc Mon Sep 17 00:00:00 2001 From: "T. van der Zwan" Date: Fri, 6 Sep 2013 19:26:58 +0000 Subject: [PATCH 02/12] Added doxygen comments --- include/dispmanx-grabber/DispmanxWrapper.h | 33 ++++++- include/hyperion/Hyperion.h | 100 ++++++++++++++++++++- include/hyperion/ImageProcessor.h | 68 ++++++++------ include/hyperion/ImageProcessorFactory.h | 20 +++++ include/hyperion/LedDevice.h | 3 + include/hyperion/LedString.h | 62 ++++++++----- include/hyperion/PriorityMuxer.h | 69 ++++++++++++++ libsrc/hyperion/LedString.cpp | 1 + 8 files changed, 301 insertions(+), 55 deletions(-) diff --git a/include/dispmanx-grabber/DispmanxWrapper.h b/include/dispmanx-grabber/DispmanxWrapper.h index 134c30cd..2d22b677 100644 --- a/include/dispmanx-grabber/DispmanxWrapper.h +++ b/include/dispmanx-grabber/DispmanxWrapper.h @@ -22,33 +22,58 @@ class DispmanxWrapper: public QObject { Q_OBJECT public: + /// + /// Constructs the dispmanx frame grabber with a specified grab size and update rate. + /// + /// @param[in] grabWidth The width of the grabbed image [pixels] + /// @param[in] grabHeight The height of the grabbed images [pixels] + /// @param[in] updateRate_Hz The image grab rate [Hz] + /// @param[in] hyperion The instance of Hyperion used to write the led values + /// DispmanxWrapper(const unsigned grabWidth, const unsigned grabHeight, const unsigned updateRate_Hz, Hyperion * hyperion); + /// + /// Destructor of this dispmanx frame grabber. Releases any claimed resources. + /// virtual ~DispmanxWrapper(); -signals: - void ledValues(const unsigned priority, const std::vector ledColors, const unsigned timeout_ms); - public slots: + /// + /// Starts the grabber wich produces led values with the specified update rate + /// void start(); + /// + /// Performs a single frame grab and computes the led-colors + /// void action(); + /// + /// Stops the grabber + /// void stop(); private: + /// The update rate [Hz] const int _updateInterval_ms; + /// The timeout of the led colors [ms] const int _timeout_ms; + /// The priority of the led colors [ms] const int _priority; + /// The timer for generating events with the specified update rate QTimer _timer; + /// The image used for grabbing frames RgbImage _image; + /// The actual grabber DispmanxFrameGrabber * _frameGrabber; + /// The processor for transforming images to led colors ImageProcessor * _processor; + /// The list with computed led colors std::vector _ledColors; + /// Pointer to Hyperion for writing led values Hyperion * _hyperion; }; - diff --git a/include/hyperion/Hyperion.h b/include/hyperion/Hyperion.h index ce4cd546..e25f1aae 100644 --- a/include/hyperion/Hyperion.h +++ b/include/hyperion/Hyperion.h @@ -19,65 +19,161 @@ class HsvTransform; class ColorTransform; +/// +/// The main class of Hyperion. This gives other 'users' access to the attached LedDevice through +/// the priority muxer. +/// class Hyperion : public QObject { Q_OBJECT public: + /// Type definition of the info structure used by the priority muxer typedef PriorityMuxer::InputInfo InputInfo; + /// + /// RGB-Color channel enumeration + /// enum Color { RED, GREEN, BLUE, INVALID }; + /// + /// Enumeration of the possible color (color-channel) transforms + /// enum Transform { SATURATION_GAIN, VALUE_GAIN, THRESHOLD, GAMMA, BLACKLEVEL, WHITELEVEL }; + /// + /// Constructs the Hyperion instance based on the given Json configuration + /// + /// @param[in] jsonConfig The Json configuration + /// Hyperion(const Json::Value& jsonConfig); + /// + /// Destructor; cleans up resourcess + /// ~Hyperion(); + /// + /// Returns the number of attached leds + /// unsigned getLedCount() const; + /// + /// Writes a single color to all the leds for the given time and priority + /// + /// @param[in] priority The priority of the written color + /// @param[in] ledColor The color to write to the leds + /// @param[in] timeout_ms The time the leds are set to the given color [ms] + /// void setColor(int priority, RgbColor &ledColor, const int timeout_ms); + /// + /// Writes the given colors to all leds for the given time and priority + /// + /// @param[in] priority The priority of the written colors + /// @param[in] ledColors The colors to write to the leds + /// @param[in] timeout_ms The time the leds are set to the given colors [ms] + /// void setColors(int priority, std::vector &ledColors, const int timeout_ms); + /// + /// Sets/Updates a part of the color transformation. + /// + /// @param[in] transform The type of transform to configure + /// @param[in] color The color channel to which the transform applies (only applicable for + /// Transform::THRESHOLD, Transform::GAMMA, Transform::BLACKLEVEL, + /// Transform::WHITELEVEL) + /// @param[in] value The new value for the given transform + /// void setTransform(Transform transform, Color color, double value); + /// + /// Clears the given priority channel. This will switch the led-colors to the colors of the next + /// lower priority channel (or off if no more channels are set) + /// + /// @param[in] priority The priority channel + /// void clear(int priority); + /// + /// Clears all priority channels. This will switch the leds off until a new priority is written. + /// void clearall(); + /// + /// Returns the value of a specific color transform + /// + /// @param[in] transform The type of transform + /// @param[in] color The color channel to which the transform applies (only applicable for + /// Transform::THRESHOLD, Transform::GAMMA, Transform::BLACKLEVEL, + /// Transform::WHITELEVEL) + /// + /// @return The value of the specified color transform + /// double getTransform(Transform transform, Color color) const; + /// + /// Returns a list of active priorities + /// + /// @return The list with priorities + /// QList getActivePriorities() const; + /// + /// Returns the information of a specific priorrity channel + /// + /// @param[in] priority The priority channel + /// + /// @return The information of the given + /// + /// @throw std::runtime_error when the priority channel does not exist + /// const InputInfo& getPriorityInfo(const int priority) const; - static LedDevice* constructDevice(const Json::Value & deviceConfig); + static LedDevice * constructDevice(const Json::Value & deviceConfig); static LedString createLedString(const Json::Value & ledsConfig); static HsvTransform * createHsvTransform(const Json::Value & hsvConfig); - static ColorTransform* createColorTransform(const Json::Value & colorConfig); + static ColorTransform * createColorTransform(const Json::Value & colorConfig); private slots: + /// + /// Updates the priority muxer with the current time and (re)writes the led color with applied + /// transforms. + /// void update(); private: + /// + /// Applies all color transmforms to the given list of colors. The transformation is performed + /// in place. + /// + /// @param colors The colors to be transformed + /// void applyTransform(std::vector& colors) const; + /// The specifiation of the led frame construction and picture integration LedString _ledString; + /// The priority muxer PriorityMuxer _muxer; + /// The HSV Transform for applying Saturation and Value transforms HsvTransform * _hsvTransform; + /// The RED-Channel (RGB) transform ColorTransform * _redTransform; + /// The GREEN-Channel (RGB) transform ColorTransform * _greenTransform; + /// The BLUE-Channel (RGB) transform ColorTransform * _blueTransform; + /// The actual LedDevice LedDevice* _device; + /// The timer for handling priority channel timeouts QTimer _timer; }; diff --git a/include/hyperion/ImageProcessor.h b/include/hyperion/ImageProcessor.h index 18747afe..642d0297 100644 --- a/include/hyperion/ImageProcessor.h +++ b/include/hyperion/ImageProcessor.h @@ -14,57 +14,71 @@ namespace hyperion { class BlackBorderProcessor; } -/** - * The ImageProcessor translates an RGB-image to RGB-values for the leds. The processing is - * performed in two steps. First the average color per led-region is computed. Second a - * color-tranform is applied based on a gamma-correction. - */ +/// +/// The ImageProcessor translates an RGB-image to RGB-values for the leds. The processing is +/// performed in two steps. First the average color per led-region is computed. Second a +/// color-tranform is applied based on a gamma-correction. +/// class ImageProcessor { public: ~ImageProcessor(); - /** - * Specifies the width and height of 'incomming' images. This will resize the buffer-image to - * match the given size. - * NB All earlier obtained references will be invalid. - * - * @param[in] width The new width of the buffer-image - * @param[in] height The new height of the buffer-image - */ + /// + /// Specifies the width and height of 'incomming' images. This will resize the buffer-image to + /// match the given size. + /// NB All earlier obtained references will be invalid. + /// + /// @param[in] width The new width of the buffer-image + /// @param[in] height The new height of the buffer-image + /// void setSize(const unsigned width, const unsigned height); - /** - * Processes the image to a list of led colors. This will update the size of the buffer-image - * if required and call the image-to-leds mapping to determine the mean color per led. - * - * @param[in] image The image to translate to led values - * - * @return The color value per led - */ + /// + /// Processes the image to a list of led colors. This will update the size of the buffer-image + /// if required and call the image-to-leds mapping to determine the mean color per led. + /// + /// @param[in] image The image to translate to led values + /// + /// @return The color value per led + /// std::vector process(const RgbImage& image); - /** - * Determines the led colors of the image in the buffer. - * - * @param[out] ledColors The color value per led - */ + /// + /// Determines the led colors of the image in the buffer. + /// + /// @param[out] ledColors The color value per led + /// void process(const RgbImage& image, std::vector& ledColors); private: + /// Friend declaration of the factory for creating ImageProcessor's friend class ImageProcessorFactory; + /// + /// Constructs an image-processor for translating an image to led-color values based on the + /// given led-string specification + /// + /// @param[in] ledString The led-string specification + /// ImageProcessor(const LedString &ledString); + /// + /// Performs black-border detection (if enabled) on the given image + /// + /// @param[in] image The image to perform black-border detection on + /// void verifyBorder(const RgbImage& image); private: + /// The Led-string specification const LedString mLedString; + /// Flag the enables(true)/disabled(false) blackborder detector bool _enableBlackBorderRemoval; /// The processor for black border detection hyperion::BlackBorderProcessor* _borderProcessor; + /// The mapping of image-pixels to leds hyperion::ImageToLedsMap* mImageToLeds; }; - diff --git a/include/hyperion/ImageProcessorFactory.h b/include/hyperion/ImageProcessorFactory.h index dc558371..3431065b 100644 --- a/include/hyperion/ImageProcessorFactory.h +++ b/include/hyperion/ImageProcessorFactory.h @@ -11,16 +11,36 @@ // Forward class declaration class ImageProcessor; +/// +/// The ImageProcessor is a singleton factor for creating ImageProcessors that translate images to +/// led color values. +/// class ImageProcessorFactory { public: + /// + /// Returns the 'singleton' instance (creates the singleton if it does not exist) + /// + /// @return The singleton instance of the ImageProcessorFactory + /// static ImageProcessorFactory& getInstance(); public: + /// + /// Initialises this factory with the given led-configuration + /// + /// @param[in] ledString The led configuration + /// void init(const LedString& ledString); + /// + /// Creates a new ImageProcessor. The onwership of the processor is transferred to the caller. + /// + /// @return The newly created ImageProcessor + /// ImageProcessor* newImageProcessor() const; private: + /// The Led-string specification LedString _ledString; }; diff --git a/include/hyperion/LedDevice.h b/include/hyperion/LedDevice.h index ea84fa7f..7c1dc6a6 100644 --- a/include/hyperion/LedDevice.h +++ b/include/hyperion/LedDevice.h @@ -6,6 +6,9 @@ // Utility includes #include +/// +/// Interface (pure virtual base class) for LedDevices. +/// class LedDevice { public: diff --git a/include/hyperion/LedString.h b/include/hyperion/LedString.h index 030dd11f..e5963440 100644 --- a/include/hyperion/LedString.h +++ b/include/hyperion/LedString.h @@ -12,49 +12,67 @@ // Forward class declarations namespace Json { class Value; } -/** - * The Led structure contains the definition of the image portion used to determine a single led's - * color. - *
- * |--------------------image--|
- * | minX  maxX                |
- * |  |-----|minY              |
- * |  |     |                  |
- * |  |-----|maxY              |
- * |                           |
- * |                           |
- * |                           |
- * |---------------------------|
- * 
- */
+///
+/// The Led structure contains the definition of the image portion used to determine a single led's
+/// color.
+/// 
+/// |--------------------image--|
+/// | minX  maxX                |
+/// |  |-----|minY              |
+/// |  |     |                  |
+/// |  |-----|maxY              |
+/// |                           |
+/// |                           |
+/// |                           |
+/// |---------------------------|
+/// 
+///
 struct Led
 {
-	/** The index of the led */
+	///  The index of the led
 	unsigned index;
 
-	/** The minimum vertical scan line included for this leds color */
+	///  The minimum vertical scan line included for this leds color
 	double minX_frac;
-	/** The maximum vertical scan line included for this leds color */
+	///  The maximum vertical scan line included for this leds color
 	double maxX_frac;
-	/** The minimum horizontal scan line included for this leds color */
+	///  The minimum horizontal scan line included for this leds color
 	double minY_frac;
-	/** The maximum horizontal scan line included for this leds color */
+	///  The maximum horizontal scan line included for this leds color
 	double maxY_frac;
 };
 
+///
+/// The LedString contains the image integration information of the leds
+///
 class LedString
 {
 public:
-	static LedString construct(const Json::Value& ledConfig);
-
+	///
+	/// Constructs the LedString with no leds
+	///
 	LedString();
 
+	///
+	/// Destructor of this LedString
+	///
 	~LedString();
 
+	///
+	/// Returns the led specifications
+	///
+	/// @return The list with led specifications
+	///
 	std::vector& leds();
 
+	///
+	/// Returns the led specifications
+	///
+	/// @return The list with led specifications
+	///
 	const std::vector& leds() const;
 
 private:
+	/// The list with led specifications
 	std::vector mLeds;
 };
diff --git a/include/hyperion/PriorityMuxer.h b/include/hyperion/PriorityMuxer.h
index 73ca7694..2536150a 100644
--- a/include/hyperion/PriorityMuxer.h
+++ b/include/hyperion/PriorityMuxer.h
@@ -15,43 +15,112 @@
 // Hyperion includes
 #include 
 
+///
+/// The PriorityMuxer handles the priority channels. Led values input is written to the priority map
+/// and the muxer keeps track of all active priorities. The current priority can be queried and per
+/// priority the led colors.
+///
 class PriorityMuxer
 {
 public:
+	///
+	/// The information structure for a single priority channel
+	///
 	struct InputInfo
 	{
+		/// The priority of this channel
 		int priority;
 
+		/// The absolute timeout of the channel
 		int64_t timeoutTime_ms;
+		/// The colors for each led of the channel
 		std::vector ledColors;
 	};
 
+	///
+	/// Constructs the PriorityMuxer for the given number of leds (used to switch to black when
+	/// there are no priority channels
+	///
+	/// @param ledCount The number of leds
+	///
 	PriorityMuxer(int ledCount);
 
+	///
+	/// Destructor
+	///
 	~PriorityMuxer();
 
+	///
+	/// Returns the current priority
+	///
+	/// @return The current priority
+	///
 	int getCurrentPriority() const;
 
+	///
+	/// Returns the state (enabled/disabled) of a specific priority channel
+	/// @param priority The priority channel
+	/// @return True if the priority channel exists else false
+	///
 	bool hasPriority(const int priority) const;
 
+	///
+	/// Returns the number of active priorities
+	///
+	/// @return The list with active priorities
+	///
 	QList getPriorities() const;
 
+	///
+	/// Returns the information of a specified priority channel
+	///
+	/// @param priority The priority channel
+	///
+	/// @return The information for the specified priority channel
+	///
+	/// @throws std::runtime_error if the priority channel does not exist
+	///
 	const InputInfo& getInputInfo(const int priority) const;
 
+	///
+	/// Sets/Updates the data for a priority channel
+	///
+	/// @param[in] priority The priority of the channel
+	/// @param[in] ledColors The led colors of the priority channel
+	/// @param[in] timeoutTime_ms The absolute timeout time of the channel
+	///
 	void setInput(const int priority, const std::vector& ledColors, const int64_t timeoutTime_ms=-1);
 
+	///
+	/// Clears the specified priority channel
+	///
+	/// @param[in] priority  The priority of the channel to clear
+	///
 	void clearInput(const int priority);
 
+	///
+	/// Clears all priority channels
+	///
 	void clearAll();
 
+	///
+	/// Updates the current time. Channels with a configured time out will be checked and cleared if
+	/// required.
+	///
+	/// @param[in] now The current time
+	///
 	void setCurrentTime(const int64_t& now);
 
 private:
+	/// The current priority (lowest value in _activeInputs)
 	int _currentPriority;
 
+	/// The mapping from priority channel to led-information
 	QMap _activeInputs;
 
+	/// The information of the lowest priority channel
 	InputInfo _lowestPriorityInfo;
 
+	/// The lowest possible priority, which is used when no priority channels are active
 	const static int LOWEST_PRIORITY = std::numeric_limits::max();
 };
diff --git a/libsrc/hyperion/LedString.cpp b/libsrc/hyperion/LedString.cpp
index 38c1b8f9..a44a4dc5 100644
--- a/libsrc/hyperion/LedString.cpp
+++ b/libsrc/hyperion/LedString.cpp
@@ -17,6 +17,7 @@ LedString::LedString()
 
 LedString::~LedString()
 {
+	// empty
 }
 
 std::vector& LedString::leds()

From 8441dd51cc82ed5faa633064866ac15c48118876 Mon Sep 17 00:00:00 2001
From: "T. van der Zwan" 
Date: Mon, 9 Sep 2013 02:54:13 +0000
Subject: [PATCH 03/12] Added/Updated/Fixed doxygen comments

---
 include/jsonserver/JsonServer.h             | 14 ++--
 include/utils/ColorTransform.h              | 15 ++--
 include/utils/HsvTransform.h                | 43 ++++++++--
 include/utils/RgbColor.h                    | 30 ++++++-
 include/utils/RgbImage.h                    | 86 ++++++++++++++++++--
 include/xbmcvideochecker/XBMCVideoChecker.h | 29 +++++--
 libsrc/hyperion/BlackBorderProcessor.h      | 33 ++++++++
 libsrc/hyperion/LedDeviceTest.h             | 19 +++++
 libsrc/hyperion/LedDeviceWs2801.cpp         |  4 +-
 libsrc/hyperion/LedDeviceWs2801.h           | 32 +++++++-
 libsrc/jsonserver/JsonClientConnection.h    | 87 ++++++++++++++++-----
 libsrc/utils/RgbImage.cpp                   | 12 +--
 src/hyperion-remote/JsonConnection.h        | 55 ++++++++++---
 13 files changed, 385 insertions(+), 74 deletions(-)

diff --git a/include/jsonserver/JsonServer.h b/include/jsonserver/JsonServer.h
index b072b6e3..67609fe3 100644
--- a/include/jsonserver/JsonServer.h
+++ b/include/jsonserver/JsonServer.h
@@ -23,27 +23,27 @@ class JsonServer : public QObject
 
 public:
 	///
-	/// \brief JsonServer constructor
-	/// \param hyperion Hyperion instance
-	/// \param port port number on which to start listening for connections
+	/// JsonServer constructor
+	/// @param hyperion Hyperion instance
+	/// @param port port number on which to start listening for connections
 	///
 	JsonServer(Hyperion * hyperion, uint16_t port = 19444);
 	~JsonServer();
 
 	///
-	/// \return the port number on which this TCP listens for incoming connections
+	/// @return the port number on which this TCP listens for incoming connections
 	///
 	uint16_t getPort() const;
 
 private slots:
 	///
-	/// \brief Slot which is called when a client tries to create a new connection
+	/// Slot which is called when a client tries to create a new connection
 	///
 	void newConnection();
 
 	///
-	/// \brief Slot which is called when a client closes a connection
-	/// \param The Connection object which is being closed
+	/// Slot which is called when a client closes a connection
+	/// @param The Connection object which is being closed
 	///
 	void closedConnection(JsonClientConnection * connection);
 
diff --git a/include/utils/ColorTransform.h b/include/utils/ColorTransform.h
index 0373ceda..c89b3916 100644
--- a/include/utils/ColorTransform.h
+++ b/include/utils/ColorTransform.h
@@ -15,17 +15,17 @@
 class ColorTransform
 {
 public:
-	/// @brief Default constructor
+	/// Default constructor
 	ColorTransform();
 
-	/// @brief Constructor
+	/// Constructor
 	/// @param threshold
 	/// @param gamma
 	/// @param blacklevel
 	/// @param whitelevel
 	ColorTransform(double threshold, double gamma, double blacklevel, double whitelevel);
 
-	/// @brief Destructor
+	/// Destructor
 	~ColorTransform();
 
 	/// @return The current threshold value
@@ -52,7 +52,7 @@ public:
 	/// @param whitelevel New whitelevel value
 	void setWhitelevel(double whitelevel);
 
-	/// @brief Transform the given byte value
+	/// Transform the given byte value
 	/// @param input The input color byte
 	/// @return The transformed byte value
 	uint8_t transform(uint8_t input) const
@@ -61,14 +61,19 @@ public:
 	}
 
 private:
-	/// @brief (re)-initilize the color mapping
+	/// (re)-initilize the color mapping
 	void initializeMapping();
 
 private:
+	/// The threshold value
 	double _threshold;
+	/// The gamma value
 	double _gamma;
+	/// The blacklevel
 	double _blacklevel;
+	/// The whitelevel
 	double _whitelevel;
 
+	/// The mapping from input color to output color
 	uint8_t _mapping[256];
 };
diff --git a/include/utils/HsvTransform.h b/include/utils/HsvTransform.h
index 05e0b2cc..f260b8e0 100644
--- a/include/utils/HsvTransform.h
+++ b/include/utils/HsvTransform.h
@@ -4,48 +4,79 @@
 #include 
 
 ///
-/// \brief Color transformation to adjust the saturation and value of a RGB color value
+/// Color transformation to adjust the saturation and value of a RGB color value
 ///
 class HsvTransform
 {
 public:
+	///
 	/// Default constructor
+	///
 	HsvTransform();
 
-	/// @brief Constructor
-	/// @param saturationGain
-	/// @param valueGain
+	///
+	/// Constructor
+	///
+	/// @param saturationGain The used saturation gain
+	/// @param valueGain The used value gain
+	///
 	HsvTransform(double saturationGain, double valueGain);
 
+	///
 	/// Destructor
+	///
 	~HsvTransform();
 
+	///
+	/// Updates the saturation gain
+	///
 	/// @param saturationGain New saturationGain
+	///
 	void setSaturationGain(double saturationGain);
 
+	///
+	/// Returns the saturation gain
+	///
 	/// @return The current Saturation gain
+	///
 	double getSaturationGain() const;
 
-	/// @param valueGain New Value gain
+	///
+	/// Updates the value gain
+	///
+	/// @param valueGain New value gain
+	///
 	void setValueGain(double valueGain);
 
+	///
+	/// Returns the value gain
+	///
 	/// @return The current value gain
+	///
 	double getValueGain() const;
 
-	/// @brief Apply the transform the the given RGB values.
+	///
+	/// Apply the transform the the given RGB values.
+	///
 	/// @param red The red color component
 	/// @param green The green color component
 	/// @param blue The blue color component
+	///
 	/// @note The values are updated in place.
+	///
 	void transform(uint8_t & red, uint8_t & green, uint8_t & blue) const;
 
+	///
 	/// integer version of the conversion are faster, but a little less accurate
 	/// all values are unsigned 8 bit values and scaled between 0 and 255 except
 	/// for the hue which is a 16 bit number and scaled between 0 and 360
+	///
 	static void rgb2hsv(uint8_t red, uint8_t green, uint8_t blue, uint16_t & hue, uint8_t & saturation, uint8_t & value);
 	static void hsv2rgb(uint16_t hue, uint8_t saturation, uint8_t value, uint8_t & red, uint8_t & green, uint8_t & blue);
 
 private:
+	/// The saturation gain
 	double _saturationGain;
+	/// The value gain
 	double _valueGain;
 };
diff --git a/include/utils/RgbColor.h b/include/utils/RgbColor.h
index e7c0eccb..ae42e0ce 100644
--- a/include/utils/RgbColor.h
+++ b/include/utils/RgbColor.h
@@ -8,31 +8,57 @@
 // Forward class declaration
 struct RgbColor;
 
+///
+/// Plain-Old-Data structure containing the red-green-blue color specification. Size of the
+/// structure is exactly 3-bytes for easy writing to led-device
+///
 struct RgbColor
 {
+	/// The red color channel
 	uint8_t red;
+	/// The green color channel
 	uint8_t green;
+	/// The blue color channel
 	uint8_t blue;
 
+	/// 'Black' RgbColor (0, 0, 0)
 	static RgbColor BLACK;
+	/// 'Red' RgbColor (255, 0, 0)
 	static RgbColor RED;
+	/// 'Green' RgbColor (0, 255, 0)
 	static RgbColor GREEN;
+	/// 'Blue' RgbColor (0, 0, 255)
 	static RgbColor BLUE;
+	/// 'Yellow' RgbColor (255, 255, 0)
 	static RgbColor YELLOW;
+	/// 'White' RgbColor (255, 255, 255)
 	static RgbColor WHITE;
 
+	///
+	/// Checks is this exactly matches another color
+	///
+	/// @param other The other color
+	///
+	/// @return True if the colors are identical
+	///
 	inline bool operator==(const RgbColor& other) const
 	{
 		return red == other.red && green == other.green && blue == other.blue;
 	}
 };
 
+/// Assert to ensure that the size of the structure is 'only' 3 bytes
 static_assert(sizeof(RgbColor) == 3, "Incorrect size of RgbColor");
 
-
+///
+/// Stream operator to write RgbColor to an outputstream (format "'{'[red]','[green]','[blue]'}'")
+///
+/// @param os The output stream
+/// @param color The color to write
+/// @return The output stream (with the color written to it)
+///
 inline std::ostream& operator<<(std::ostream& os, const RgbColor& color)
 {
 	os << "{" << unsigned(color.red) << "," << unsigned(color.green) << "," << unsigned(color.blue) << "}";
 	return os;
 }
-
diff --git a/include/utils/RgbImage.h b/include/utils/RgbImage.h
index 5ee8e5d2..cdc6539e 100644
--- a/include/utils/RgbImage.h
+++ b/include/utils/RgbImage.h
@@ -8,57 +8,127 @@
 // Local includes
 #include "RgbColor.h"
 
+///
+/// The RgbImage holds a 2D matrix of RgbColors's (or image). Width and height of the image are
+/// fixed at construction.
+///
 class RgbImage
 {
 public:
 
+	///
+	/// Constructor for an image with specified width and height
+	///
+	/// @param width The width of the image
+	/// @param height The height of the image
+	/// @param background The color of the image (default = BLACK)
+	///
 	RgbImage(const unsigned width, const unsigned height, const RgbColor background = RgbColor::BLACK);
 
+	///
+	/// Destructor
+	///
 	~RgbImage();
 
+	///
+	/// Returns the width of the image
+	///
+	/// @return The width of the image
+	///
 	inline unsigned width() const
 	{
-		return mWidth;
+		return _width;
 	}
 
+	///
+	/// Returns the height of the image
+	///
+	/// @return The height of the image
+	///
 	inline unsigned height() const
 	{
-		return mHeight;
+		return _height;
 	}
 
+	///
+	/// Sets the color of a specific pixel in the image
+	///
+	/// @param x The x index
+	/// @param y The y index
+	/// @param color The new color
+	///
 	void setPixel(const unsigned x, const unsigned y, const RgbColor color);
 
+	///
+	/// Returns a const reference to a specified pixel in the image
+	///
+	/// @param x The x index
+	/// @param y The y index
+	///
+	/// @return const reference to specified pixel
+	///
 	const RgbColor& operator()(const unsigned x, const unsigned y) const;
 
+	///
+	/// Returns a reference to a specified pixel in the image
+	///
+	/// @param x The x index
+	/// @param y The y index
+	///
+	/// @return reference to specified pixel
+	///
 	RgbColor& operator()(const unsigned x, const unsigned y);
 
+	///
+	/// Copies another image into this image. The images should have exactly the same size.
+	///
+	/// @param other The image to copy into this
+	///
 	inline void copy(const RgbImage& other)
 	{
-		assert(other.mWidth == mWidth);
-		assert(other.mHeight == mHeight);
+		assert(other._width == _width);
+		assert(other._height == _height);
 
-		memcpy(mColors, other.mColors, mWidth*mHeight*sizeof(RgbColor));
+		memcpy(mColors, other.mColors, _width*_height*sizeof(RgbColor));
 	}
 
+	///
+	/// Returns a memory pointer to the first pixel in the image
+	/// @return The memory pointer to the first pixel
+	///
 	RgbColor* memptr()
 	{
 		return mColors;
 	}
 
+	///
+	/// Returns a const memory pointer to the first pixel in the image
+	/// @return The const memory pointer to the first pixel
+	///
 	const RgbColor* memptr() const
 	{
 		return mColors;
 	}
 private:
 
+	///
+	/// Translate x and y coordinate to index of the underlying vector
+	///
+	/// @param x The x index
+	/// @param y The y index
+	///
+	/// @return The index into the underlying data-vector
+	///
 	inline unsigned toIndex(const unsigned x, const unsigned y) const
 	{
-		return y*mWidth + x;
+		return y*_width + x;
 	}
 
 private:
-	const unsigned mWidth;
-	const unsigned mHeight;
+	/// The width of the image
+	const unsigned _width;
+	/// The height of the image
+	const unsigned _height;
 
 	/** The colors of the image */
 	RgbColor* mColors;
diff --git a/include/xbmcvideochecker/XBMCVideoChecker.h b/include/xbmcvideochecker/XBMCVideoChecker.h
index 106baf07..54917ed2 100644
--- a/include/xbmcvideochecker/XBMCVideoChecker.h
+++ b/include/xbmcvideochecker/XBMCVideoChecker.h
@@ -14,46 +14,63 @@
 // Hyperion includes
 #include 
 
+///
 /// This class will check if XBMC is playing something. When it does not, this class will send all black data to Hyperion.
 /// This allows grabbed screen data to be overriden while in the XBMC menus.
 ///
 /// Note: The json TCP server needs to be enabled manually in XBMC in System/Settings/Network/Services
+///
 class XBMCVideoChecker : public QObject
 {
 Q_OBJECT
 
 public:
-	/// @Constructor
-	/// @param address Netwrok address of the XBMC instance
+	///
+	/// Constructor
+	///
+	/// @param address Network address of the XBMC instance
 	/// @param port Port number to use (XBMC default = 9090)
 	/// @param interval The interval at which XBMC is polled
 	/// @param hyperion The Hyperion instance
 	/// @param priority The priority at which to send the all black data
+	///
 	XBMCVideoChecker(const std::string & address, uint16_t port, uint64_t interval, Hyperion * hyperion, int priority);
 
-	/// \brief Start polling XBMC
+	///
+	/// Start polling XBMC
+	///
 	void start();
 
 private slots:
-	/// \brief Send a request to XBMC
+	///
+	/// Send a request to XBMC
+	///
 	void sendRequest();
 
-	/// @brief receive a reply from XBMC
+	///
+	/// Receive a reply from XBMC
+	///
 	void receiveReply();
 
 private:
+	/// The network address of the XBMC instance
 	const QString _address;
 
+	/// The port number of XBMC
 	const uint16_t _port;
 
+	/// The JSON-RPC request message
 	const QByteArray _request;
 
+	/// The timer that schedules XBMC queries
 	QTimer _timer;
 
+	/// The QT TCP Socket with connection to XBMC
 	QTcpSocket _socket;
 
+	/// The Hyperion instance to switch leds to black if in XBMC menu
 	Hyperion * _hyperion;
 
+	/// The priority of the BLACK led value when in XBMC menu
 	const int _priority;
 };
-
diff --git a/libsrc/hyperion/BlackBorderProcessor.h b/libsrc/hyperion/BlackBorderProcessor.h
index bd917fe5..89c59198 100644
--- a/libsrc/hyperion/BlackBorderProcessor.h
+++ b/libsrc/hyperion/BlackBorderProcessor.h
@@ -6,32 +6,65 @@
 
 namespace hyperion
 {
+	///
+	/// The BlackBorder processor is a wrapper around the black-border detector for keeping track of
+	/// detected borders and count of the type and size of detected borders.
+	///
 	class BlackBorderProcessor
 	{
 	public:
+		///
+		/// Constructor for the BlackBorderProcessor
+		/// @param unknownFrameCnt The number of frames(images) that need to contain an unknown
+		///                        border before the current border is set to unknown
+		/// @param borderFrameCnt The number of frames(images) that need to contain a vertical or
+		///                       horizontal border becomes the current border
+		/// @param blurRemoveCnt The size to add to a horizontal or vertical border (because the
+		///                      outer pixels is blurred (black and color combined))
+		///
 		BlackBorderProcessor(
 				const unsigned unknownFrameCnt,
 				const unsigned borderFrameCnt,
 				const unsigned blurRemoveCnt);
 
+		///
+		/// Return the current (detected) border
+		/// @return The current border
+		///
 		BlackBorder getCurrentBorder() const;
 
+		///
+		/// Processes the image. This performs detecion of black-border on the given image and
+		/// updates the current border accordingly. If the current border is updated the method call
+		/// will return true else false
+		///
+		/// @param image The image to process
+		///
+		/// @return True if a different border was detected than the current else false
+		///
 		bool process(const RgbImage& image);
 
 	private:
 
+		/// The number of unknown-borders detected before it becomes the current border
 		const unsigned _unknownSwitchCnt;
 
+		/// The number of horizontal/vertical borders detected before it becomes the current border
 		const unsigned _borderSwitchCnt;
 
+		/// The number of pixels to increase a detected border for removing blury pixels
 		unsigned _blurRemoveCnt;
 
+		/// The blackborder detector
 		BlackBorderDetector _detector;
 
+		/// The current detected border
 		BlackBorder _currentBorder;
 
+		/// The border detected in the previous frame
 		BlackBorder _previousDetectedBorder;
 
+		/// The number of frame the previous detected border matched the incomming border
 		unsigned _consistentCnt;
 	};
 } // end namespace hyperion
diff --git a/libsrc/hyperion/LedDeviceTest.h b/libsrc/hyperion/LedDeviceTest.h
index d9a6f1e8..473a4855 100644
--- a/libsrc/hyperion/LedDeviceTest.h
+++ b/libsrc/hyperion/LedDeviceTest.h
@@ -6,14 +6,33 @@
 // Hyperion includes
 #include 
 
+///
+/// Implementation of the LedDevice that write the led-colors to an
+/// ASCII-textfile('/home/pi/LedDevice.out')
+///
 class LedDeviceTest : public LedDevice
 {
 public:
+	///
+	/// Constructs the test-device, which opens an output stream to the file
+	///
 	LedDeviceTest();
+
+	///
+	/// Destructor of this test-device
+	///
 	virtual ~LedDeviceTest();
 
+	///
+	/// Writes the given led-color values to the output stream
+	///
+	/// @param ledValues The color-value per led
+	///
+	/// @return Zero on success else negative
+	///
 	virtual int write(const std::vector & ledValues);
 
 private:
+	/// The outputstream
 	std::ofstream _ofs;
 };
diff --git a/libsrc/hyperion/LedDeviceWs2801.cpp b/libsrc/hyperion/LedDeviceWs2801.cpp
index be4212cc..aa474242 100644
--- a/libsrc/hyperion/LedDeviceWs2801.cpp
+++ b/libsrc/hyperion/LedDeviceWs2801.cpp
@@ -11,9 +11,7 @@
 // hyperion local includes
 #include "LedDeviceWs2801.h"
 
-LedDeviceWs2801::LedDeviceWs2801(const std::string& name,
-								 const std::string& outputDevice,
-								 const unsigned interval,
+LedDeviceWs2801::LedDeviceWs2801(const std::string& outputDevice,
 								 const unsigned baudrate) :
 	mDeviceName(outputDevice),
 	mBaudRate_Hz(baudrate),
diff --git a/libsrc/hyperion/LedDeviceWs2801.h b/libsrc/hyperion/LedDeviceWs2801.h
index f5fc05ad..833666a3 100644
--- a/libsrc/hyperion/LedDeviceWs2801.h
+++ b/libsrc/hyperion/LedDeviceWs2801.h
@@ -9,25 +9,51 @@
 // hyperion incluse
 #include 
 
+///
+/// Implementation of the LedDevice interface for writing to Ws2801 led device.
+///
 class LedDeviceWs2801 : public LedDevice
 {
 public:
-	LedDeviceWs2801(const std::string& name,
-					const std::string& outputDevice,
-					const unsigned interval,
+	///
+	/// Constructs the LedDevice for a string containing leds of the type Ws2801
+	///
+	/// @param outputDevice The name of the output device (eg '/etc/SpiDev.0.0')
+	/// @param baudrate The used baudrate for writing to the output device
+	///
+	LedDeviceWs2801(const std::string& outputDevice,
 					const unsigned baudrate);
 
+	///
+	/// Destructor of the LedDevice; closes the output device if it is open
+	///
 	virtual ~LedDeviceWs2801();
 
+	///
+	/// Opens and configures the output device
+	///
+	/// @return Zero on succes else negative
+	///
 	int open();
 
+	///
+	/// Writes the led color values to the led-device
+	///
+	/// @param ledValues The color-value per led
+	/// @return Zero on succes else negative
+	///
 	virtual int write(const std::vector &ledValues);
 
 private:
+	/// The name of the output device
 	const std::string mDeviceName;
+	/// The used baudrate of the output device
 	const int mBaudRate_Hz;
 
+	/// The File Identifier of the opened output device (or -1 if not opened)
 	int mFid;
+	/// The transfer structure for writing to the spi-device
 	spi_ioc_transfer spi;
+	/// The 'latch' time for latching the shifted-value into the leds
 	timespec latchTime;
 };
diff --git a/libsrc/jsonserver/JsonClientConnection.h b/libsrc/jsonserver/JsonClientConnection.h
index 6bae1918..d2ff4366 100644
--- a/libsrc/jsonserver/JsonClientConnection.h
+++ b/libsrc/jsonserver/JsonClientConnection.h
@@ -18,91 +18,142 @@
 
 class ImageProcessor;
 
-/// @brief The Connection object created by \a JsonServer when a new connection is establshed
+///
+/// The Connection object created by \a JsonServer when a new connection is establshed
 ///
 class JsonClientConnection : public QObject
 {
 	Q_OBJECT
 
 public:
-	/// @brief Constructor
+	///
+	/// Constructor
 	/// @param socket The Socket object for this connection
 	/// @param hyperion The Hyperion server
+	///
 	JsonClientConnection(QTcpSocket * socket, Hyperion * hyperion);
 
-	/// @brief Destructor
+	///
+	/// Destructor
+	///
 	~JsonClientConnection();
 
 signals:
-	/// @brief Signal which is emitted when the connection is being closed
+	///
+	/// Signal which is emitted when the connection is being closed
 	/// @param connection This connection object
+	///
 	void connectionClosed(JsonClientConnection * connection);
 
 private slots:
-	/// @brief Slot called when new data has arrived
+	///
+	/// Slot called when new data has arrived
+	///
 	void readData();
 
-	/// @brief Slot called when this connection is being closed
+	///
+	/// Slot called when this connection is being closed
+	///
 	void socketClosed();
 
 private:
-	/// @brief Handle an incoming JSON message
+	///
+	/// Handle an incoming JSON message
+	///
 	/// @param message the incoming message as string
+	///
 	void handleMessage(const std::string & message);
 
-	/// @brief Handle an incoming JSON Color message
+	///
+	/// Handle an incoming JSON Color message
+	///
 	/// @param message the incoming message
+	///
 	void handleColorCommand(const Json::Value & message);
 
-	/// @brief Handle an incoming JSON Image message
+	///
+	/// Handle an incoming JSON Image message
+	///
 	/// @param message the incoming message
+	///
 	void handleImageCommand(const Json::Value & message);
 
-	/// @brief Handle an incoming JSON Server info message
+	///
+	/// Handle an incoming JSON Server info message
+	///
 	/// @param message the incoming message
+	///
 	void handleServerInfoCommand(const Json::Value & message);
 
-	/// @brief Handle an incoming JSON Clear message
+	///
+	/// Handle an incoming JSON Clear message
+	///
 	/// @param message the incoming message
+	///
 	void handleClearCommand(const Json::Value & message);
 
-	/// @brief Handle an incoming JSON Clearall message
+	///
+	/// Handle an incoming JSON Clearall message
+	///
 	/// @param message the incoming message
+	///
 	void handleClearallCommand(const Json::Value & message);
 
-	/// @brief Handle an incoming JSON Transform message
+	///
+	/// Handle an incoming JSON Transform message
+	///
 	/// @param message the incoming message
+	///
 	void handleTransformCommand(const Json::Value & message);
 
-	/// @brief Handle an incoming JSON message of unknown type
+	///
+	/// Handle an incoming JSON message of unknown type
+	///
 	/// @param message the incoming message
+	///
 	void handleNotImplemented();
 
-	/// @brief Send a message to the connected client
+	///
+	/// Send a message to the connected client
+	///
 	/// @param message The JSON message to send
+	///
 	void sendMessage(const Json::Value & message);
 
-	/// @brief Send a standard reply indicating success
+	///
+	/// Send a standard reply indicating success
+	///
 	void sendSuccessReply();
 
-	/// @brief Send an error message back to the client
+	///
+	/// Send an error message back to the client
+	///
 	/// @param error String describing the error
+	///
 	void sendErrorReply(const std::string & error);
 
 private:
-	/// @brief Check if a JSON messag is valid according to a given JSON schema
+	///
+	/// Check if a JSON messag is valid according to a given JSON schema
+	///
 	/// @param message JSON message which need to be checked
 	/// @param schemaResource Qt esource identifier with the JSON schema
 	/// @param errors Output error message
+	///
 	/// @return true if message conforms the given JSON schema
+	///
 	bool checkJson(const Json::Value & message, const QString &schemaResource, std::string & errors);
 
 private:
+	/// The TCP-Socket that is connected tot the Json-client
 	QTcpSocket * _socket;
 
+	/// The processor for translating images to led-values
 	ImageProcessor * _imageProcessor;
 
+	/// Link to Hyperion for writing led-values to a priority channel
 	Hyperion * _hyperion;
 
+	/// The buffer used for reading data from the socket
 	QByteArray _receiveBuffer;
 };
diff --git a/libsrc/utils/RgbImage.cpp b/libsrc/utils/RgbImage.cpp
index 6372f92f..d79ef0e5 100644
--- a/libsrc/utils/RgbImage.cpp
+++ b/libsrc/utils/RgbImage.cpp
@@ -8,8 +8,8 @@
 
 
 RgbImage::RgbImage(const unsigned width, const unsigned height, const RgbColor background) :
-	mWidth(width),
-	mHeight(height),
+	_width(width),
+	_height(height),
 	mColors(new RgbColor[width*height])
 {
 	for (unsigned i=0; i
Date: Mon, 9 Sep 2013 15:23:44 +0000
Subject: [PATCH 04/12] Changed the constructor of LedDeviceW2801 (only incl
 required parameters) Changed the call sign of the write functions (included
 const declaration of color parameter)

---
 include/hyperion/Hyperion.h  | 4 ++--
 libsrc/hyperion/Hyperion.cpp | 8 +++-----
 test/TestSpi.cpp             | 4 ++--
 3 files changed, 7 insertions(+), 9 deletions(-)

diff --git a/include/hyperion/Hyperion.h b/include/hyperion/Hyperion.h
index e25f1aae..5a9e0159 100644
--- a/include/hyperion/Hyperion.h
+++ b/include/hyperion/Hyperion.h
@@ -70,7 +70,7 @@ public:
 	/// @param[in] ledColor The color to write to the leds
 	/// @param[in] timeout_ms The time the leds are set to the given color [ms]
 	///
-	void setColor(int priority, RgbColor &ledColor, const int timeout_ms);
+	void setColor(int priority, const RgbColor &ledColor, const int timeout_ms);
 
 	///
 	/// Writes the given colors to all leds for the given time and priority
@@ -79,7 +79,7 @@ public:
 	/// @param[in] ledColors The colors to write to the leds
 	/// @param[in] timeout_ms The time the leds are set to the given colors [ms]
 	///
-	void setColors(int priority, std::vector &ledColors, const int timeout_ms);
+	void setColors(int priority, const std::vector &ledColors, const int timeout_ms);
 
 	///
 	/// Sets/Updates a part of the color transformation.
diff --git a/libsrc/hyperion/Hyperion.cpp b/libsrc/hyperion/Hyperion.cpp
index 02bf4252..631ff2a5 100644
--- a/libsrc/hyperion/Hyperion.cpp
+++ b/libsrc/hyperion/Hyperion.cpp
@@ -22,12 +22,10 @@ LedDevice* Hyperion::constructDevice(const Json::Value& deviceConfig)
 	LedDevice* device = nullptr;
 	if (deviceConfig["type"].asString() == "ws2801")
 	{
-		const std::string name = "WS-2801";
 		const std::string output = deviceConfig["output"].asString();
-		const unsigned interval  = deviceConfig["interval"].asInt();
 		const unsigned rate      = deviceConfig["rate"].asInt();
 
-		LedDeviceWs2801* deviceWs2801 = new LedDeviceWs2801(name, output, interval, rate);
+		LedDeviceWs2801* deviceWs2801 = new LedDeviceWs2801(output, rate);
 		deviceWs2801->open();
 
 		device = deviceWs2801;
@@ -117,7 +115,7 @@ unsigned Hyperion::getLedCount() const
 	return _ledString.leds().size();
 }
 
-void Hyperion::setColor(int priority, RgbColor & color, const int timeout_ms)
+void Hyperion::setColor(int priority, const RgbColor &color, const int timeout_ms)
 {
 	// create led output
 	std::vector ledColors(_ledString.leds().size(), color);
@@ -126,7 +124,7 @@ void Hyperion::setColor(int priority, RgbColor & color, const int timeout_ms)
 	setColors(priority, ledColors, timeout_ms);
 }
 
-void Hyperion::setColors(int priority, std::vector& ledColors, const int timeout_ms)
+void Hyperion::setColors(int priority, const std::vector& ledColors, const int timeout_ms)
 {
 	if (timeout_ms > 0)
 	{
diff --git a/test/TestSpi.cpp b/test/TestSpi.cpp
index c955ad88..8d28784a 100644
--- a/test/TestSpi.cpp
+++ b/test/TestSpi.cpp
@@ -54,7 +54,7 @@ void setColor(char* colorStr)
 	unsigned ledCnt = 50;
 	std::vector buff(ledCnt, color);
 
-	LedDeviceWs2801 ledDevice("SpiPi", "/dev/spidev0.0", 20000, 40000);
+	LedDeviceWs2801 ledDevice("/dev/spidev0.0", 40000);
 	ledDevice.open();
 	ledDevice.write(buff);
 }
@@ -68,7 +68,7 @@ void doCircle()
 	unsigned ledCnt = 50;
 	std::vector data(ledCnt, RgbColor::BLACK);
 
-	LedDeviceWs2801 ledDevice("SpiPi", "/dev/spidev0.0", 20000, 40000);
+	LedDeviceWs2801 ledDevice("/dev/spidev0.0", 40000);
 	ledDevice.open();
 
 	timespec loopTime;

From a567f0feeb88fc90ccd3c3731839334f09f3519c Mon Sep 17 00:00:00 2001
From: "T. van der Zwan" 
Date: Mon, 9 Sep 2013 15:24:36 +0000
Subject: [PATCH 05/12] Added abstract boot sequence to handle events and
 iteration count. Implemented KnightRider bootsequence (KittBootSequence).

---
 libsrc/bootsequence/AbstractBootSequence.cpp | 35 ++++++++++
 libsrc/bootsequence/AbstractBootSequence.h   | 40 ++++++++++++
 libsrc/bootsequence/CMakeLists.txt           |  6 +-
 libsrc/bootsequence/KittBootSequence.cpp     | 67 ++++++++++++++++++++
 libsrc/bootsequence/KittBootSequence.h       | 36 +++++++++++
 libsrc/bootsequence/RainbowBootSequence.cpp  | 46 ++++----------
 libsrc/bootsequence/RainbowBootSequence.h    | 27 ++------
 7 files changed, 198 insertions(+), 59 deletions(-)
 create mode 100644 libsrc/bootsequence/AbstractBootSequence.cpp
 create mode 100644 libsrc/bootsequence/AbstractBootSequence.h
 create mode 100644 libsrc/bootsequence/KittBootSequence.cpp
 create mode 100644 libsrc/bootsequence/KittBootSequence.h

diff --git a/libsrc/bootsequence/AbstractBootSequence.cpp b/libsrc/bootsequence/AbstractBootSequence.cpp
new file mode 100644
index 00000000..585ebb8c
--- /dev/null
+++ b/libsrc/bootsequence/AbstractBootSequence.cpp
@@ -0,0 +1,35 @@
+#include "AbstractBootSequence.h"
+
+AbstractBootSequence::AbstractBootSequence(Hyperion * hyperion, const int64_t interval, const unsigned iterationCnt) :
+	_timer(),
+	_hyperion(hyperion),
+	_priority(0),
+	_iterationCounter(iterationCnt)
+{
+	_timer.setInterval(interval);
+	_timer.setSingleShot(false);
+	QObject::connect(&_timer, SIGNAL(timeout()), this, SLOT(update()));
+}
+
+void AbstractBootSequence::start()
+{
+	_timer.start();
+}
+
+void AbstractBootSequence::update()
+{
+	if (_iterationCounter == 0)
+	{
+		_timer.stop();
+		_hyperion->clear(_priority);
+		return;
+	}
+
+	// Obtain the next led-colors from the child-class
+	const std::vector& colors = nextColors();
+	// Write the colors to hyperion
+	_hyperion->setColors(_priority, colors, -1);
+
+	// Decrease the loop count
+	--_iterationCounter;
+}
diff --git a/libsrc/bootsequence/AbstractBootSequence.h b/libsrc/bootsequence/AbstractBootSequence.h
new file mode 100644
index 00000000..bd2d944b
--- /dev/null
+++ b/libsrc/bootsequence/AbstractBootSequence.h
@@ -0,0 +1,40 @@
+#pragma once
+
+// QT includes
+#include 
+
+// Bootsequence includes
+#include 
+
+// Hyperion includes
+#include 
+
+class AbstractBootSequence : public QObject, public BootSequence
+{
+Q_OBJECT
+
+public:
+	AbstractBootSequence(Hyperion * hyperion, const int64_t interval, const unsigned iterationCnt);
+
+	virtual void start();
+
+protected slots:
+	void update();
+
+
+protected:
+	virtual const std::vector& nextColors() = 0;
+
+private:
+	/// The timer used to generate an 'update' signal every interval
+	QTimer _timer;
+
+	/// The Hyperion instance
+	Hyperion * _hyperion;
+	/// The priority of the boot sequence
+	int _priority;
+
+	/// The counter of the number of iterations left
+	int _iterationCounter;
+};
+
diff --git a/libsrc/bootsequence/CMakeLists.txt b/libsrc/bootsequence/CMakeLists.txt
index 28bfdfb3..f10e37a4 100644
--- a/libsrc/bootsequence/CMakeLists.txt
+++ b/libsrc/bootsequence/CMakeLists.txt
@@ -5,17 +5,21 @@ SET(CURRENT_SOURCE_DIR ${CMAKE_SOURCE_DIR}/libsrc/bootsequence)
 
 # Group the headers that go through the MOC compiler
 SET(BootsequenceQT_HEADERS
-		${CURRENT_SOURCE_DIR}/RainbowBootSequence.h
+		${CURRENT_SOURCE_DIR}/AbstractBootSequence.h
 )
 
 SET(BootsequenceHEADERS
 		${CURRENT_HEADER_DIR}/BootSequence.h
 		${CURRENT_HEADER_DIR}/BootSequenceFactory.h
+		${CURRENT_SOURCE_DIR}/RainbowBootSequence.h
+		${CURRENT_SOURCE_DIR}/KittBootSequence.h
 )
 
 SET(BootsequenceSOURCES
+		${CURRENT_SOURCE_DIR}/AbstractBootSequence.cpp
 		${CURRENT_SOURCE_DIR}/BootSequenceFactory.cpp
 		${CURRENT_SOURCE_DIR}/RainbowBootSequence.cpp
+		${CURRENT_SOURCE_DIR}/KittBootSequence.cpp
 )
 
 QT4_WRAP_CPP(BootsequenceHEADERS_MOC ${BootsequenceQT_HEADERS})
diff --git a/libsrc/bootsequence/KittBootSequence.cpp b/libsrc/bootsequence/KittBootSequence.cpp
new file mode 100644
index 00000000..b40e1e0e
--- /dev/null
+++ b/libsrc/bootsequence/KittBootSequence.cpp
@@ -0,0 +1,67 @@
+
+// Hyperion includes
+#include 
+
+// Local-Bootsequence includes
+#include "KittBootSequence.h"
+
+KittBootSequence::KittBootSequence(Hyperion * hyperion, const unsigned duration_ms) :
+	AbstractBootSequence(hyperion, 100, duration_ms/100),
+	_processor(ImageProcessorFactory::getInstance().newImageProcessor()),
+	_image(9, 1),
+	_ledColors(hyperion->getLedCount(), RgbColor::BLACK),
+	_forwardMove(false),
+	_currentLight(0)
+{
+	// empty
+}
+
+KittBootSequence::~KittBootSequence()
+{
+	delete _processor;
+}
+
+const std::vector& KittBootSequence::nextColors()
+{
+
+	// Switch the previous light 'off'
+	_image(_currentLight, 0) = RgbColor::BLACK;
+
+	// Move the current to the next light
+	moveNextLight();
+
+	// Switch the current light 'on'
+	_image(_currentLight, 0) = RgbColor::RED;
+
+
+	// Translate the 'image' to led colors
+	_processor->process(_image, _ledColors);
+
+	// Return the colors
+	return _ledColors;
+}
+
+void KittBootSequence::moveNextLight()
+{
+	// Increase/Decrease the current light
+	if (_forwardMove)
+	{
+		++_currentLight;
+		if (_currentLight == _image.width())
+		{
+			_forwardMove = false;
+			--_currentLight;
+		}
+	}
+	else
+	{
+		if (_currentLight == 0)
+		{
+			_forwardMove = true;
+		}
+		else
+		{
+			--_currentLight;
+		}
+	}
+}
diff --git a/libsrc/bootsequence/KittBootSequence.h b/libsrc/bootsequence/KittBootSequence.h
new file mode 100644
index 00000000..809027b9
--- /dev/null
+++ b/libsrc/bootsequence/KittBootSequence.h
@@ -0,0 +1,36 @@
+
+#pragma once
+
+// Bootsequence includes
+#include "AbstractBootSequence.h"
+
+// Hyperion includes
+#include 
+#include 
+
+
+class KittBootSequence : public AbstractBootSequence
+{
+public:
+	KittBootSequence(Hyperion * hyperion, const unsigned duration_ms);
+
+	virtual ~KittBootSequence();
+
+	virtual const std::vector& nextColors();
+
+private:
+	/// Image processor to compute led-colors from the image
+	ImageProcessor * _processor;
+
+	/// 1D-Image of the KITT-grill contains a single red pixel and the rest black
+	RgbImage _image;
+
+	/// The vector with led-colors
+	std::vector _ledColors;
+
+	bool _forwardMove = true;
+	unsigned _currentLight = 0;
+
+	void moveNextLight();
+};
+
diff --git a/libsrc/bootsequence/RainbowBootSequence.cpp b/libsrc/bootsequence/RainbowBootSequence.cpp
index b60364ed..d976b70d 100644
--- a/libsrc/bootsequence/RainbowBootSequence.cpp
+++ b/libsrc/bootsequence/RainbowBootSequence.cpp
@@ -6,49 +6,25 @@
 #include "RainbowBootSequence.h"
 
 RainbowBootSequence::RainbowBootSequence(Hyperion * hyperion, const unsigned duration_ms) :
-	_timer(),
-	_hyperion(hyperion),
-	_priority(0),
-	_ledColors(hyperion->getLedCount()),
-	_iterationCounter(hyperion->getLedCount())
+	AbstractBootSequence(hyperion, duration_ms/hyperion->getLedCount(), hyperion->getLedCount()),
+	_ledColors(hyperion->getLedCount())
 {
-	for (unsigned iLed=0; iLed<_hyperion->getLedCount(); ++iLed)
+	for (unsigned iLed=0; iLedgetLedCount(); ++iLed)
 	{
 		RgbColor& color = _ledColors[iLed];
-		HsvTransform::hsv2rgb(iLed*360/_hyperion->getLedCount(), 255, 255, color.red, color.green, color.blue);
+		HsvTransform::hsv2rgb(iLed*360/hyperion->getLedCount(), 255, 255, color.red, color.green, color.blue);
 	}
-
-	_timer.setInterval(duration_ms/_hyperion->getLedCount());
-	_timer.setSingleShot(false);
-	QObject::connect(&_timer, SIGNAL(timeout()), this, SLOT(update()));
 }
 
-void RainbowBootSequence::start()
+const std::vector& RainbowBootSequence::nextColors()
 {
-	_timer.start();
-}
-
-void RainbowBootSequence::update()
-{
-	if (_iterationCounter == 0)
+	// Rotate the colors left
+	const RgbColor headColor = _ledColors.front();
+	for (unsigned i=1; i<_ledColors.size(); ++i)
 	{
-		_timer.stop();
-		_hyperion->clear(_priority);
+		_ledColors[i-1] = _ledColors[i];
 	}
-	else
-	{
-		// Rotate the colors left
-		const RgbColor headColor = _ledColors.front();
-		for (unsigned i=1; i<_ledColors.size(); ++i)
-		{
-			_ledColors[i-1] = _ledColors[i];
-		}
-		_ledColors.back() = headColor;
+	_ledColors.back() = headColor;
 
-		// Write the colors to hyperion
-		_hyperion->setColors(_priority, _ledColors, -1);
-
-		// Decrease the loop count
-		--_iterationCounter;
-	}
+	return _ledColors;
 }
diff --git a/libsrc/bootsequence/RainbowBootSequence.h b/libsrc/bootsequence/RainbowBootSequence.h
index a6b38ca1..e227febf 100644
--- a/libsrc/bootsequence/RainbowBootSequence.h
+++ b/libsrc/bootsequence/RainbowBootSequence.h
@@ -5,19 +5,14 @@
 #include 
 
 // Bootsequence include
-#include 
-
-// Hyperion includes
-#include 
+#include "AbstractBootSequence.h"
 
 ///
 /// The RainborBootSequence shows a 'rainbow' (all lights have a different color). The rainbow is
 /// rotated over each led during the length of the sequence.
 ///
-class RainbowBootSequence : public QObject, public BootSequence
+class RainbowBootSequence : public AbstractBootSequence
 {
-Q_OBJECT
-
 public:
 	///
 	/// Constructs the rainbow boot-sequence. Hyperion is used for writing the led colors. The given
@@ -28,27 +23,13 @@ public:
 	///
 	RainbowBootSequence(Hyperion * hyperion, const unsigned duration_ms);
 
-	///
-	/// Starts the boot-sequence
-	///
-	virtual void start();
-
-private slots:
+protected:
 	///
 	/// Moves the rainbow one led further
 	///
-	void update();
+	const std::vector& nextColors();
 
 private:
-	/// The timer used to generate an 'update' signal every interval
-	QTimer _timer;
-
-	/// The Hyperion instance
-	Hyperion * _hyperion;
-
-	/// The priority of the boot sequence
-	int _priority;
-
 	/// The current color of the boot sequence (the rainbow)
 	std::vector _ledColors;
 	/// The counter of the number of iterations left

From b9826e06eeb8e8675245436d4fcaa83fda19c996 Mon Sep 17 00:00:00 2001
From: "T. van der Zwan" 
Date: Mon, 9 Sep 2013 17:14:49 +0000
Subject: [PATCH 06/12] Added doxygen comments

---
 libsrc/bootsequence/AbstractBootSequence.h | 24 +++++++++++++++++++++-
 libsrc/bootsequence/KittBootSequence.h     | 22 +++++++++++++++++++-
 2 files changed, 44 insertions(+), 2 deletions(-)

diff --git a/libsrc/bootsequence/AbstractBootSequence.h b/libsrc/bootsequence/AbstractBootSequence.h
index bd2d944b..8ef7e712 100644
--- a/libsrc/bootsequence/AbstractBootSequence.h
+++ b/libsrc/bootsequence/AbstractBootSequence.h
@@ -9,20 +9,42 @@
 // Hyperion includes
 #include 
 
+///
+/// The AbstractBootSequence is an 'abstract' implementation of the BootSequence that handles the
+/// event generation and Hyperion connection. Subclasses only need to specify the interval and
+/// return the colors for the leds for each iteration.
+///
 class AbstractBootSequence : public QObject, public BootSequence
 {
 Q_OBJECT
 
 public:
+	///
+	/// Constructs the AbstractBootSequence with the given parameters
+	///
+	/// @param hyperion The Hyperion instance
+	/// @param interval The interval between new led colors
+	/// @param iterationCnt The number of iteration performed by the boot sequence
+	///
 	AbstractBootSequence(Hyperion * hyperion, const int64_t interval, const unsigned iterationCnt);
 
+	///
+	/// Starts the boot-sequence
+	///
 	virtual void start();
 
 protected slots:
+	///
+	/// Timer slot for handling each interval of the boot-sequence
+	///
 	void update();
 
-
 protected:
+	///
+	/// Child-classes must implement this by returning the next led colors in the sequence
+	///
+	/// @return The next led colors in the boot sequence
+	///
 	virtual const std::vector& nextColors() = 0;
 
 private:
diff --git a/libsrc/bootsequence/KittBootSequence.h b/libsrc/bootsequence/KittBootSequence.h
index 809027b9..ccd26845 100644
--- a/libsrc/bootsequence/KittBootSequence.h
+++ b/libsrc/bootsequence/KittBootSequence.h
@@ -8,14 +8,31 @@
 #include 
 #include 
 
-
+///
+/// The KITT BootSequence is a boot sequence inspired by the Knight Rider car: Knight Industries Two
+/// Thousand (aka KITT)
+///
 class KittBootSequence : public AbstractBootSequence
 {
 public:
+	///
+	/// Constructs the KITT BootSequence
+	///
+	/// @param[in] hyperion  The Hyperion instance
+	/// @param[in] duration_ms  The length of the sequence [ms]
+	///
 	KittBootSequence(Hyperion * hyperion, const unsigned duration_ms);
 
+	///
+	/// Destructor, deletes the processor
+	///
 	virtual ~KittBootSequence();
 
+	///
+	/// Returns the next led color sequence
+	///
+	/// @return The next colors for the leds
+	///
 	virtual const std::vector& nextColors();
 
 private:
@@ -28,9 +45,12 @@ private:
 	/// The vector with led-colors
 	std::vector _ledColors;
 
+	/// Direction the red-light is currently moving
 	bool _forwardMove = true;
+	/// The location of the current red-light
 	unsigned _currentLight = 0;
 
+	/// Moves the current light to the next (increase or decrease depending on direction)
 	void moveNextLight();
 };
 

From a6c0f06b444e4cb126e7a7097b523c30d42bf4d5 Mon Sep 17 00:00:00 2001
From: "T. van der Zwan" 
Date: Mon, 9 Sep 2013 20:35:03 +0000
Subject: [PATCH 07/12] Added automatic doxygen generation to cmake

---
 CMakeLists.txt               |    3 +
 doc/CMakeLists.txt           |   32 +
 doc/hyperion-build-doc.in.sh |   30 +
 doc/hyperion-footer.html     |    8 +
 doc/hyperion-header.html     |    9 +
 doc/hyperion-stylesheet.css  |  472 +++++++++++
 doc/hyperion.in.doxygen      | 1421 ++++++++++++++++++++++++++++++++++
 7 files changed, 1975 insertions(+)
 create mode 100644 doc/CMakeLists.txt
 create mode 100644 doc/hyperion-build-doc.in.sh
 create mode 100644 doc/hyperion-footer.html
 create mode 100644 doc/hyperion-header.html
 create mode 100644 doc/hyperion-stylesheet.css
 create mode 100644 doc/hyperion.in.doxygen

diff --git a/CMakeLists.txt b/CMakeLists.txt
index c90d137e..eb288f56 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -46,3 +46,6 @@ add_subdirectory(dependencies)
 add_subdirectory(libsrc)
 add_subdirectory(src)
 add_subdirectory(test)
+
+# Add the doxygen generation directory
+add_subdirectory(doc)
diff --git a/doc/CMakeLists.txt b/doc/CMakeLists.txt
new file mode 100644
index 00000000..dc5e88fd
--- /dev/null
+++ b/doc/CMakeLists.txt
@@ -0,0 +1,32 @@
+
+# Find doxygen
+find_package(Doxygen QUIET)
+
+# This processes our hyperion-cmake.doxyfile and subsitutes variables to generate a final hyperion.doxyfile
+configure_file(${CMAKE_CURRENT_SOURCE_DIR}/hyperion.in.doxygen ${CMAKE_CURRENT_BINARY_DIR}/hyperion.doxygen)
+
+# This processes the shell script that is used to build the documentation and check the result
+configure_file(${CMAKE_CURRENT_SOURCE_DIR}/hyperion-build-doc.in.sh ${CMAKE_CURRENT_BINARY_DIR}/hyperion-build-doc.sh)
+
+# Define all static (i.e. not generated) documentation files
+set(StaticDocumentationFiles hyperion-header.html hyperion-footer.html hyperion-stylesheet.css)
+
+# Loop over all static documentation files
+foreach(StaticDocumentationFile ${StaticDocumentationFiles})
+	# Copy the file to the bindary documentation directory
+	configure_file(${CMAKE_CURRENT_SOURCE_DIR}/${StaticDocumentationFile} ${CMAKE_CURRENT_BINARY_DIR}/html/${StaticDocumentationFile} COPYONLY)
+endforeach()
+
+if(DOXYGEN_FOUND)
+	option(BuildDocumentationSearchEngine "Enable doxygen's search engine (requires that documentation to be installed on a php enabled web server)" OFF)
+	if(BuildDocumentationSearchEngine)
+		set(DOXYGEN_SEARCHENGINE YES)
+	else(BuildDocumentationSearchEngine)
+		set(DOXYGEN_SEARCHENGINE NO)
+	endif(BuildDocumentationSearchEngine)
+
+	#Create a custom target to build documentation. It runs doxygen aginast the generated hyperion.doxyfile and checks its return value
+	add_custom_target(doc sh ${CMAKE_CURRENT_BINARY_DIR}/hyperion-build-doc.sh)
+else(DOXYGEN_FOUND)
+	message(WARNING "Doxygen not found, unable to generate documenation!")
+endif(DOXYGEN_FOUND)
diff --git a/doc/hyperion-build-doc.in.sh b/doc/hyperion-build-doc.in.sh
new file mode 100644
index 00000000..3198611d
--- /dev/null
+++ b/doc/hyperion-build-doc.in.sh
@@ -0,0 +1,30 @@
+#!/bin/sh
+
+# Fail on error.
+set -e
+
+# Log file containing documentation errors and warnings (if any).
+log_file=${CMAKE_CURRENT_BINARY_DIR}/hyperion-doxygen.log
+
+# Remove the log file before building the documentation.
+rm -f $log_file
+
+# Generate the documentation.
+${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/hyperion.doxygen
+
+# At this point, the log file should have been generated.
+# If not, an error is displayed on stderr and 1 is returned to indicate an error.
+if [ -f $log_file ] ; then
+	# So the log file exists. If its size is > 0, show its contents on stderr and exit 1.
+	if [ -s $log_file ] ; then
+	cat $log_file 1>&2
+	exit 1;
+	else
+	# The log file exists, but its size is zero, meaning there were no documentation warnings or errors.
+	# Exit with 0 to indicate success.
+	exit 0;
+	fi
+else
+	echo "The doxygen log file ($log_file) does not exist. Ensure that WARN_LOGFILE is set correctly in hyperion-cmake.doxyfile." 1>&2
+	exit 1;
+fi
diff --git a/doc/hyperion-footer.html b/doc/hyperion-footer.html
new file mode 100644
index 00000000..dc33270e
--- /dev/null
+++ b/doc/hyperion-footer.html
@@ -0,0 +1,8 @@
+        
+ + + + +
Generated at $datetime for $projectname by doxygen $doxygenversion.
+ + diff --git a/doc/hyperion-header.html b/doc/hyperion-header.html new file mode 100644 index 00000000..652afa69 --- /dev/null +++ b/doc/hyperion-header.html @@ -0,0 +1,9 @@ + + + + + $title + + + + diff --git a/doc/hyperion-stylesheet.css b/doc/hyperion-stylesheet.css new file mode 100644 index 00000000..2e81b75d --- /dev/null +++ b/doc/hyperion-stylesheet.css @@ -0,0 +1,472 @@ +BODY,H1,H2,H3,H4,H5,H6,P,CENTER,TD,TH,UL,DL,DIV { + font-family: Geneva, Arial, Helvetica, sans-serif; +} +BODY,TD { + font-size: 90%; +} +H1 { + text-align: center; + font-size: 160%; +} +H2 { + font-size: 120%; +} +H3 { + font-size: 100%; +} +CAPTION { + font-weight: bold +} +DIV.qindex { + width: 100%; + background-color: #e8eef2; + border: 1px solid #84b0c7; + text-align: center; + margin: 2px; + padding: 2px; + line-height: 140%; +} +DIV.navpath { + width: 100%; + background-color: #e8eef2; + border: 1px solid #84b0c7; + text-align: center; + margin: 2px; + padding: 2px; + line-height: 140%; +} +DIV.navtab { + background-color: #e8eef2; + border: 1px solid #84b0c7; + text-align: center; + margin: 2px; + margin-right: 15px; + padding: 2px; +} +TD.navtab { + font-size: 70%; +} +A.qindex { + text-decoration: none; + font-weight: bold; + color: #1A419D; +} +A.qindex:visited { + text-decoration: none; + font-weight: bold; + color: #1A419D +} +A.qindex:hover { + text-decoration: none; + background-color: #ddddff; +} +A.qindexHL { + text-decoration: none; + font-weight: bold; + background-color: #6666cc; + color: #ffffff; + border: 1px double #9295C2; +} +A.qindexHL:hover { + text-decoration: none; + background-color: #6666cc; + color: #ffffff; +} +A.qindexHL:visited { + text-decoration: none; + background-color: #6666cc; + color: #ffffff +} +A.el { + text-decoration: none; + font-weight: bold +} +A.elRef { + font-weight: bold +} +A.code:link { + text-decoration: none; + font-weight: normal; + color: #0000FF +} +A.code:visited { + text-decoration: none; + font-weight: normal; + color: #0000FF +} +A.codeRef:link { + font-weight: normal; + color: #0000FF +} +A.codeRef:visited { + font-weight: normal; + color: #0000FF +} +A:hover { + text-decoration: none; + background-color: #f2f2ff +} +DL.el { + margin-left: -1cm +} +.fragment { + font-family: monospace, fixed; + font-size: 95%; +} +PRE.fragment { + border: 1px solid #CCCCCC; + background-color: #f5f5f5; + margin-top: 4px; + margin-bottom: 4px; + margin-left: 2px; + margin-right: 8px; + padding-left: 6px; + padding-right: 6px; + padding-top: 4px; + padding-bottom: 4px; +} +DIV.ah { + background-color: black; + font-weight: bold; + color: #ffffff; + margin-bottom: 3px; + margin-top: 3px +} + +DIV.groupHeader { + margin-left: 16px; + margin-top: 12px; + margin-bottom: 6px; + font-weight: bold; +} +DIV.groupText { + margin-left: 16px; + font-style: italic; + font-size: 90% +} +BODY { + background: white; + color: black; + margin-right: 20px; + margin-left: 20px; +} +TD.indexkey { + background-color: #e8eef2; + font-weight: bold; + padding-right : 10px; + padding-top : 2px; + padding-left : 10px; + padding-bottom : 2px; + margin-left : 0px; + margin-right : 0px; + margin-top : 2px; + margin-bottom : 2px; + border: 1px solid #CCCCCC; +} +TD.indexvalue { + background-color: #e8eef2; + font-style: italic; + padding-right : 10px; + padding-top : 2px; + padding-left : 10px; + padding-bottom : 2px; + margin-left : 0px; + margin-right : 0px; + margin-top : 2px; + margin-bottom : 2px; + border: 1px solid #CCCCCC; +} +TR.memlist { + background-color: #f0f0f0; +} +P.formulaDsp { + text-align: center; +} +IMG.formulaDsp { +} +IMG.formulaInl { + vertical-align: middle; +} +SPAN.keyword { color: #008000 } +SPAN.keywordtype { color: #604020 } +SPAN.keywordflow { color: #e08000 } +SPAN.comment { color: #800000 } +SPAN.preprocessor { color: #806020 } +SPAN.stringliteral { color: #002080 } +SPAN.charliteral { color: #008080 } +SPAN.vhdldigit { color: #ff00ff } +SPAN.vhdlchar { color: #000000 } +SPAN.vhdlkeyword { color: #700070 } +SPAN.vhdllogic { color: #ff0000 } + +.mdescLeft { + padding: 0px 8px 4px 8px; + font-size: 80%; + font-style: italic; + background-color: #FAFAFA; + border-top: 1px none #E0E0E0; + border-right: 1px none #E0E0E0; + border-bottom: 1px none #E0E0E0; + border-left: 1px none #E0E0E0; + margin: 0px; +} +.mdescRight { + padding: 0px 8px 4px 8px; + font-size: 80%; + font-style: italic; + background-color: #FAFAFA; + border-top: 1px none #E0E0E0; + border-right: 1px none #E0E0E0; + border-bottom: 1px none #E0E0E0; + border-left: 1px none #E0E0E0; + margin: 0px; +} +.memItemLeft { + padding: 1px 0px 0px 8px; + margin: 4px; + border-top-width: 1px; + border-right-width: 1px; + border-bottom-width: 1px; + border-left-width: 1px; + border-top-color: #E0E0E0; + border-right-color: #E0E0E0; + border-bottom-color: #E0E0E0; + border-left-color: #E0E0E0; + border-top-style: solid; + border-right-style: none; + border-bottom-style: none; + border-left-style: none; + background-color: #FAFAFA; + font-size: 80%; +} +.memItemRight { + padding: 1px 8px 0px 8px; + margin: 4px; + border-top-width: 1px; + border-right-width: 1px; + border-bottom-width: 1px; + border-left-width: 1px; + border-top-color: #E0E0E0; + border-right-color: #E0E0E0; + border-bottom-color: #E0E0E0; + border-left-color: #E0E0E0; + border-top-style: solid; + border-right-style: none; + border-bottom-style: none; + border-left-style: none; + background-color: #FAFAFA; + font-size: 80%; +} +.memTemplItemLeft { + padding: 1px 0px 0px 8px; + margin: 4px; + border-top-width: 1px; + border-right-width: 1px; + border-bottom-width: 1px; + border-left-width: 1px; + border-top-color: #E0E0E0; + border-right-color: #E0E0E0; + border-bottom-color: #E0E0E0; + border-left-color: #E0E0E0; + border-top-style: none; + border-right-style: none; + border-bottom-style: none; + border-left-style: none; + background-color: #FAFAFA; + font-size: 80%; +} +.memTemplItemRight { + padding: 1px 8px 0px 8px; + margin: 4px; + border-top-width: 1px; + border-right-width: 1px; + border-bottom-width: 1px; + border-left-width: 1px; + border-top-color: #E0E0E0; + border-right-color: #E0E0E0; + border-bottom-color: #E0E0E0; + border-left-color: #E0E0E0; + border-top-style: none; + border-right-style: none; + border-bottom-style: none; + border-left-style: none; + background-color: #FAFAFA; + font-size: 80%; +} +.memTemplParams { + padding: 1px 0px 0px 8px; + margin: 4px; + border-top-width: 1px; + border-right-width: 1px; + border-bottom-width: 1px; + border-left-width: 1px; + border-top-color: #E0E0E0; + border-right-color: #E0E0E0; + border-bottom-color: #E0E0E0; + border-left-color: #E0E0E0; + border-top-style: solid; + border-right-style: none; + border-bottom-style: none; + border-left-style: none; + color: #606060; + background-color: #FAFAFA; + font-size: 80%; +} +.search { + color: #003399; + font-weight: bold; +} +FORM.search { + margin-bottom: 0px; + margin-top: 0px; +} +INPUT.search { + font-size: 75%; + color: #000080; + font-weight: normal; + background-color: #e8eef2; +} +TD.tiny { + font-size: 75%; +} +a { + color: #1A41A8; +} +a:visited { + color: #2A3798; +} +.dirtab { + padding: 4px; + border-collapse: collapse; + border: 1px solid #84b0c7; +} +TH.dirtab { + background: #e8eef2; + font-weight: bold; +} +HR { + height: 1px; + border: none; + border-top: 1px solid black; +} + +/* Style for detailed member documentation */ +.memtemplate { + font-size: 80%; + color: #606060; + font-weight: normal; + margin-left: 3px; +} +.memnav { + background-color: #e8eef2; + border: 1px solid #84b0c7; + text-align: center; + margin: 2px; + margin-right: 15px; + padding: 2px; +} +.memitem { + padding: 4px; + background-color: #eef3f5; + border-width: 1px; + border-style: solid; + border-color: #dedeee; + -moz-border-radius: 8px 8px 8px 8px; +} +.memname { + white-space: nowrap; + font-weight: bold; +} +.memdoc { + padding-left: 10px; +} +.memproto { + background-color: #d5e1e8; + width: 100%; + border-width: 1px; + border-style: solid; + border-color: #84b0c7; + font-weight: bold; + -moz-border-radius: 8px 8px 8px 8px; +} +.paramkey { + text-align: right; +} +.paramtype { + white-space: nowrap; +} +.paramname { + color: #602020; + font-style: italic; + white-space: nowrap; +} +/* End Styling for detailed member documentation */ + +/* for the tree view */ +.ftvtree { + font-family: sans-serif; + margin:0.5em; +} +/* these are for tree view when used as main index */ +.directory { + font-size: 9pt; + font-weight: bold; +} +.directory h3 { + margin: 0px; + margin-top: 1em; + font-size: 11pt; +} + +/* The following two styles can be used to replace the root node title */ +/* with an image of your choice. Simply uncomment the next two styles, */ +/* specify the name of your image and be sure to set 'height' to the */ +/* proper pixel height of your image. */ + +/* .directory h3.swap { */ +/* height: 61px; */ +/* background-repeat: no-repeat; */ +/* background-image: url("yourimage.gif"); */ +/* } */ +/* .directory h3.swap span { */ +/* display: none; */ +/* } */ + +.directory > h3 { + margin-top: 0; +} +.directory p { + margin: 0px; + white-space: nowrap; +} +.directory div { + display: none; + margin: 0px; +} +.directory img { + vertical-align: -30%; +} +/* these are for tree view when not used as main index */ +.directory-alt { + font-size: 100%; + font-weight: bold; +} +.directory-alt h3 { + margin: 0px; + margin-top: 1em; + font-size: 11pt; +} +.directory-alt > h3 { + margin-top: 0; +} +.directory-alt p { + margin: 0px; + white-space: nowrap; +} +.directory-alt div { + display: none; + margin: 0px; +} +.directory-alt img { + vertical-align: -30%; +} diff --git a/doc/hyperion.in.doxygen b/doc/hyperion.in.doxygen new file mode 100644 index 00000000..a5cc4c6a --- /dev/null +++ b/doc/hyperion.in.doxygen @@ -0,0 +1,1421 @@ +# Doxyfile 1.5.6 + +# This file describes the settings to be used by the documentation system +# doxygen (www.doxygen.org) for a project +# +# All text after a hash (#) is considered a comment and will be ignored +# The format is: +# TAG = value [value, ...] +# For lists items can also be appended using: +# TAG += value [value, ...] +# Values that contain spaces should be placed between quotes (" ") + +#--------------------------------------------------------------------------- +# Project related configuration options +#--------------------------------------------------------------------------- + +# This tag specifies the encoding used for all characters in the config file +# that follow. The default is UTF-8 which is also the encoding used for all +# text before the first occurrence of this tag. Doxygen uses libiconv (or the +# iconv built into libc) for the transcoding. See +# http://www.gnu.org/software/libiconv for the list of possible encodings. + +DOXYFILE_ENCODING = UTF-8 + +# The PROJECT_NAME tag is a single word (or a sequence of words surrounded +# by quotes) that should identify the project. + +PROJECT_NAME = Hyperion + +# The PROJECT_NUMBER tag can be used to enter a project or revision number. +# This could be handy for archiving the generated documentation or +# if some version control system is used. + +PROJECT_NUMBER = "Version 0.1" + +# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) +# base path where the generated documentation will be put. +# If a relative path is entered, it will be relative to the location +# where doxygen was started. If left blank the current directory will be used. + +OUTPUT_DIRECTORY = "${CMAKE_CURRENT_BINARY_DIR}" + +# If the CREATE_SUBDIRS tag is set to YES, then doxygen will create +# 4096 sub-directories (in 2 levels) under the output directory of each output +# format and will distribute the generated files over these directories. +# Enabling this option can be useful when feeding doxygen a huge amount of +# source files, where putting all generated files in the same directory would +# otherwise cause performance problems for the file system. + +CREATE_SUBDIRS = YES + +# The OUTPUT_LANGUAGE tag is used to specify the language in which all +# documentation generated by doxygen is written. Doxygen will use this +# information to generate all constant output in the proper language. +# The default language is English, other supported languages are: +# Afrikaans, Arabic, Brazilian, Catalan, Chinese, Chinese-Traditional, +# Croatian, Czech, Danish, Dutch, Farsi, Finnish, French, German, Greek, +# Hungarian, Italian, Japanese, Japanese-en (Japanese with English messages), +# Korean, Korean-en, Lithuanian, Norwegian, Macedonian, Persian, Polish, +# Portuguese, Romanian, Russian, Serbian, Slovak, Slovene, Spanish, Swedish, +# and Ukrainian. + +OUTPUT_LANGUAGE = English + +# If the BRIEF_MEMBER_DESC tag is set to YES (the default) Doxygen will +# include brief member descriptions after the members that are listed in +# the file and class documentation (similar to JavaDoc). +# Set to NO to disable this. + +BRIEF_MEMBER_DESC = YES + +# If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will prepend +# the brief description of a member or function before the detailed description. +# Note: if both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the +# brief descriptions will be completely suppressed. + +REPEAT_BRIEF = YES + +# This tag implements a quasi-intelligent brief description abbreviator +# that is used to form the text in various listings. Each string +# in this list, if found as the leading text of the brief description, will be +# stripped from the text and the result after processing the whole list, is +# used as the annotated text. Otherwise, the brief description is used as-is. +# If left blank, the following values are used ("$name" is automatically +# replaced with the name of the entity): "The $name class" "The $name widget" +# "The $name file" "is" "provides" "specifies" "contains" +# "represents" "a" "an" "the" + +ABBREVIATE_BRIEF = + +# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then +# Doxygen will generate a detailed section even if there is only a brief +# description. + +ALWAYS_DETAILED_SEC = NO + +# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all +# inherited members of a class in the documentation of that class as if those +# members were ordinary class members. Constructors, destructors and assignment +# operators of the base classes will not be shown. + +INLINE_INHERITED_MEMB = NO + +# If the FULL_PATH_NAMES tag is set to YES then Doxygen will prepend the full +# path before files name in the file list and in the header files. If set +# to NO the shortest path that makes the file name unique will be used. + +FULL_PATH_NAMES = YES + +# If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag +# can be used to strip a user-defined part of the path. Stripping is +# only done if one of the specified strings matches the left-hand part of +# the path. The tag can be used to show relative paths in the file list. +# If left blank the directory from which doxygen is run is used as the +# path to strip. + +STRIP_FROM_PATH = ${CMAKE_SOURCE_DIR} + +# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of +# the path mentioned in the documentation of a class, which tells +# the reader which header file to include in order to use a class. +# If left blank only the name of the header file containing the class +# definition is used. Otherwise one should specify the include paths that +# are normally passed to the compiler using the -I flag. + +STRIP_FROM_INC_PATH = + +# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter +# (but less readable) file names. This can be useful is your file systems +# doesn't support long names like on DOS, Mac, or CD-ROM. + +SHORT_NAMES = YES + +# If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen +# will interpret the first line (until the first dot) of a JavaDoc-style +# comment as the brief description. If set to NO, the JavaDoc +# comments will behave just like regular Qt-style comments +# (thus requiring an explicit @brief command for a brief description.) + +JAVADOC_AUTOBRIEF = YES + +# If the QT_AUTOBRIEF tag is set to YES then Doxygen will +# interpret the first line (until the first dot) of a Qt-style +# comment as the brief description. If set to NO, the comments +# will behave just like regular Qt-style comments (thus requiring +# an explicit \brief command for a brief description.) + +QT_AUTOBRIEF = NO + +# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make Doxygen +# treat a multi-line C++ special comment block (i.e. a block of //! or /// +# comments) as a brief description. This used to be the default behaviour. +# The new default is to treat a multi-line C++ comment block as a detailed +# description. Set this tag to YES if you prefer the old behaviour instead. + +MULTILINE_CPP_IS_BRIEF = NO + +# If the INHERIT_DOCS tag is set to YES (the default) then an undocumented +# member inherits the documentation from any documented member that it +# re-implements. + +INHERIT_DOCS = NO + +# If the SEPARATE_MEMBER_PAGES tag is set to YES, then doxygen will produce +# a new page for each member. If set to NO, the documentation of a member will +# be part of the file/class/namespace that contains it. + +SEPARATE_MEMBER_PAGES = NO + +# The TAB_SIZE tag can be used to set the number of spaces in a tab. +# Doxygen uses this value to replace tabs by spaces in code fragments. + +TAB_SIZE = 4 + +# This tag can be used to specify a number of aliases that acts +# as commands in the documentation. An alias has the form "name=value". +# For example adding "sideeffect=\par Side Effects:\n" will allow you to +# put the command \sideeffect (or @sideeffect) in the documentation, which +# will result in a user-defined paragraph with heading "Side Effects:". +# You can put \n's in the value part of an alias to insert newlines. + +ALIASES = + +# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C +# sources only. Doxygen will then generate output that is more tailored for C. +# For instance, some of the names that are used will be different. The list +# of all members will be omitted, etc. + +OPTIMIZE_OUTPUT_FOR_C = NO + +# Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java +# sources only. Doxygen will then generate output that is more tailored for +# Java. For instance, namespaces will be presented as packages, qualified +# scopes will look different, etc. + +OPTIMIZE_OUTPUT_JAVA = NO + +# Set the OPTIMIZE_FOR_FORTRAN tag to YES if your project consists of Fortran +# sources only. Doxygen will then generate output that is more tailored for +# Fortran. + +OPTIMIZE_FOR_FORTRAN = NO + +# Set the OPTIMIZE_OUTPUT_VHDL tag to YES if your project consists of VHDL +# sources. Doxygen will then generate output that is tailored for +# VHDL. + +OPTIMIZE_OUTPUT_VHDL = NO + +# If you use STL classes (i.e. std::string, std::vector, etc.) but do not want +# to include (a tag file for) the STL sources as input, then you should +# set this tag to YES in order to let doxygen match functions declarations and +# definitions whose arguments contain STL classes (e.g. func(std::string); v.s. +# func(std::string) {}). This also make the inheritance and collaboration +# diagrams that involve STL classes more complete and accurate. + +BUILTIN_STL_SUPPORT = YES + +# If you use Microsoft's C++/CLI language, you should set this option to YES to +# enable parsing support. + +CPP_CLI_SUPPORT = NO + +# Set the SIP_SUPPORT tag to YES if your project consists of sip sources only. +# Doxygen will parse them like normal C++ but will assume all classes use public +# instead of private inheritance when no explicit protection keyword is present. + +SIP_SUPPORT = NO + +# For Microsoft's IDL there are propget and propput attributes to indicate getter +# and setter methods for a property. Setting this option to YES (the default) +# will make doxygen to replace the get and set methods by a property in the +# documentation. This will only work if the methods are indeed getting or +# setting a simple type. If this is not the case, or you want to show the +# methods anyway, you should set this option to NO. + +IDL_PROPERTY_SUPPORT = NO + +# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC +# tag is set to YES, then doxygen will reuse the documentation of the first +# member in the group (if any) for the other members of the group. By default +# all members of a group must be documented explicitly. + +DISTRIBUTE_GROUP_DOC = NO + +# Set the SUBGROUPING tag to YES (the default) to allow class member groups of +# the same type (for instance a group of public functions) to be put as a +# subgroup of that type (e.g. under the Public Functions section). Set it to +# NO to prevent subgrouping. Alternatively, this can be done per class using +# the \nosubgrouping command. + +SUBGROUPING = YES + +# When TYPEDEF_HIDES_STRUCT is enabled, a typedef of a struct, union, or enum +# is documented as struct, union, or enum with the name of the typedef. So +# typedef struct TypeS {} TypeT, will appear in the documentation as a struct +# with name TypeT. When disabled the typedef will appear as a member of a file, +# namespace, or class. And the struct will be named TypeS. This can typically +# be useful for C code in case the coding convention dictates that all compound +# types are typedef'ed and only the typedef is referenced, never the tag name. + +TYPEDEF_HIDES_STRUCT = NO + +#--------------------------------------------------------------------------- +# Build related configuration options +#--------------------------------------------------------------------------- + +# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in +# documentation are documented, even if no documentation was available. +# Private class members and static file members will be hidden unless +# the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES + +EXTRACT_ALL = NO + +# If the EXTRACT_PRIVATE tag is set to YES all private members of a class +# will be included in the documentation. + +EXTRACT_PRIVATE = YES + +# If the EXTRACT_STATIC tag is set to YES all static members of a file +# will be included in the documentation. + +EXTRACT_STATIC = YES + +# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) +# defined locally in source files will be included in the documentation. +# If set to NO only classes defined in header files are included. + +EXTRACT_LOCAL_CLASSES = NO + +# This flag is only useful for Objective-C code. When set to YES local +# methods, which are defined in the implementation section but not in +# the interface are included in the documentation. +# If set to NO (the default) only methods in the interface are included. + +EXTRACT_LOCAL_METHODS = NO + +# If this flag is set to YES, the members of anonymous namespaces will be +# extracted and appear in the documentation as a namespace called +# 'anonymous_namespace{file}', where file will be replaced with the base +# name of the file that contains the anonymous namespace. By default +# anonymous namespace are hidden. + +EXTRACT_ANON_NSPACES = NO + +# If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all +# undocumented members of documented classes, files or namespaces. +# If set to NO (the default) these members will be included in the +# various overviews, but no documentation section is generated. +# This option has no effect if EXTRACT_ALL is enabled. + +HIDE_UNDOC_MEMBERS = NO + +# If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all +# undocumented classes that are normally visible in the class hierarchy. +# If set to NO (the default) these classes will be included in the various +# overviews. This option has no effect if EXTRACT_ALL is enabled. + +HIDE_UNDOC_CLASSES = NO + +# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, Doxygen will hide all +# friend (class|struct|union) declarations. +# If set to NO (the default) these declarations will be included in the +# documentation. + +HIDE_FRIEND_COMPOUNDS = NO + +# If the HIDE_IN_BODY_DOCS tag is set to YES, Doxygen will hide any +# documentation blocks found inside the body of a function. +# If set to NO (the default) these blocks will be appended to the +# function's detailed documentation block. + +HIDE_IN_BODY_DOCS = NO + +# The INTERNAL_DOCS tag determines if documentation +# that is typed after a \internal command is included. If the tag is set +# to NO (the default) then the documentation will be excluded. +# Set it to YES to include the internal documentation. + +INTERNAL_DOCS = NO + +# If the CASE_SENSE_NAMES tag is set to NO then Doxygen will only generate +# file names in lower-case letters. If set to YES upper-case letters are also +# allowed. This is useful if you have classes or files whose names only differ +# in case and if your file system supports case sensitive file names. Windows +# and Mac users are advised to set this option to NO. + +CASE_SENSE_NAMES = YES + +# If the HIDE_SCOPE_NAMES tag is set to NO (the default) then Doxygen +# will show members with their full class and namespace scopes in the +# documentation. If set to YES the scope will be hidden. + +HIDE_SCOPE_NAMES = NO + +# If the SHOW_INCLUDE_FILES tag is set to YES (the default) then Doxygen +# will put a list of the files that are included by a file in the documentation +# of that file. + +SHOW_INCLUDE_FILES = YES + +# If the INLINE_INFO tag is set to YES (the default) then a tag [inline] +# is inserted in the documentation for inline members. + +INLINE_INFO = YES + +# If the SORT_MEMBER_DOCS tag is set to YES (the default) then doxygen +# will sort the (detailed) documentation of file and class members +# alphabetically by member name. If set to NO the members will appear in +# declaration order. + +SORT_MEMBER_DOCS = NO + +# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the +# brief documentation of file, namespace and class members alphabetically +# by member name. If set to NO (the default) the members will appear in +# declaration order. + +SORT_BRIEF_DOCS = NO + +# If the SORT_GROUP_NAMES tag is set to YES then doxygen will sort the +# hierarchy of group names into alphabetical order. If set to NO (the default) +# the group names will appear in their defined order. + +SORT_GROUP_NAMES = NO + +# If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be +# sorted by fully-qualified names, including namespaces. If set to +# NO (the default), the class list will be sorted only by class name, +# not including the namespace part. +# Note: This option is not very useful if HIDE_SCOPE_NAMES is set to YES. +# Note: This option applies only to the class list, not to the +# alphabetical list. + +SORT_BY_SCOPE_NAME = YES + +# The GENERATE_TODOLIST tag can be used to enable (YES) or +# disable (NO) the todo list. This list is created by putting \todo +# commands in the documentation. + +GENERATE_TODOLIST = YES + +# The GENERATE_TESTLIST tag can be used to enable (YES) or +# disable (NO) the test list. This list is created by putting \test +# commands in the documentation. + +GENERATE_TESTLIST = YES + +# The GENERATE_BUGLIST tag can be used to enable (YES) or +# disable (NO) the bug list. This list is created by putting \bug +# commands in the documentation. + +GENERATE_BUGLIST = YES + +# The GENERATE_DEPRECATEDLIST tag can be used to enable (YES) or +# disable (NO) the deprecated list. This list is created by putting +# \deprecated commands in the documentation. + +GENERATE_DEPRECATEDLIST= YES + +# The ENABLED_SECTIONS tag can be used to enable conditional +# documentation sections, marked by \if sectionname ... \endif. + +ENABLED_SECTIONS = + +# The MAX_INITIALIZER_LINES tag determines the maximum number of lines +# the initial value of a variable or define consists of for it to appear in +# the documentation. If the initializer consists of more lines than specified +# here it will be hidden. Use a value of 0 to hide initializers completely. +# The appearance of the initializer of individual variables and defines in the +# documentation can be controlled using \showinitializer or \hideinitializer +# command in the documentation regardless of this setting. + +MAX_INITIALIZER_LINES = 30 + +# Set the SHOW_USED_FILES tag to NO to disable the list of files generated +# at the bottom of the documentation of classes and structs. If set to YES the +# list will mention the files that were used to generate the documentation. + +SHOW_USED_FILES = YES + +# If the sources in your project are distributed over multiple directories +# then setting the SHOW_DIRECTORIES tag to YES will show the directory hierarchy +# in the documentation. The default is NO. +#SHOW_DIRECTORIES = YES + +# Set the SHOW_FILES tag to NO to disable the generation of the Files page. +# This will remove the Files entry from the Quick Index and from the +# Folder Tree View (if specified). The default is YES. + +SHOW_FILES = YES + +# Set the SHOW_NAMESPACES tag to NO to disable the generation of the +# Namespaces page. This will remove the Namespaces entry from the Quick Index +# and from the Folder Tree View (if specified). The default is YES. + +SHOW_NAMESPACES = YES + +# The FILE_VERSION_FILTER tag can be used to specify a program or script that +# doxygen should invoke to get the current version for each file (typically from +# the version control system). Doxygen will invoke the program by executing (via +# popen()) the command , where is the value of +# the FILE_VERSION_FILTER tag, and is the name of an input file +# provided by doxygen. Whatever the program writes to standard output +# is used as the file version. See the manual for examples. + +FILE_VERSION_FILTER = + +#--------------------------------------------------------------------------- +# configuration options related to warning and progress messages +#--------------------------------------------------------------------------- + +# The QUIET tag can be used to turn on/off the messages that are generated +# by doxygen. Possible values are YES and NO. If left blank NO is used. + +QUIET = YES + +# The WARNINGS tag can be used to turn on/off the warning messages that are +# generated by doxygen. Possible values are YES and NO. If left blank +# NO is used. + +WARNINGS = YES + +# If WARN_IF_UNDOCUMENTED is set to YES, then doxygen will generate warnings +# for undocumented members. If EXTRACT_ALL is set to YES then this flag will +# automatically be disabled. + +WARN_IF_UNDOCUMENTED = YES + +# If WARN_IF_DOC_ERROR is set to YES, doxygen will generate warnings for +# potential errors in the documentation, such as not documenting some +# parameters in a documented function, or documenting parameters that +# don't exist or using markup commands wrongly. + +WARN_IF_DOC_ERROR = YES + +# This WARN_NO_PARAMDOC option can be abled to get warnings for +# functions that are documented, but have no documentation for their parameters +# or return value. If set to NO (the default) doxygen will only warn about +# wrong or incomplete parameter documentation, but not about the absence of +# documentation. + +WARN_NO_PARAMDOC = YES + +# The WARN_FORMAT tag determines the format of the warning messages that +# doxygen can produce. The string should contain the $file, $line, and $text +# tags, which will be replaced by the file and line number from which the +# warning originated and the warning text. Optionally the format may contain +# $version, which will be replaced by the version of the file (if it could +# be obtained via FILE_VERSION_FILTER) + +WARN_FORMAT = "$file:$line: $text" + +# The WARN_LOGFILE tag can be used to specify a file to which warning +# and error messages should be written. If left blank the output is written +# to stderr. + +WARN_LOGFILE = ${CMAKE_CURRENT_BINARY_DIR}/hyperion-doxygen.log + +#--------------------------------------------------------------------------- +# configuration options related to the input files +#--------------------------------------------------------------------------- + +# The INPUT tag can be used to specify the files and/or directories that contain +# documented source files. You may enter file names like "myfile.cpp" or +# directories like "/usr/src/myproject". Separate the files or directories +# with spaces. + +INPUT = "${CMAKE_SOURCE_DIR}/include" \ + "${CMAKE_SOURCE_DIR}/libsrc" \ + "${CMAKE_SOURCE_DIR}/src" \ + "${CMAKE_SOURCE_DIR}/test" + +# This tag can be used to specify the character encoding of the source files +# that doxygen parses. Internally doxygen uses the UTF-8 encoding, which is +# also the default input encoding. Doxygen uses libiconv (or the iconv built +# into libc) for the transcoding. See http://www.gnu.org/software/libiconv for +# the list of possible encodings. + +INPUT_ENCODING = UTF-8 + +# If the value of the INPUT tag contains directories, you can use the +# FILE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp +# and *.h) to filter out the source-files in the directories. If left +# blank the following patterns are tested: +# *.c *.cc *.cxx *.cpp *.c++ *.java *.ii *.ixx *.ipp *.i++ *.inl *.h *.hh *.hxx +# *.hpp *.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm *.py *.f90 + +FILE_PATTERNS = *.h + +# The RECURSIVE tag can be used to turn specify whether or not subdirectories +# should be searched for input files as well. Possible values are YES and NO. +# If left blank NO is used. + +RECURSIVE = YES + +# The EXCLUDE tag can be used to specify files and/or directories that should +# excluded from the INPUT source files. This way you can easily exclude a +# subdirectory from a directory tree whose root is specified with the INPUT tag. + +EXCLUDE = + +# The EXCLUDE_SYMLINKS tag can be used select whether or not files or +# directories that are symbolic links (a Unix filesystem feature) are excluded +# from the input. + +EXCLUDE_SYMLINKS = NO + +# If the value of the INPUT tag contains directories, you can use the +# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude +# certain files from those directories. Note that the wildcards are matched +# against the file with absolute path, so to exclude all test directories +# for example use the pattern */test/* + +EXCLUDE_PATTERNS = */.git/* \ + */*build/* + +# The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names +# (namespaces, classes, functions, etc.) that should be excluded from the +# output. The symbol name can be a fully qualified name, a word, or if the +# wildcard * is used, a substring. Examples: ANamespace, AClass, +# AClass::ANamespace, ANamespace::*Test + +EXCLUDE_SYMBOLS = + +# The EXAMPLE_PATH tag can be used to specify one or more files or +# directories that contain example code fragments that are included (see +# the \include command). + +EXAMPLE_PATH = + +# If the value of the EXAMPLE_PATH tag contains directories, you can use the +# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp +# and *.h) to filter out the source-files in the directories. If left +# blank all files are included. + +EXAMPLE_PATTERNS = + +# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be +# searched for input files to be used with the \include or \dontinclude +# commands irrespective of the value of the RECURSIVE tag. +# Possible values are YES and NO. If left blank NO is used. + +EXAMPLE_RECURSIVE = NO + +# The IMAGE_PATH tag can be used to specify one or more files or +# directories that contain image that are included in the documentation (see +# the \image command). + +IMAGE_PATH = + +# The INPUT_FILTER tag can be used to specify a program that doxygen should +# invoke to filter for each input file. Doxygen will invoke the filter program +# by executing (via popen()) the command , where +# is the value of the INPUT_FILTER tag, and is the name of an +# input file. Doxygen will then use the output that the filter program writes +# to standard output. If FILTER_PATTERNS is specified, this tag will be +# ignored. + +INPUT_FILTER = + +# The FILTER_PATTERNS tag can be used to specify filters on a per file pattern +# basis. Doxygen will compare the file name with each pattern and apply the +# filter if there is a match. The filters are a list of the form: +# pattern=filter (like *.cpp=my_cpp_filter). See INPUT_FILTER for further +# info on how filters are used. If FILTER_PATTERNS is empty, INPUT_FILTER +# is applied to all files. + +FILTER_PATTERNS = + +# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using +# INPUT_FILTER) will be used to filter the input files when producing source +# files to browse (i.e. when SOURCE_BROWSER is set to YES). + +FILTER_SOURCE_FILES = NO + +#--------------------------------------------------------------------------- +# configuration options related to source browsing +#--------------------------------------------------------------------------- + +# If the SOURCE_BROWSER tag is set to YES then a list of source files will +# be generated. Documented entities will be cross-referenced with these sources. +# Note: To get rid of all source code in the generated output, make sure also +# VERBATIM_HEADERS is set to NO. + +SOURCE_BROWSER = YES + +# Setting the INLINE_SOURCES tag to YES will include the body +# of functions and classes directly in the documentation. + +INLINE_SOURCES = NO + +# Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct +# doxygen to hide any special comment blocks from generated source code +# fragments. Normal C and C++ comments will always remain visible. + +STRIP_CODE_COMMENTS = YES + +# If the REFERENCED_BY_RELATION tag is set to YES +# then for each documented function all documented +# functions referencing it will be listed. + +REFERENCED_BY_RELATION = NO + +# If the REFERENCES_RELATION tag is set to YES +# then for each documented function all documented entities +# called/used by that function will be listed. + +REFERENCES_RELATION = NO + +# If the REFERENCES_LINK_SOURCE tag is set to YES (the default) +# and SOURCE_BROWSER tag is set to YES, then the hyperlinks from +# functions in REFERENCES_RELATION and REFERENCED_BY_RELATION lists will +# link to the source code. Otherwise they will link to the documentstion. + +REFERENCES_LINK_SOURCE = YES + +# If the USE_HTAGS tag is set to YES then the references to source code +# will point to the HTML generated by the htags(1) tool instead of doxygen +# built-in source browser. The htags tool is part of GNU's global source +# tagging system (see http://www.gnu.org/software/global/global.html). You +# will need version 4.8.6 or higher. + +USE_HTAGS = NO + +# If the VERBATIM_HEADERS tag is set to YES (the default) then Doxygen +# will generate a verbatim copy of the header file for each class for +# which an include is specified. Set to NO to disable this. + +VERBATIM_HEADERS = YES + +#--------------------------------------------------------------------------- +# configuration options related to the alphabetical class index +#--------------------------------------------------------------------------- + +# If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index +# of all compounds will be generated. Enable this if the project +# contains a lot of classes, structs, unions or interfaces. + +ALPHABETICAL_INDEX = YES + +# If the alphabetical index is enabled (see ALPHABETICAL_INDEX) then +# the COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns +# in which this list will be split (can be a number in the range [1..20]) + +COLS_IN_ALPHA_INDEX = 2 + +# In case all classes in a project start with a common prefix, all +# classes will be put under the same header in the alphabetical index. +# The IGNORE_PREFIX tag can be used to specify one or more prefixes that +# should be ignored while generating the index headers. + +IGNORE_PREFIX = + +#--------------------------------------------------------------------------- +# configuration options related to the HTML output +#--------------------------------------------------------------------------- + +# If the GENERATE_HTML tag is set to YES (the default) Doxygen will +# generate HTML output. + +GENERATE_HTML = YES + +# The HTML_OUTPUT tag is used to specify where the HTML docs will be put. +# If a relative path is entered the value of OUTPUT_DIRECTORY will be +# put in front of it. If left blank `html' will be used as the default path. + +HTML_OUTPUT = html + +# The HTML_FILE_EXTENSION tag can be used to specify the file extension for +# each generated HTML page (for example: .htm,.php,.asp). If it is left blank +# doxygen will generate files with .html extension. + +HTML_FILE_EXTENSION = .html + +# The HTML_HEADER tag can be used to specify a personal HTML header for +# each generated HTML page. If it is left blank doxygen will generate a +# standard header. + +HTML_HEADER = "html/hyperion-header.html" + +# The HTML_FOOTER tag can be used to specify a personal HTML footer for +# each generated HTML page. If it is left blank doxygen will generate a +# standard footer. + +HTML_FOOTER = "html/hyperion-footer.html" + +# The HTML_STYLESHEET tag can be used to specify a user-defined cascading +# style sheet that is used by each HTML page. It can be used to +# fine-tune the look of the HTML output. If the tag is left blank doxygen +# will generate a default style sheet. Note that doxygen will try to copy +# the style sheet file to the HTML output directory, so don't put your own +# stylesheet in the HTML output directory as well, or it will be erased! + +#HTML_STYLESHEET = "html/hyperion-stylesheet.css" + +# If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes, +# files or namespaces will be aligned in HTML using tables. If set to +# NO a bullet list will be used. + +#HTML_ALIGN_MEMBERS = YES + +# If the GENERATE_HTMLHELP tag is set to YES, additional index files +# will be generated that can be used as input for tools like the +# Microsoft HTML help workshop to generate a compiled HTML help file (.chm) +# of the generated HTML documentation. + +GENERATE_HTMLHELP = NO + +# If the GENERATE_DOCSET tag is set to YES, additional index files +# will be generated that can be used as input for Apple's Xcode 3 +# integrated development environment, introduced with OSX 10.5 (Leopard). +# To create a documentation set, doxygen will generate a Makefile in the +# HTML output directory. Running make will produce the docset in that +# directory and running "make install" will install the docset in +# ~/Library/Developer/Shared/Documentation/DocSets so that Xcode will find +# it at startup. + +GENERATE_DOCSET = NO + +# When GENERATE_DOCSET tag is set to YES, this tag determines the name of the +# feed. A documentation feed provides an umbrella under which multiple +# documentation sets from a single provider (such as a company or product suite) +# can be grouped. + +DOCSET_FEEDNAME = "Doxygen generated docs" + +# When GENERATE_DOCSET tag is set to YES, this tag specifies a string that +# should uniquely identify the documentation set bundle. This should be a +# reverse domain-name style string, e.g. com.mycompany.MyDocSet. Doxygen +# will append .docset to the name. + +DOCSET_BUNDLE_ID = org.doxygen.Project + +# If the HTML_DYNAMIC_SECTIONS tag is set to YES then the generated HTML +# documentation will contain sections that can be hidden and shown after the +# page has loaded. For this to work a browser that supports +# JavaScript and DHTML is required (for instance Mozilla 1.0+, Firefox +# Netscape 6.0+, Internet explorer 5.0+, Konqueror, or Safari). + +HTML_DYNAMIC_SECTIONS = YES + +# If the GENERATE_HTMLHELP tag is set to YES, the CHM_FILE tag can +# be used to specify the file name of the resulting .chm file. You +# can add a path in front of the file if the result should not be +# written to the html output directory. + +CHM_FILE = + +# If the GENERATE_HTMLHELP tag is set to YES, the HHC_LOCATION tag can +# be used to specify the location (absolute path including file name) of +# the HTML help compiler (hhc.exe). If non-empty doxygen will try to run +# the HTML help compiler on the generated index.hhp. + +HHC_LOCATION = + +# If the GENERATE_HTMLHELP tag is set to YES, the GENERATE_CHI flag +# controls if a separate .chi index file is generated (YES) or that +# it should be included in the master .chm file (NO). + +GENERATE_CHI = NO + +# If the GENERATE_HTMLHELP tag is set to YES, the CHM_INDEX_ENCODING +# is used to encode HtmlHelp index (hhk), content (hhc) and project file +# content. + +CHM_INDEX_ENCODING = + +# If the GENERATE_HTMLHELP tag is set to YES, the BINARY_TOC flag +# controls whether a binary table of contents is generated (YES) or a +# normal table of contents (NO) in the .chm file. + +BINARY_TOC = NO + +# The TOC_EXPAND flag can be set to YES to add extra items for group members +# to the contents of the HTML help documentation and to the tree view. + +TOC_EXPAND = NO + +# The DISABLE_INDEX tag can be used to turn on/off the condensed index at +# top of each HTML page. The value NO (the default) enables the index and +# the value YES disables it. + +DISABLE_INDEX = NO + +# This tag can be used to set the number of enum values (range [1..20]) +# that doxygen will group on one line in the generated HTML documentation. + +ENUM_VALUES_PER_LINE = 4 + +# The GENERATE_TREEVIEW tag is used to specify whether a tree-like index +# structure should be generated to display hierarchical information. +# If the tag value is set to FRAME, a side panel will be generated +# containing a tree-like index structure (just like the one that +# is generated for HTML Help). For this to work a browser that supports +# JavaScript, DHTML, CSS and frames is required (for instance Mozilla 1.0+, +# Netscape 6.0+, Internet explorer 5.0+, or Konqueror). Windows users are +# probably better off using the HTML help feature. Other possible values +# for this tag are: HIERARCHIES, which will generate the Groups, Directories, +# and Class Hiererachy pages using a tree view instead of an ordered list; +# ALL, which combines the behavior of FRAME and HIERARCHIES; and NONE, which +# disables this behavior completely. For backwards compatibility with previous +# releases of Doxygen, the values YES and NO are equivalent to FRAME and NONE +# respectively. + +GENERATE_TREEVIEW = YES + +# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be +# used to set the initial width (in pixels) of the frame in which the tree +# is shown. + +TREEVIEW_WIDTH = 250 + +# Use this tag to change the font size of Latex formulas included +# as images in the HTML documentation. The default is 10. Note that +# when you change the font size after a successful doxygen run you need +# to manually remove any form_*.png images from the HTML output directory +# to force them to be regenerated. + +FORMULA_FONTSIZE = 10 + +#--------------------------------------------------------------------------- +# configuration options related to the LaTeX output +#--------------------------------------------------------------------------- + +# If the GENERATE_LATEX tag is set to YES (the default) Doxygen will +# generate Latex output. + +GENERATE_LATEX = NO + +# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. +# If a relative path is entered the value of OUTPUT_DIRECTORY will be +# put in front of it. If left blank `latex' will be used as the default path. + +LATEX_OUTPUT = latex + +# The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be +# invoked. If left blank `latex' will be used as the default command name. + +LATEX_CMD_NAME = pdflatex + +# The MAKEINDEX_CMD_NAME tag can be used to specify the command name to +# generate index for LaTeX. If left blank `makeindex' will be used as the +# default command name. + +MAKEINDEX_CMD_NAME = makeindex + +# If the COMPACT_LATEX tag is set to YES Doxygen generates more compact +# LaTeX documents. This may be useful for small projects and may help to +# save some trees in general. + +COMPACT_LATEX = NO + +# The PAPER_TYPE tag can be used to set the paper type that is used +# by the printer. Possible values are: a4, a4wide, letter, legal and +# executive. If left blank a4wide will be used. + +PAPER_TYPE = a4wide + +# The EXTRA_PACKAGES tag can be to specify one or more names of LaTeX +# packages that should be included in the LaTeX output. + +EXTRA_PACKAGES = + +# The LATEX_HEADER tag can be used to specify a personal LaTeX header for +# the generated latex document. The header should contain everything until +# the first chapter. If it is left blank doxygen will generate a +# standard header. Notice: only use this tag if you know what you are doing! + +LATEX_HEADER = + +# If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated +# is prepared for conversion to pdf (using ps2pdf). The pdf file will +# contain links (just like the HTML output) instead of page references +# This makes the output suitable for online browsing using a pdf viewer. + +PDF_HYPERLINKS = YES + +# If the USE_PDFLATEX tag is set to YES, pdflatex will be used instead of +# plain latex in the generated Makefile. Set this option to YES to get a +# higher quality PDF documentation. + +USE_PDFLATEX = YES + +# If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \\batchmode. +# command to the generated LaTeX files. This will instruct LaTeX to keep +# running if errors occur, instead of asking the user for help. +# This option is also used when generating formulas in HTML. + +LATEX_BATCHMODE = NO + +# If LATEX_HIDE_INDICES is set to YES then doxygen will not +# include the index chapters (such as File Index, Compound Index, etc.) +# in the output. + +LATEX_HIDE_INDICES = NO + +#--------------------------------------------------------------------------- +# configuration options related to the RTF output +#--------------------------------------------------------------------------- + +# If the GENERATE_RTF tag is set to YES Doxygen will generate RTF output +# The RTF output is optimized for Word 97 and may not look very pretty with +# other RTF readers or editors. + +GENERATE_RTF = NO + +# The RTF_OUTPUT tag is used to specify where the RTF docs will be put. +# If a relative path is entered the value of OUTPUT_DIRECTORY will be +# put in front of it. If left blank `rtf' will be used as the default path. + +RTF_OUTPUT = rtf + +# If the COMPACT_RTF tag is set to YES Doxygen generates more compact +# RTF documents. This may be useful for small projects and may help to +# save some trees in general. + +COMPACT_RTF = NO + +# If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated +# will contain hyperlink fields. The RTF file will +# contain links (just like the HTML output) instead of page references. +# This makes the output suitable for online browsing using WORD or other +# programs which support those fields. +# Note: wordpad (write) and others do not support links. + +RTF_HYPERLINKS = NO + +# Load stylesheet definitions from file. Syntax is similar to doxygen's +# config file, i.e. a series of assignments. You only have to provide +# replacements, missing definitions are set to their default value. + +RTF_STYLESHEET_FILE = + +# Set optional variables used in the generation of an rtf document. +# Syntax is similar to doxygen's config file. + +RTF_EXTENSIONS_FILE = + +#--------------------------------------------------------------------------- +# configuration options related to the man page output +#--------------------------------------------------------------------------- + +# If the GENERATE_MAN tag is set to YES (the default) Doxygen will +# generate man pages + +GENERATE_MAN = NO + +# The MAN_OUTPUT tag is used to specify where the man pages will be put. +# If a relative path is entered the value of OUTPUT_DIRECTORY will be +# put in front of it. If left blank `man' will be used as the default path. + +MAN_OUTPUT = man + +# The MAN_EXTENSION tag determines the extension that is added to +# the generated man pages (default is the subroutine's section .3) + +MAN_EXTENSION = .3 + +# If the MAN_LINKS tag is set to YES and Doxygen generates man output, +# then it will generate one additional man file for each entity +# documented in the real man page(s). These additional files +# only source the real man page, but without them the man command +# would be unable to find the correct page. The default is NO. + +MAN_LINKS = NO + +#--------------------------------------------------------------------------- +# configuration options related to the XML output +#--------------------------------------------------------------------------- + +# If the GENERATE_XML tag is set to YES Doxygen will +# generate an XML file that captures the structure of +# the code including all documentation. + +GENERATE_XML = NO + +# The XML_OUTPUT tag is used to specify where the XML pages will be put. +# If a relative path is entered the value of OUTPUT_DIRECTORY will be +# put in front of it. If left blank `xml' will be used as the default path. + +XML_OUTPUT = xml + +# The XML_SCHEMA tag can be used to specify an XML schema, +# which can be used by a validating XML parser to check the +# syntax of the XML files. + +XML_SCHEMA = + +# The XML_DTD tag can be used to specify an XML DTD, +# which can be used by a validating XML parser to check the +# syntax of the XML files. + +XML_DTD = + +# If the XML_PROGRAMLISTING tag is set to YES Doxygen will +# dump the program listings (including syntax highlighting +# and cross-referencing information) to the XML output. Note that +# enabling this will significantly increase the size of the XML output. + +XML_PROGRAMLISTING = YES + +#--------------------------------------------------------------------------- +# configuration options for the AutoGen Definitions output +#--------------------------------------------------------------------------- + +# If the GENERATE_AUTOGEN_DEF tag is set to YES Doxygen will +# generate an AutoGen Definitions (see autogen.sf.net) file +# that captures the structure of the code including all +# documentation. Note that this feature is still experimental +# and incomplete at the moment. + +GENERATE_AUTOGEN_DEF = NO + +#--------------------------------------------------------------------------- +# configuration options related to the Perl module output +#--------------------------------------------------------------------------- + +# If the GENERATE_PERLMOD tag is set to YES Doxygen will +# generate a Perl module file that captures the structure of +# the code including all documentation. Note that this +# feature is still experimental and incomplete at the +# moment. + +GENERATE_PERLMOD = NO + +# If the PERLMOD_LATEX tag is set to YES Doxygen will generate +# the necessary Makefile rules, Perl scripts and LaTeX code to be able +# to generate PDF and DVI output from the Perl module output. + +PERLMOD_LATEX = NO + +# If the PERLMOD_PRETTY tag is set to YES the Perl module output will be +# nicely formatted so it can be parsed by a human reader. This is useful +# if you want to understand what is going on. On the other hand, if this +# tag is set to NO the size of the Perl module output will be much smaller +# and Perl will parse it just the same. + +PERLMOD_PRETTY = YES + +# The names of the make variables in the generated doxyrules.make file +# are prefixed with the string contained in PERLMOD_MAKEVAR_PREFIX. +# This is useful so different doxyrules.make files included by the same +# Makefile don't overwrite each other's variables. + +PERLMOD_MAKEVAR_PREFIX = + +#--------------------------------------------------------------------------- +# Configuration options related to the preprocessor +#--------------------------------------------------------------------------- + +# If the ENABLE_PREPROCESSING tag is set to YES (the default) Doxygen will +# evaluate all C-preprocessor directives found in the sources and include +# files. + +ENABLE_PREPROCESSING = YES + +# If the MACRO_EXPANSION tag is set to YES Doxygen will expand all macro +# names in the source code. If set to NO (the default) only conditional +# compilation will be performed. Macro expansion can be done in a controlled +# way by setting EXPAND_ONLY_PREDEF to YES. + +MACRO_EXPANSION = NO + +# If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES +# then the macro expansion is limited to the macros specified with the +# PREDEFINED and EXPAND_AS_DEFINED tags. + +EXPAND_ONLY_PREDEF = NO + +# If the SEARCH_INCLUDES tag is set to YES (the default) the includes files +# in the INCLUDE_PATH (see below) will be search if a #include is found. + +SEARCH_INCLUDES = YES + +# The INCLUDE_PATH tag can be used to specify one or more directories that +# contain include files that are not input files but should be processed by +# the preprocessor. + +INCLUDE_PATH = + +# You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard +# patterns (like *.h and *.hpp) to filter out the header-files in the +# directories. If left blank, the patterns specified with FILE_PATTERNS will +# be used. + +INCLUDE_FILE_PATTERNS = + +# The PREDEFINED tag can be used to specify one or more macro names that +# are defined before the preprocessor is started (similar to the -D option of +# gcc). The argument of the tag is a list of macros of the form: name +# or name=definition (no spaces). If the definition and the = are +# omitted =1 is assumed. To prevent a macro definition from being +# undefined via #undef or recursively expanded use the := operator +# instead of the = operator. + +PREDEFINED = DOXYGEN_SHOULD_SKIP_THIS + +# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then +# this tag can be used to specify a list of macro names that should be expanded. +# The macro definition that is found in the sources will be used. +# Use the PREDEFINED tag if you want to use a different macro definition. + +EXPAND_AS_DEFINED = + +# If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then +# doxygen's preprocessor will remove all function-like macros that are alone +# on a line, have an all uppercase name, and do not end with a semicolon. Such +# function macros are typically used for boiler-plate code, and will confuse +# the parser if not removed. + +SKIP_FUNCTION_MACROS = YES + +#--------------------------------------------------------------------------- +# Configuration::additions related to external references +#--------------------------------------------------------------------------- + +# The TAGFILES option can be used to specify one or more tagfiles. +# Optionally an initial location of the external documentation +# can be added for each tagfile. The format of a tag file without +# this location is as follows: +# TAGFILES = file1 file2 ... +# Adding location for the tag files is done as follows: +# TAGFILES = file1=loc1 "file2 = loc2" ... +# where "loc1" and "loc2" can be relative or absolute paths or +# URLs. If a location is present for each tag, the installdox tool +# does not have to be run to correct the links. +# Note that each tag file must have a unique name +# (where the name does NOT include the path) +# If a tag file is not located in the directory in which doxygen +# is run, you must also specify the path to the tagfile here. + +TAGFILES = + +# When a file name is specified after GENERATE_TAGFILE, doxygen will create +# a tag file that is based on the input files it reads. + +GENERATE_TAGFILE = + +# If the ALLEXTERNALS tag is set to YES all external classes will be listed +# in the class index. If set to NO only the inherited external classes +# will be listed. + +ALLEXTERNALS = NO + +# If the EXTERNAL_GROUPS tag is set to YES all external groups will be listed +# in the modules index. If set to NO, only the current project's groups will +# be listed. + +EXTERNAL_GROUPS = YES + +# The PERL_PATH should be the absolute path and name of the perl script +# interpreter (i.e. the result of `which perl'). + +PERL_PATH = /usr/bin/perl + +#--------------------------------------------------------------------------- +# Configuration options related to the dot tool +#--------------------------------------------------------------------------- + +# If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will +# generate a inheritance diagram (in HTML, RTF and LaTeX) for classes with base +# or super classes. Setting the tag to NO turns the diagrams off. Note that +# this option is superseded by the HAVE_DOT option below. This is only a +# fallback. It is recommended to install and use dot, since it yields more +# powerful graphs. + +CLASS_DIAGRAMS = YES + +# You can define message sequence charts within doxygen comments using the \msc +# command. Doxygen will then run the mscgen tool (see +# http://www.mcternan.me.uk/mscgen/) to produce the chart and insert it in the +# documentation. The MSCGEN_PATH tag allows you to specify the directory where +# the mscgen tool resides. If left empty the tool is assumed to be found in the +# default search path. + +MSCGEN_PATH = + +# If set to YES, the inheritance and collaboration graphs will hide +# inheritance and usage relations if the target is undocumented +# or is not a class. + +HIDE_UNDOC_RELATIONS = YES + +# If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is +# available from the path. This tool is part of Graphviz, a graph visualization +# toolkit from AT&T and Lucent Bell Labs. The other options in this section +# have no effect if this option is set to NO (the default) + +HAVE_DOT = YES + +# The DOT_NUM_THREADS specifies the number of dot invocations doxygen is allowed +# to run in parallel. When set to 0 (the default) doxygen will base this on the +# number of processors available in the system. You can set it explicitly to a +# value larger than 0 to get control over the balance between CPU load and +# processing speed. + +DOT_NUM_THREADS = 0 + +# By default doxygen will write a font called FreeSans.ttf to the output +# directory and reference it in all dot files that doxygen generates. This +# font does not include all possible unicode characters however, so when you need +# these (or just want a differently looking font) you can specify the font name +# using DOT_FONTNAME. You need need to make sure dot is able to find the font, +# which can be done by putting it in a standard location or by setting the +# DOTFONTPATH environment variable or by setting DOT_FONTPATH to the directory +# containing the font. + +DOT_FONTNAME = FreeSans + +# By default doxygen will tell dot to use the output directory to look for the +# FreeSans.ttf font (which doxygen will put there itself). If you specify a +# different font using DOT_FONTNAME you can set the path where dot +# can find it using this tag. + +DOT_FONTPATH = + +# If the CLASS_GRAPH and HAVE_DOT tags are set to YES then doxygen +# will generate a graph for each documented class showing the direct and +# indirect inheritance relations. Setting this tag to YES will force the +# the CLASS_DIAGRAMS tag to NO. + +CLASS_GRAPH = YES + +# If the COLLABORATION_GRAPH and HAVE_DOT tags are set to YES then doxygen +# will generate a graph for each documented class showing the direct and +# indirect implementation dependencies (inheritance, containment, and +# class references variables) of the class with other documented classes. + +COLLABORATION_GRAPH = YES + +# If the GROUP_GRAPHS and HAVE_DOT tags are set to YES then doxygen +# will generate a graph for groups, showing the direct groups dependencies + +GROUP_GRAPHS = YES + +# If the UML_LOOK tag is set to YES doxygen will generate inheritance and +# collaboration diagrams in a style similar to the OMG's Unified Modeling +# Language. + +UML_LOOK = YES + +# If set to YES, the inheritance and collaboration graphs will show the +# relations between templates and their instances. + +TEMPLATE_RELATIONS = YES + +# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDE_GRAPH, and HAVE_DOT +# tags are set to YES then doxygen will generate a graph for each documented +# file showing the direct and indirect include dependencies of the file with +# other documented files. + +INCLUDE_GRAPH = YES + +# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDED_BY_GRAPH, and +# HAVE_DOT tags are set to YES then doxygen will generate a graph for each +# documented header file showing the documented files that directly or +# indirectly include this file. + +INCLUDED_BY_GRAPH = YES + +# If the CALL_GRAPH and HAVE_DOT options are set to YES then +# doxygen will generate a call dependency graph for every global function +# or class method. Note that enabling this option will significantly increase +# the time of a run. So in most cases it will be better to enable call graphs +# for selected functions only using the \callgraph command. + +CALL_GRAPH = NO + +# If the CALLER_GRAPH and HAVE_DOT tags are set to YES then +# doxygen will generate a caller dependency graph for every global function +# or class method. Note that enabling this option will significantly increase +# the time of a run. So in most cases it will be better to enable caller +# graphs for selected functions only using the \callergraph command. + +CALLER_GRAPH = NO + +# If the GRAPHICAL_HIERARCHY and HAVE_DOT tags are set to YES then doxygen +# will graphical hierarchy of all classes instead of a textual one. + +GRAPHICAL_HIERARCHY = YES + +# If the DIRECTORY_GRAPH, SHOW_DIRECTORIES and HAVE_DOT tags are set to YES +# then doxygen will show the dependencies a directory has on other directories +# in a graphical way. The dependency relations are determined by the #include +# relations between the files in the directories. + +DIRECTORY_GRAPH = YES + +# The DOT_IMAGE_FORMAT tag can be used to set the image format of the images +# generated by dot. Possible values are png, jpg, or gif +# If left blank png will be used. + +DOT_IMAGE_FORMAT = png + +# The tag DOT_PATH can be used to specify the path where the dot tool can be +# found. If left blank, it is assumed the dot tool can be found in the path. + +DOT_PATH = "${DOXYGEN_DOT_PATH}" + +# The DOTFILE_DIRS tag can be used to specify one or more directories that +# contain dot files that are included in the documentation (see the +# \dotfile command). + +DOTFILE_DIRS = + +# The DOT_GRAPH_MAX_NODES tag can be used to set the maximum number of +# nodes that will be shown in the graph. If the number of nodes in a graph +# becomes larger than this value, doxygen will truncate the graph, which is +# visualized by representing a node as a red box. Note that doxygen if the +# number of direct children of the root node in a graph is already larger than +# DOT_GRAPH_MAX_NODES then the graph will not be shown at all. Also note +# that the size of a graph can be further restricted by MAX_DOT_GRAPH_DEPTH. + +DOT_GRAPH_MAX_NODES = 60 + +# The MAX_DOT_GRAPH_DEPTH tag can be used to set the maximum depth of the +# graphs generated by dot. A depth value of 3 means that only nodes reachable +# from the root by following a path via at most 3 edges will be shown. Nodes +# that lay further from the root node will be omitted. Note that setting this +# option to 1 or 2 may greatly reduce the computation time needed for large +# code bases. Also note that the size of a graph can be further restricted by +# DOT_GRAPH_MAX_NODES. Using a depth of 0 means no depth restriction. + +MAX_DOT_GRAPH_DEPTH = 0 + +# Set the DOT_TRANSPARENT tag to YES to generate images with a transparent +# background. This is enabled by default, which results in a transparent +# background. Warning: Depending on the platform used, enabling this option +# may lead to badly anti-aliased labels on the edges of a graph (i.e. they +# become hard to read). + +DOT_TRANSPARENT = YES + +# Set the DOT_MULTI_TARGETS tag to YES allow dot to generate multiple output +# files in one run (i.e. multiple -o and -T options on the command line). This +# makes dot run faster, but since only newer versions of dot (>1.8.10) +# support this, this feature is disabled by default. + +DOT_MULTI_TARGETS = NO + +# If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will +# generate a legend page explaining the meaning of the various boxes and +# arrows in the dot generated graphs. + +GENERATE_LEGEND = YES + +# If the DOT_CLEANUP tag is set to YES (the default) Doxygen will +# remove the intermediate dot files that are used to generate +# the various graphs. + +DOT_CLEANUP = YES + +#--------------------------------------------------------------------------- +# Configuration::additions related to the search engine +#--------------------------------------------------------------------------- + +# The SEARCHENGINE tag specifies whether or not a search engine should be +# used. If set to NO the values of all tags below this one will be ignored. + +SEARCHENGINE = ${DOXYGEN_SEARCHENGINE} From ecdd7775c5bd0c0c8546567b5d733b10398eb279 Mon Sep 17 00:00:00 2001 From: "T. van der Zwan" Date: Mon, 9 Sep 2013 20:35:28 +0000 Subject: [PATCH 08/12] Fixed doxygen warnings --- include/hyperion/ImageProcessor.h | 1 + include/hyperion/LedDevice.h | 18 +-- include/hyperion/LedString.h | 4 +- include/jsonserver/JsonServer.h | 2 +- include/utils/HsvTransform.h | 30 ++++- include/utils/jsonschema/JsonSchemaChecker.h | 116 +++++++++++++++++- libsrc/hyperion/ImageToLedsMap.h | 4 + libsrc/jsonserver/JsonClientConnection.h | 2 - libsrc/utils/jsonschema/JsonSchemaChecker.cpp | 2 +- src/hyperion-remote/ColorTransformValues.h | 3 + src/hyperion-remote/CustomParameter.h | 9 ++ src/hyperion-remote/JsonConnection.h | 1 + src/viewpng/CMakeLists.txt | 1 + src/viewpng/FbWriter.h | 47 ++++--- 14 files changed, 205 insertions(+), 35 deletions(-) diff --git a/include/hyperion/ImageProcessor.h b/include/hyperion/ImageProcessor.h index 642d0297..4a64bbff 100644 --- a/include/hyperion/ImageProcessor.h +++ b/include/hyperion/ImageProcessor.h @@ -47,6 +47,7 @@ public: /// /// Determines the led colors of the image in the buffer. /// + /// @param[in] image The image to translate to led values /// @param[out] ledColors The color value per led /// void process(const RgbImage& image, std::vector& ledColors); diff --git a/include/hyperion/LedDevice.h b/include/hyperion/LedDevice.h index 7c1dc6a6..083d113b 100644 --- a/include/hyperion/LedDevice.h +++ b/include/hyperion/LedDevice.h @@ -13,18 +13,20 @@ class LedDevice { public: - /** - * Empty virtual destructor for pure virtual base class - */ + /// + /// Empty virtual destructor for pure virtual base class + /// virtual ~LedDevice() { // empty } - /** - * Writes the RGB-Color values to the leds. - * - * @param[in] ledValues The RGB-color per led - */ + /// + /// Writes the RGB-Color values to the leds. + /// + /// @param[in] ledValues The RGB-color per led + /// + /// @return Zero on success else negative + /// virtual int write(const std::vector& ledValues) = 0; }; diff --git a/include/hyperion/LedString.h b/include/hyperion/LedString.h index e5963440..3f7103e0 100644 --- a/include/hyperion/LedString.h +++ b/include/hyperion/LedString.h @@ -15,7 +15,7 @@ namespace Json { class Value; } /// /// The Led structure contains the definition of the image portion used to determine a single led's /// color. -///
+/// @verbatim
 /// |--------------------image--|
 /// | minX  maxX                |
 /// |  |-----|minY              |
@@ -25,7 +25,7 @@ namespace Json { class Value; }
 /// |                           |
 /// |                           |
 /// |---------------------------|
-/// 
+/// @endverbatim
 ///
 struct Led
 {
diff --git a/include/jsonserver/JsonServer.h b/include/jsonserver/JsonServer.h
index 67609fe3..1ae95854 100644
--- a/include/jsonserver/JsonServer.h
+++ b/include/jsonserver/JsonServer.h
@@ -43,7 +43,7 @@ private slots:
 
 	///
 	/// Slot which is called when a client closes a connection
-	/// @param The Connection object which is being closed
+	/// @param connection The Connection object which is being closed
 	///
 	void closedConnection(JsonClientConnection * connection);
 
diff --git a/include/utils/HsvTransform.h b/include/utils/HsvTransform.h
index f260b8e0..661f3eb1 100644
--- a/include/utils/HsvTransform.h
+++ b/include/utils/HsvTransform.h
@@ -67,11 +67,35 @@ public:
 	void transform(uint8_t & red, uint8_t & green, uint8_t & blue) const;
 
 	///
-	/// integer version of the conversion are faster, but a little less accurate
-	/// all values are unsigned 8 bit values and scaled between 0 and 255 except
-	/// for the hue which is a 16 bit number and scaled between 0 and 360
+	///	Translates an RGB (red, green, blue) color to an HSV (hue, saturation, value) color
+	///
+	/// @param[in] red The red RGB-component
+	/// @param[in] green The green RGB-component
+	/// @param[in] blue The blue RGB-component
+	/// @param[out] hue The hue HSV-component
+	/// @param[out] saturation The saturation HSV-component
+	/// @param[out] value The value HSV-component
+	///
+	/// @note Integer version of the conversion are faster, but a little less accurate all values
+	/// are unsigned 8 bit values and scaled between 0 and 255 except for the hue which is a 16 bit
+	/// number and scaled between 0 and 360
 	///
 	static void rgb2hsv(uint8_t red, uint8_t green, uint8_t blue, uint16_t & hue, uint8_t & saturation, uint8_t & value);
+
+	///
+	///	Translates an HSV (hue, saturation, value) color to an RGB (red, green, blue) color
+	///
+	/// @param[in] hue The hue HSV-component
+	/// @param[in] saturation The saturation HSV-component
+	/// @param[in] value The value HSV-component
+	/// @param[out] red The red RGB-component
+	/// @param[out] green The green RGB-component
+	/// @param[out] blue The blue RGB-component
+	///
+	/// @note Integer version of the conversion are faster, but a little less accurate all values
+	/// are unsigned 8 bit values and scaled between 0 and 255 except for the hue which is a 16 bit
+	/// number and scaled between 0 and 360
+	///
 	static void hsv2rgb(uint16_t hue, uint8_t saturation, uint8_t value, uint8_t & red, uint8_t & green, uint8_t & blue);
 
 private:
diff --git a/include/utils/jsonschema/JsonSchemaChecker.h b/include/utils/jsonschema/JsonSchemaChecker.h
index 4f02bcf5..768b57db 100644
--- a/include/utils/jsonschema/JsonSchemaChecker.h
+++ b/include/utils/jsonschema/JsonSchemaChecker.h
@@ -33,14 +33,14 @@ public:
 	virtual ~JsonSchemaChecker();
 
 	///
-	/// @param The schema to use
+	/// @param schema The schema to use
 	/// @return true upon succes
 	///
 	bool setSchema(const Json::Value & schema);
 
 	///
 	/// @brief Validate a JSON structure
-	/// @param The JSON value to check
+	/// @param value The JSON value to check
 	/// @return true when the arguments is valid according to the schema
 	///
 	bool validate(const Json::Value & value);
@@ -51,34 +51,142 @@ public:
 	const std::list & getMessages() const;
 
 private:
-	void collectReferences(const Json::Value & schema);
-
+	///
+	/// Validates a json-value against a given schema. Results are stored in the members of this
+	/// class (_error & _messages)
+	///
+	/// @param[in] value The value to validate
+	/// @param[in] schema The schema against which the value is validated
+	///
 	void validate(const Json::Value &value, const Json::Value & schema);
 
+	///
+	/// Adds the given message to the message-queue (with reference to current line-number)
+	///
+	/// @param[in] message The message to add to the queue
+	///
 	void setMessage(const std::string & message);
 
+	///
+	/// Retrieves all references from the json-value as specified by the schema
+	///
+	/// @param[in] value The json-value
+	/// @param[in] schema The schema
+	///
 	void collectDependencies(const Json::Value & value, const Json::Value &schema);
 
 private:
 	// attribute check functions
+	///
+	/// Checks if the given value is of the specified type. If the type does not match _error is set
+	/// to true and an error-message is added to the message-queue
+	///
+	/// @param[in] value The given value
+	/// @param[in] schema The specified type (as json-value)
+	///
 	void checkType(const Json::Value & value, const Json::Value & schema);
+	///
+	/// Checks is required properties of an json-object exist and if all properties are of the
+	/// correct format. If this is not the case _error is set to true and an error-message is added
+	/// to the message-queue.
+	///
+	/// @param[in] value The given json-object
+	/// @param[in] schema The schema of the json-object
+	///
 	void checkProperties(const Json::Value & value, const Json::Value & schema);
+
+	///
+	/// Verifies the additional configured properties of an json-object. If this is not the case
+	/// _error is set to true and an error-message is added to the message-queue.
+	///
+	/// @param value The given json-object
+	/// @param schema The schema for the json-object
+	/// @param ignoredProperties The properties that were ignored
+	///
 	void checkAdditionalProperties(const Json::Value & value, const Json::Value & schema, const Json::Value::Members & ignoredProperties);
+
+	///
+	/// Checks if references are configued and used correctly. If this is not the case _error is set
+	/// to true and an error-message is added to the message-queue.
+	///
+	/// @param value The given json-object
+	/// @param schemaLink The schema of the json-object
+	///
 	void checkDependencies(const Json::Value & value, const Json::Value & schemaLink);
+
+	///
+	/// Checks if the given value is larger or equal to the specified value. If this is not the case
+	/// _error is set to true and an error-message is added to the message-queue.
+	///
+	/// @param[in] value The given value
+	/// @param[in] schema The minimum value (as json-value)
+	///
 	void checkMinimum(const Json::Value & value, const Json::Value & schema);
+
+	///
+	/// Checks if the given value is smaller or equal to the specified value. If this is not the
+	/// case _error is set to true and an error-message is added to the message-queue.
+	///
+	/// @param[in] value The given value
+	/// @param[in] schema The maximum value (as json-value)
+	///
 	void checkMaximum(const Json::Value & value, const Json::Value & schema);
+
+	///
+	/// Validates all the items of an array.
+	///
+	/// @param value The json-array
+	/// @param schema The schema for the items in the array
+	///
 	void checkItems(const Json::Value & value, const Json::Value & schema);
+
+	///
+	/// Checks if a given array has at least a minimum number of items. If this is not the case
+	/// _error is set to true and an error-message is added to the message-queue.
+	///
+	/// @param value The json-array
+	/// @param schema The minimum size specification (as json-value)
+	///
 	void checkMinItems(const Json::Value & value, const Json::Value & schema);
+
+	///
+	/// Checks if a given array has at most a maximum number of items. If this is not the case
+	/// _error is set to true and an error-message is added to the message-queue.
+	///
+	/// @param value The json-array
+	/// @param schema The maximum size specification (as json-value)
+	///
 	void checkMaxItems(const Json::Value & value, const Json::Value & schema);
+
+	///
+	/// Checks if a given array contains only unique items. If this is not the case
+	/// _error is set to true and an error-message is added to the message-queue.
+	///
+	/// @param value The json-array
+	/// @param schema Bool to enable the check (as json-value)
+	///
 	void checkUniqueItems(const Json::Value & value, const Json::Value & schema);
+
+	///
+	/// Checks if an enum value is actually a valid value for that enum. If this is not the case
+	/// _error is set to true and an error-message is added to the message-queue.
+	///
+	/// @param value The enum value
+	/// @param schema The enum schema definition
+	///
 	void checkEnum(const Json::Value & value, const Json::Value & schema);
 
 private:
+	/// The schema of the entire json-configuration
 	Json::Value _schema;
 
+	/// The current location into a json-configuration structure being checked
 	std::list _currentPath;
+	/// The result messages collected during the schema verification
 	std::list _messages;
+	/// Flag indicating an error occured during validation
 	bool _error;
 
+	/// A list with references (string => json-value)
 	std::map _references; // ref 2 value
 };
diff --git a/libsrc/hyperion/ImageToLedsMap.h b/libsrc/hyperion/ImageToLedsMap.h
index 3605bf78..8cecb94b 100644
--- a/libsrc/hyperion/ImageToLedsMap.h
+++ b/libsrc/hyperion/ImageToLedsMap.h
@@ -59,6 +59,8 @@ namespace hyperion
 		/// Determines the mean-color for each led using the mapping the image given
 		/// at construction.
 		///
+		/// @param[in] image  The image from which to extract the led colors
+		///
 		/// @return ledColors  The vector containing the output
 		///
 		std::vector getMeanLedColor(const RgbImage & image) const;
@@ -67,6 +69,7 @@ namespace hyperion
 		/// Determines the mean color for each led using the mapping the image given
 		/// at construction.
 		///
+		/// @param[in] image  The image from which to extract the led colors
 		/// @param[out] ledColors  The vector containing the output
 		///
 		void getMeanLedColor(const RgbImage & image, std::vector & ledColors) const;
@@ -83,6 +86,7 @@ namespace hyperion
 		/// Calculates the 'mean color' of the given list. This is the mean over each color-channel
 		/// (red, green, blue)
 		///
+		/// @param[in] image The image a section from which an average color must be computed
 		/// @param[in] colors  The list with colors
 		///
 		/// @return The mean of the given list of colors (or black when empty)
diff --git a/libsrc/jsonserver/JsonClientConnection.h b/libsrc/jsonserver/JsonClientConnection.h
index d2ff4366..5381baff 100644
--- a/libsrc/jsonserver/JsonClientConnection.h
+++ b/libsrc/jsonserver/JsonClientConnection.h
@@ -109,8 +109,6 @@ private:
 	///
 	/// Handle an incoming JSON message of unknown type
 	///
-	/// @param message the incoming message
-	///
 	void handleNotImplemented();
 
 	///
diff --git a/libsrc/utils/jsonschema/JsonSchemaChecker.cpp b/libsrc/utils/jsonschema/JsonSchemaChecker.cpp
index 6b69ad0b..2ace25a5 100644
--- a/libsrc/utils/jsonschema/JsonSchemaChecker.cpp
+++ b/libsrc/utils/jsonschema/JsonSchemaChecker.cpp
@@ -413,7 +413,7 @@ void JsonSchemaChecker::checkUniqueItems(const Json::Value & value, const Json::
 	{
 		// only for arrays
 		_error = true;
-		setMessage("maxItems only valid for arrays");
+		setMessage("uniqueItems only valid for arrays");
 		return;
 	}
 
diff --git a/src/hyperion-remote/ColorTransformValues.h b/src/hyperion-remote/ColorTransformValues.h
index d36e2c91..4a8be275 100644
--- a/src/hyperion-remote/ColorTransformValues.h
+++ b/src/hyperion-remote/ColorTransformValues.h
@@ -3,7 +3,10 @@
 /// Simple structure to contain the values of a color transformation
 struct ColorTransformValues
 {
+	/// The value for the red color-channel
 	double valueRed;
+	/// The value for the green color-channel
 	double valueGreen;
+	/// The value for the blue color-channel
 	double valueBlue;
 };
diff --git a/src/hyperion-remote/CustomParameter.h b/src/hyperion-remote/CustomParameter.h
index a9a65242..c1ff96d4 100644
--- a/src/hyperion-remote/CustomParameter.h
+++ b/src/hyperion-remote/CustomParameter.h
@@ -20,6 +20,15 @@ typedef vlofgren::PODParameter ImageParameter;
 typedef vlofgren::PODParameter TransformParameter;
 
 namespace vlofgren {
+	///
+	/// Translates a string (as passed on the commandline) to a color
+	///
+	/// @param[in] s The string (as passed on the commandline)
+	///
+	/// @return The translated color
+	///
+	/// @throws Parameter::ParameterRejected If the string did not result in a color
+	///
 	template<>
 	QColor ColorParameter::validate(const std::string& s) throw (Parameter::ParameterRejected)
 	{
diff --git a/src/hyperion-remote/JsonConnection.h b/src/hyperion-remote/JsonConnection.h
index a6262825..33fc5b4a 100644
--- a/src/hyperion-remote/JsonConnection.h
+++ b/src/hyperion-remote/JsonConnection.h
@@ -79,6 +79,7 @@ public:
 	/// @param saturation The HSV saturation gain
 	/// @param value The HSV value gain
 	/// @param threshold The threshold
+	/// @param gamma The gamma value
 	/// @param blacklevel The blacklevel
 	/// @param whitelevel The whitelevel
 	///
diff --git a/src/viewpng/CMakeLists.txt b/src/viewpng/CMakeLists.txt
index 8ad1defa..6e50bc51 100644
--- a/src/viewpng/CMakeLists.txt
+++ b/src/viewpng/CMakeLists.txt
@@ -6,6 +6,7 @@ if(PNG_FOUND)
 	include_directories(${PNG_INCLUDE_DIR})
 
 	add_executable(viewpng
+			FbWriter.h
 			ViewPng.cpp)
 
 	target_link_libraries(viewpng
diff --git a/src/viewpng/FbWriter.h b/src/viewpng/FbWriter.h
index 9cd4afdc..f6edc6b1 100644
--- a/src/viewpng/FbWriter.h
+++ b/src/viewpng/FbWriter.h
@@ -12,14 +12,27 @@
 
 #include 
 
+///
+/// FbWriter allows direct access tot the FrameBuffer. It writes and image to the framebuffer,
+/// adjusting the resolution as required. When destructed the FrameBuffer is switch to original
+/// configuration.
+///
 class FbWriter
 {
 public:
+	///
+	/// Constructs the FrameBuffer writer opening the FrameBuffer device and storing the current
+	/// configuration.
+	///
 	FbWriter()
 	{
 		initialise();
 	}
 
+	///
+	/// Destructor of the write. Switches the FrameBuffer to its origianl configuration and closes
+	/// the FrameBuffer
+	///
 	~FbWriter()
 	{
 		if (ioctl(fbfd, FBIOPUT_VSCREENINFO, &orig_vinfo))
@@ -30,26 +43,33 @@ public:
 		close(fbfd);
 	}
 
+	///
+	/// Initialises the write, opening the FrameBuffer
+	///
+	/// @return Zero on succes else negative
+	///
 	int initialise()
 	{
 		// Open the file for reading and writing
 		fbfd = open("/dev/fb0", O_RDWR);
 		if (!fbfd)
 		{
-			printf("Error: cannot open framebuffer device.\n");
-			return(-1);
+			std::cerr << "Error: cannot open framebuffer device." << std::endl;
+			return -1;
 		}
 		printf("The framebuffer device was opened successfully.\n");
 
 		// Get fixed screen information
 		if (ioctl(fbfd, FBIOGET_FSCREENINFO, &finfo))
 		{
-			printf("Error reading fixed information.\n");
+			std::cerr << "Error reading fixed information.\n" << std::endl;
+			return -1;
 		}
 		// Get variable screen information
 		if (ioctl(fbfd, FBIOGET_VSCREENINFO, &orig_vinfo))
 		{
-			printf("Error reading variable information.\n");
+			std::cerr << "Error reading variable information.\n" << std::endl;
+			return -1;
 		}
 		printf("Original %dx%d, %dbpp\n", orig_vinfo.xres, orig_vinfo.yres, orig_vinfo.bits_per_pixel );
 
@@ -57,6 +77,12 @@ public:
 		return 0;
 	}
 
+	///
+	/// Writes the given RGB Image to the FrameBuffer. When required the resolution of the
+	/// FrameBuffer is asjusted to match the given image
+	///
+	/// @param image  The RGB Image
+	///
 	void writeImage(const RgbImage& image)
 	{
 		std::cout << "Writing image [" << image.width() << "x" << image.height() << "]" << std::endl;
@@ -93,23 +119,16 @@ public:
 		for (unsigned iY=0; iY
Date: Thu, 12 Sep 2013 18:42:16 +0000
Subject: [PATCH 09/12] Enabled KnightRider boot sequence

---
 libsrc/bootsequence/BootSequenceFactory.cpp | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/libsrc/bootsequence/BootSequenceFactory.cpp b/libsrc/bootsequence/BootSequenceFactory.cpp
index d8e02b0a..50c2cdf2 100644
--- a/libsrc/bootsequence/BootSequenceFactory.cpp
+++ b/libsrc/bootsequence/BootSequenceFactory.cpp
@@ -4,6 +4,7 @@
 
 // Local Bootsequence includes
 #include "RainbowBootSequence.h"
+#include "KittBootSequence.h"
 
 BootSequence * BootSequenceFactory::createBootSequence(Hyperion * hyperion, const Json::Value & jsonConfig)
 {
@@ -20,11 +21,8 @@ BootSequence * BootSequenceFactory::createBootSequence(Hyperion * hyperion, cons
 	}
 	else if (type == "knightrider")
 	{
-		std::cout << "KNIGHT RIDER NOT IMPLEMENTED YET" << std::endl;
-		return nullptr;
-//		const unsigned duration_ms = jsonConfig["duration_ms"].asUint();
-//		const std::string colorStr = jsonConfig["color"].asString();
-//		return new KnightRiderSequence(hyperion, duration_ms);
+		const unsigned duration_ms = jsonConfig["duration_ms"].asUInt();
+		return new KittBootSequence(hyperion, duration_ms);
 	}
 
 	std::cerr << "Unknown boot-sequence selected; boot-sequence disabled." << std::endl;

From 02fa8f56798fd639b1a5760d4278089705ab34ac Mon Sep 17 00:00:00 2001
From: johan 
Date: Fri, 13 Sep 2013 14:03:12 +0200
Subject: [PATCH 10/12] Fix bug in hsv2rgb transform

---
 libsrc/utils/HsvTransform.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libsrc/utils/HsvTransform.cpp b/libsrc/utils/HsvTransform.cpp
index 6595a1c7..8381da10 100644
--- a/libsrc/utils/HsvTransform.cpp
+++ b/libsrc/utils/HsvTransform.cpp
@@ -103,7 +103,7 @@ void HsvTransform::hsv2rgb(uint16_t hue, uint8_t saturation, uint8_t value, uint
 	}
 
 	region = hue / 60;
-	remainder = (hue - (region * 60)) * 6;
+	remainder = (hue - (region * 60)) * 256 / 60;
 
 	p = (value * (255 - saturation)) >> 8;
 	q = (value * (255 - ((saturation * remainder) >> 8))) >> 8;

From 82617dea5127505a1a56da8349e02b8943a5d7d5 Mon Sep 17 00:00:00 2001
From: johan 
Date: Fri, 13 Sep 2013 14:24:49 +0200
Subject: [PATCH 11/12] Fix bug in rgb2hsv transform

---
 libsrc/utils/HsvTransform.cpp | 15 ++++++++++++++-
 1 file changed, 14 insertions(+), 1 deletion(-)

diff --git a/libsrc/utils/HsvTransform.cpp b/libsrc/utils/HsvTransform.cpp
index 8381da10..3b147662 100644
--- a/libsrc/utils/HsvTransform.cpp
+++ b/libsrc/utils/HsvTransform.cpp
@@ -1,3 +1,4 @@
+#include 
 #include 
 
 HsvTransform::HsvTransform() :
@@ -44,6 +45,8 @@ void HsvTransform::transform(uint8_t & red, uint8_t & green, uint8_t & blue) con
 		uint8_t saturation, value;
 		rgb2hsv(red, green, blue, hue, saturation, value);
 
+		std::cout << int(hue) << " " << int(saturation) << " " << int(value) << std::endl;
+
 		int s = saturation * _saturationGain;
 		if (s > 255)
 			saturation = 255;
@@ -83,11 +86,21 @@ void HsvTransform::rgb2hsv(uint8_t red, uint8_t green, uint8_t blue, uint16_t &
 	}
 
 	if (rgbMax == red)
-		hue = 0 + 60 * (green - blue) / (rgbMax - rgbMin);
+	{
+		// start from 360 to be sure that we won't assign a negative number to the unsigned hue value
+		hue = 360 + 60 * (green - blue) / (rgbMax - rgbMin);
+
+		if (hue > 359)
+			hue -= 360;
+	}
 	else if (rgbMax == green)
+	{
 		hue = 120 + 60 * (blue - red) / (rgbMax - rgbMin);
+	}
 	else
+	{
 		hue = 240 + 60 * (red - green) / (rgbMax - rgbMin);
+	}
 }
 
 void HsvTransform::hsv2rgb(uint16_t hue, uint8_t saturation, uint8_t value, uint8_t & red, uint8_t & green, uint8_t & blue)

From cf0f94224f5a5e1460fdea2ba2843aa94fba3d20 Mon Sep 17 00:00:00 2001
From: johan 
Date: Mon, 23 Sep 2013 22:33:38 +0200
Subject: [PATCH 12/12] Changed XBMC Video checker from emitting all black on a
 lower channel than the grabber to commanding the grabber

---
 include/dispmanx-grabber/DispmanxWrapper.h   |  7 ++++
 include/utils/GrabbingMode.h                 | 11 ++++++
 include/xbmcvideochecker/XBMCVideoChecker.h  | 31 ++++++++++++----
 libsrc/dispmanx-grabber/DispmanxWrapper.cpp  |  8 ++++
 libsrc/xbmcvideochecker/XBMCVideoChecker.cpp | 39 +++++++++++++++-----
 src/hyperiond/hyperiond.cpp                  |  3 +-
 6 files changed, 81 insertions(+), 18 deletions(-)
 create mode 100644 include/utils/GrabbingMode.h

diff --git a/include/dispmanx-grabber/DispmanxWrapper.h b/include/dispmanx-grabber/DispmanxWrapper.h
index 2d22b677..6dc433cd 100644
--- a/include/dispmanx-grabber/DispmanxWrapper.h
+++ b/include/dispmanx-grabber/DispmanxWrapper.h
@@ -7,6 +7,7 @@
 // Utils includes
 #include 
 #include 
+#include 
 
 // Forward class declaration
 class DispmanxFrameGrabber;
@@ -53,6 +54,12 @@ public slots:
 	///
 	void stop();
 
+	///
+	/// \brief Set the grabbing mode
+	/// \param mode The new grabbing mode
+	///
+	void setGrabbingMode(GrabbingMode mode);
+
 private:
 	/// The update rate [Hz]
 	const int _updateInterval_ms;
diff --git a/include/utils/GrabbingMode.h b/include/utils/GrabbingMode.h
new file mode 100644
index 00000000..7e7a8786
--- /dev/null
+++ b/include/utils/GrabbingMode.h
@@ -0,0 +1,11 @@
+#pragma once
+
+enum GrabbingMode
+{
+	GRABBINGMODE_OFF,
+	GRABBINGMODE_VIDEO,
+	GRABBINGMODE_PHOTO,
+	GRABBINGMODE_AUDIO,
+	GRABBINGMODE_MENU,
+	GRABBINGMODE_INVALID
+};
diff --git a/include/xbmcvideochecker/XBMCVideoChecker.h b/include/xbmcvideochecker/XBMCVideoChecker.h
index 54917ed2..aa6a27ee 100644
--- a/include/xbmcvideochecker/XBMCVideoChecker.h
+++ b/include/xbmcvideochecker/XBMCVideoChecker.h
@@ -14,6 +14,9 @@
 // Hyperion includes
 #include 
 
+// Utils includes
+#include 
+
 ///
 /// This class will check if XBMC is playing something. When it does not, this class will send all black data to Hyperion.
 /// This allows grabbed screen data to be overriden while in the XBMC menus.
@@ -31,16 +34,21 @@ public:
 	/// @param address Network address of the XBMC instance
 	/// @param port Port number to use (XBMC default = 9090)
 	/// @param interval The interval at which XBMC is polled
-	/// @param hyperion The Hyperion instance
-	/// @param priority The priority at which to send the all black data
+	/// @param grabVideo Whether or not to grab when the XBMC video player is playing
+	/// @param grabPhoto Whether or not to grab when the XBMC photo player is playing
+	/// @param grabAudio Whether or not to grab when the XBMC audio player is playing
+	/// @param grabMenu Whether or not to grab when nothing is playing (in XBMC menu)
 	///
-	XBMCVideoChecker(const std::string & address, uint16_t port, uint64_t interval, Hyperion * hyperion, int priority);
+	XBMCVideoChecker(const std::string & address, uint16_t port, uint64_t interval, bool grabVideo, bool grabPhoto, bool grabAudio, bool grabMenu);
 
 	///
 	/// Start polling XBMC
 	///
 	void start();
 
+signals:
+	void grabbingMode(GrabbingMode grabbingMode);
+
 private slots:
 	///
 	/// Send a request to XBMC
@@ -68,9 +76,18 @@ private:
 	/// The QT TCP Socket with connection to XBMC
 	QTcpSocket _socket;
 
-	/// The Hyperion instance to switch leds to black if in XBMC menu
-	Hyperion * _hyperion;
+	/// Flag indicating whether or not to grab when the XBMC video player is playing
+	bool _grabVideo;
 
-	/// The priority of the BLACK led value when in XBMC menu
-	const int _priority;
+	/// Flag indicating whether or not to grab when the XBMC photo player is playing
+	bool _grabPhoto;
+
+	/// Flag indicating whether or not to grab when the XBMC audio player is playing
+	bool _grabAudio;
+
+	/// Flag indicating whether or not to grab when XBMC is playing nothing (in menu)
+	bool _grabMenu;
+
+	/// Previous emitted grab state
+	GrabbingMode _previousMode;
 };
diff --git a/libsrc/dispmanx-grabber/DispmanxWrapper.cpp b/libsrc/dispmanx-grabber/DispmanxWrapper.cpp
index b785db19..f04e3dce 100644
--- a/libsrc/dispmanx-grabber/DispmanxWrapper.cpp
+++ b/libsrc/dispmanx-grabber/DispmanxWrapper.cpp
@@ -60,3 +60,11 @@ void DispmanxWrapper::stop()
 	// Stop the timer, effectivly stopping the process
 	_timer.stop();
 }
+
+void DispmanxWrapper::setGrabbingMode(GrabbingMode mode)
+{
+	if (mode == GRABBINGMODE_VIDEO)
+		start();
+	else
+		stop();
+}
diff --git a/libsrc/xbmcvideochecker/XBMCVideoChecker.cpp b/libsrc/xbmcvideochecker/XBMCVideoChecker.cpp
index 2a065b65..117fd46c 100644
--- a/libsrc/xbmcvideochecker/XBMCVideoChecker.cpp
+++ b/libsrc/xbmcvideochecker/XBMCVideoChecker.cpp
@@ -3,15 +3,18 @@
 
 #include 
 
-XBMCVideoChecker::XBMCVideoChecker(const std::string & address, uint16_t port, uint64_t interval_ms, Hyperion * hyperion, int priority) :
+XBMCVideoChecker::XBMCVideoChecker(const std::string & address, uint16_t port, uint64_t interval_ms, bool grabVideo, bool grabPhoto, bool grabAudio, bool grabMenu) :
 	QObject(),
 	_address(QString::fromStdString(address)),
 	_port(port),
 	_request("{\"jsonrpc\":\"2.0\",\"method\":\"Player.GetActivePlayers\",\"id\":1}"),
 	_timer(),
 	_socket(),
-	_hyperion(hyperion),
-	_priority(priority)
+	_grabVideo(grabVideo),
+	_grabPhoto(grabPhoto),
+	_grabAudio(grabAudio),
+	_grabMenu(grabMenu),
+	_previousMode(GRABBINGMODE_INVALID)
 {
 	// setup timer
 	_timer.setSingleShot(false);
@@ -51,17 +54,33 @@ void XBMCVideoChecker::receiveReply()
 	// expect that the reply is received as a single message. Probably oke considering the size of the expected reply
 	QString reply(_socket.readAll());
 
-	if (reply.contains("playerid"))
+	GrabbingMode newMode = GRABBINGMODE_INVALID;
+	if (reply.contains("video"))
 	{
-		// something is playing. check for "video" to check if a video is playing
-		// clear our priority channel to allow the grabbed vido colors to be shown
-		_hyperion->clear(_priority);
+		// video is playing
+		newMode = _grabVideo ? GRABBINGMODE_VIDEO : GRABBINGMODE_OFF;
+	}
+	else if (reply.contains("picture"))
+	{
+		// photo viewer is playing
+		newMode = _grabVideo ? GRABBINGMODE_PHOTO : GRABBINGMODE_OFF;
+	}
+	else if (reply.contains("audio"))
+	{
+		// photo viewer is playing
+		newMode = _grabVideo ? GRABBINGMODE_AUDIO : GRABBINGMODE_OFF;
 	}
 	else
 	{
-		// Nothing is playing. set our priority channel completely to black
-		// The timeout is used to have the channel cleared after 30 seconds of connection problems...
-		_hyperion->setColor(_priority, RgbColor::BLACK, 30000);
+		// Nothing is playing.
+		newMode = _grabMenu ? GRABBINGMODE_MENU : GRABBINGMODE_OFF;
+	}
+
+	// emit new state if applicable
+	if (newMode != _previousMode)
+	{
+		emit grabbingMode(newMode);
+		_previousMode = newMode;
 	}
 }
 
diff --git a/src/hyperiond/hyperiond.cpp b/src/hyperiond/hyperiond.cpp
index 0f216db5..61fc4c13 100644
--- a/src/hyperiond/hyperiond.cpp
+++ b/src/hyperiond/hyperiond.cpp
@@ -83,7 +83,7 @@ int main(int argc, char** argv)
 	}
 
 	const Json::Value & videoCheckerConfig = config["xbmcVideoChecker"];
-	XBMCVideoChecker xbmcVideoChecker(videoCheckerConfig["xbmcAddress"].asString(), videoCheckerConfig["xbmcTcpPort"].asUInt(), 1000, &hyperion, 999);
+	XBMCVideoChecker xbmcVideoChecker(videoCheckerConfig["xbmcAddress"].asString(), videoCheckerConfig["xbmcTcpPort"].asUInt(), 1000, true, true, true, true);
 	if (videoCheckerConfig["enable"].asBool())
 	{
 		xbmcVideoChecker.start();
@@ -97,6 +97,7 @@ int main(int argc, char** argv)
 			frameGrabberConfig["height"].asUInt(),
 			frameGrabberConfig["frequency_Hz"].asUInt(),
 			&hyperion);
+	QObject::connect(&xbmcVideoChecker, SIGNAL(grabbingMode(GrabbingMode)), &dispmanx, SLOT(setGrabbingMode(GrabbingMode)));
 	dispmanx.start();
 	std::cout << "Frame grabber created and started" << std::endl;