We recently upgraded from VS 2005
to VS 2008
(Windows XP). We use SlimDx
in one of our projects. All was working ok after the upgrade, except my Recover function, which gets called on devicelost/device reset which crashes with
D3DERR_INVALIDCALL: Invalid call (-2005530516)
I use Ctrl-Alt-Del and then Escape to simulate device lost.
void Recover()
{
try
{
if (res.Code == D3DERR_DEVICENOTRESET)
{
res = m_device.Reset(m_presentParams); //Crashes on this.
if (res.IsSuccess)
{
m_deviceLost = false;
}
}
}
catch(Exception e)
{}
}
Is this something to do with VS 2008
, as it used to work nicely with VS 2005
?