mirror of
https://github.com/CTCaer/RetroArch.git
synced 2024-12-22 10:49:02 +00:00
Revert "(D3D) More refactors to do with hiding away vertex declaration"
This reverts commit c6458daa0e
.
This commit is contained in:
parent
c6458daa0e
commit
7f65bf700a
@ -149,17 +149,20 @@ void *d3d_vertex_buffer_lock(LPDIRECT3DVERTEXBUFFER vertbuf)
|
||||
|
||||
void d3d_vertex_buffer_free(void *vertex_data, void *vertex_declaration)
|
||||
{
|
||||
if (vertex_data)
|
||||
#ifdef HAVE_D3D9
|
||||
LPDIRECT3DVERTEXDECLARATION vertex_decl = (LPDIRECT3DVERTEXDECLARATION)vertex_declaration;
|
||||
#endif
|
||||
LPDIRECT3DVERTEXBUFFER buf = (LPDIRECT3DVERTEXBUFFER)vertex_data;
|
||||
|
||||
if (buf)
|
||||
{
|
||||
LPDIRECT3DVERTEXBUFFER buf = (LPDIRECT3DVERTEXBUFFER)vertex_data;
|
||||
buf->Release();
|
||||
buf = NULL;
|
||||
}
|
||||
|
||||
#ifdef HAVE_D3D9
|
||||
if (vertex_declaration)
|
||||
if (vertex_decl)
|
||||
{
|
||||
LPDIRECT3DVERTEXDECLARATION vertex_decl = (LPDIRECT3DVERTEXDECLARATION)vertex_declaration;
|
||||
vertex_decl->Release();
|
||||
vertex_decl = NULL;
|
||||
}
|
||||
|
@ -776,7 +776,8 @@ void renderchain_clear(void *data)
|
||||
d3d_vertex_buffer_free(chain->prev.vertex_buf[i], NULL);
|
||||
}
|
||||
|
||||
d3d_vertex_buffer_free(NULL, chain->passes[0].vertex_decl);
|
||||
if (chain->passes[0].vertex_decl)
|
||||
chain->passes[0].vertex_decl->Release();
|
||||
|
||||
for (i = 1; i < chain->passes.size(); i++)
|
||||
{
|
||||
|
@ -54,7 +54,9 @@ struct Pass
|
||||
CGprogram vPrg, fPrg;
|
||||
#endif
|
||||
unsigned last_width, last_height;
|
||||
void *vertex_decl;
|
||||
#ifdef HAVE_D3D9
|
||||
LPDIRECT3DVERTEXDECLARATION vertex_decl;
|
||||
#endif
|
||||
std::vector<unsigned> attrib_map;
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user