/*!	
	@file
	@brief	ゲーム側から使う頂点配列
*/

#ifndef CVertexMemory_h
#define CVertexMemory_h

#include"../Setup/CompileMode.h"
#include"../template/ReferenceCount.h"

#include"CCustomVertexTemplate.h"
#include"CResourceNameGenerator.h"
#include"CVertex.h"

namespace Maid
{
	class CVertexMemory : public CVertex
	{
	public:
		CVertexMemory();
		CVertexMemory( const CVertexMemory& rha );
		virtual ~CVertexMemory();


		void Create( VERTEXFORMAT fmt, void* pVertex, int Count );

		void Delete();

		virtual mstring GetID()const;

	public:
		CVertexMemory& operator = ( const CVertexMemory& rha );

	private:
		mstring m_VertexName;

		static ReferenceCount<mstring>	s_Cache;
		static unt		s_AutoCount;
	};
}

#endif