//
//  SpriteNode.h
//  PixelKit
//
//  Copyright (c) 2014 César Parent. All rights reserved.
//
#ifndef _RECTNODE_H
#define _RECTNODE_H

#include "includes.h"
#include "Node.h"
#include "Color.h"

namespace PixelKit
{
	/*!
	 * @class  PixelKit::RectNode
	 * @brief  Node drawn as an axis-aligned rectangle of any color.
	 * @namespace PixelKit
	 */
	class RectNode : public Node
	{
	public:
		/*!
		 * @brief RectNode's default constructor.
		 */
		RectNode();
		
		/*!
		 * @brief RectNode's destructor.
		 */
		~RectNode() override;
		
		/*!
		 * @brief Draw RecNode on the screen.
		 * @param renderer SDL_Renderer to draw to.
		 */
		virtual void draw(SDL_Renderer *renderer) override;
		
		/*!
		 * @brief Set the rectangle's color.
		 * @param color RectNode's new color.
		 */
		virtual void setColor(Color color);
		
		/*!
		 * @brief RectNode's fill color.
		 */
		const Color &color;
		
	protected:
		
		Color _color;
	};

}

#endif