SlimDX Device.Reset crashes with a “D3DERR_INVALIDCALL: Invalid call (-2005530516)” error

前端 未结 3 1613
北荒
北荒 2021-01-05 18:39

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,

3条回答
  •  小鲜肉
    小鲜肉 (楼主)
    2021-01-05 19:13

    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) {} 
    }
    

提交回复
热议问题