2010-06-13 19:50:06 +00:00
|
|
|
// Copyright (C) 2003 Dolphin Project.
|
|
|
|
|
|
|
|
// This program is free software: you can redistribute it and/or modify
|
|
|
|
// it under the terms of the GNU General Public License as published by
|
|
|
|
// the Free Software Foundation, version 2.0.
|
|
|
|
|
|
|
|
// This program is distributed in the hope that it will be useful,
|
|
|
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
// GNU General Public License 2.0 for more details.
|
|
|
|
|
|
|
|
// A copy of the GPL 2.0 should have been included with the program.
|
|
|
|
// If not, see http://www.gnu.org/licenses/
|
|
|
|
|
|
|
|
// Official SVN repository and contact information can be found at
|
|
|
|
// http://code.google.com/p/dolphin-emu/
|
|
|
|
|
|
|
|
#ifndef _VERTEXMANAGER_H
|
|
|
|
#define _VERTEXMANAGER_H
|
|
|
|
|
2010-10-03 00:41:06 +00:00
|
|
|
#include "VertexManagerBase.h"
|
2011-03-14 09:38:29 +00:00
|
|
|
#include "LineGeometryShader.h"
|
|
|
|
#include "PointGeometryShader.h"
|
2010-06-13 19:50:06 +00:00
|
|
|
|
2010-10-03 00:41:06 +00:00
|
|
|
namespace DX11
|
|
|
|
{
|
2010-06-13 19:50:06 +00:00
|
|
|
|
2010-10-03 00:41:06 +00:00
|
|
|
class VertexManager : public ::VertexManager
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
VertexManager();
|
2011-06-11 19:37:21 +00:00
|
|
|
~VertexManager();
|
2010-10-03 00:41:06 +00:00
|
|
|
|
2010-11-26 09:25:08 +00:00
|
|
|
NativeVertexFormat* CreateNativeVertexFormat();
|
2011-06-11 19:37:21 +00:00
|
|
|
void CreateDeviceObjects();
|
|
|
|
void DestroyDeviceObjects();
|
2012-10-20 13:22:15 +00:00
|
|
|
|
|
|
|
private:
|
|
|
|
|
2010-10-20 02:17:16 +00:00
|
|
|
void LoadBuffers();
|
2010-10-20 03:11:22 +00:00
|
|
|
void Draw(UINT stride);
|
2010-10-03 00:41:06 +00:00
|
|
|
// temp
|
|
|
|
void vFlush();
|
2010-10-20 02:17:16 +00:00
|
|
|
|
|
|
|
UINT m_indexBufferCursor;
|
|
|
|
UINT m_vertexBufferCursor;
|
|
|
|
UINT m_vertexDrawOffset;
|
|
|
|
UINT m_triangleDrawIndex;
|
|
|
|
UINT m_lineDrawIndex;
|
2012-10-20 13:22:15 +00:00
|
|
|
UINT m_pointDrawIndex;
|
|
|
|
UINT m_activeVertexBuffer;
|
|
|
|
UINT m_activeIndexBuffer;
|
|
|
|
UINT m_LastVertexBuffer;
|
|
|
|
UINT m_LastIndexBuffer;
|
|
|
|
typedef ID3D11Buffer* PID3D11Buffer;
|
|
|
|
PID3D11Buffer* m_indexBuffers;
|
|
|
|
PID3D11Buffer* m_vertexBuffers;
|
2011-03-14 09:38:29 +00:00
|
|
|
|
|
|
|
LineGeometryShader m_lineShader;
|
|
|
|
PointGeometryShader m_pointShader;
|
2010-10-03 00:41:06 +00:00
|
|
|
};
|
2010-06-13 19:50:06 +00:00
|
|
|
|
|
|
|
} // namespace
|
|
|
|
|
|
|
|
#endif
|