/***************************************************************************
*                                                                          *
*  Copyright (C) Golaem S.A.  All Rights Reserved.                         *
*                                                                          *
****************************************************************************/

#pragma once

#include "glmRTTI.h"

namespace glm
{
	/**
	* \brief Shader Attribute
	*/
	struct ShaderAttributeV0
	{
		GLM_RTTI("15754490-0544-454a-8010-dff2c652c1a4", ShaderAttributeV0, addAttributes)
	public:
		GLM_CLASS_STAT_ID( glm::MemoryStatIds::GolaemShared);

		glm::GlmString _name;				/// The name of the attribute
		ShaderAttributeType::Value _type;	/// The type of the attribute
		glm::GlmString _minValue;			/// The min value (to be interpreted according to the type)
		glm::GlmString _maxValue;			/// The max value (to be interpreted according to the type)
		glm::GlmString _fileName;			/// The filename path value
		bool _useRandomValue;				/// If true, a random value between the min and max values will be used,  otherwise the PP attribute value will be used instead
		glm::GlmString _ppAttr;				/// The PP attribute from which to retrieve the value

		ShaderAttributeV0();

		~ShaderAttributeV0();

	protected:

		/**
		* \brief Inspection needed method declaring the inspectable attributes.
		*/
		static void addAttributes();

		/**
		* \brief Accessor to the attribute type needed for inspection
		*/
		int getTypeAsInt() const;

		/**
		* \brief Accessor to the attribute type needed for inspection
		*/
		void setTypeFromInt(int value);
	};
}
