summaryrefslogtreecommitdiff
path: root/Runtime/GfxDevice/d3d/VertexDeclarations.h
blob: f737f5a5986904e3fc3df4145ad49bc83c111754 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#pragma once

#include "D3D9Includes.h"
#include "Runtime\Filters\Mesh\VertexData.h"
#include <map>


class VertexDeclarations
{
public:
	VertexDeclarations();
	~VertexDeclarations();

	IDirect3DVertexDeclaration9* GetVertexDecl( const ChannelInfoArray channels );
	void Clear();

private:
	struct KeyType
	{
		bool operator < (const KeyType& rhs) const;
		ChannelInfoArray channels;
	};

	typedef UNITY_MAP(kMemVertexData, KeyType, IDirect3DVertexDeclaration9*) VertexDeclMap;
	VertexDeclMap m_VertexDeclMap;
};