mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2026-03-07 09:00:18 -05:00
DX11: Introduce a StateManager class, might improve performance a little.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5740 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
@@ -31,8 +31,7 @@ struct TexbufDeleter
|
||||
{
|
||||
~TexbufDeleter()
|
||||
{
|
||||
if (texbuf) delete[] texbuf;
|
||||
texbuf = NULL;
|
||||
SAFE_DELETE_ARRAY(texbuf);
|
||||
texbufsize = 0;
|
||||
}
|
||||
} texbufdeleter;
|
||||
@@ -55,7 +54,7 @@ void ReplaceTexture2D(ID3D11Texture2D* pTexture, const u8* buffer, unsigned int
|
||||
{
|
||||
if (texbufsize < 4*width*height)
|
||||
{
|
||||
if (texbuf) delete[] texbuf;
|
||||
SAFE_DELETE_ARRAY(texbuf);
|
||||
texbuf = new u8[4*width*height];
|
||||
texbufsize = 4*width*height;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user