cancel
Showing results for 
Search instead for 
Did you mean: 

Exception when calling Ovr_destroy()

Pippopluto
Honored Guest
HI all, when i call this destructor

COculus::~COculus()
{
ovr_Destroy(hmd);
ovr_Shutdown();
}


I have an exception that say
OVR Error:
Code: -3010 -- ovrError_LeakingResources
Description: Client disconnecting with active texture sets. This will lead to instability in the calling application

so I add this to destructor

COculus::~COculus()
{

ovr_DestroySwapTextureSet(hmd, TextureSet[0]);
ovr_DestroySwapTextureSet(hmd, TextureSet[1]);
ovr_DestroyMirrorTexture;
ovr_Destroy(hmd);
ovr_Shutdown();
}


With this, i don't have the ovrError but still have an exception
exception generated in 0x09233800 in Progetto1.exe: 0xC0000005: ecces violated during execution of 0x09233800.

I have translate exception code from italian.

Do I miss something when shutting down the hmd? I'm using 0.7 sdk
2 REPLIES 2

joan
Protege
ovr_DestroyMirrorTexture;


Did you forget to actually call the function?

Also possibly missing OVR::System::Destroy(); at the end.

Pippopluto
Honored Guest
I have tried to use correct function and also to remove it, but exception doesn't disappear.
The exception is throw in OVR_CAPIShim.c

OVR_PUBLIC_FUNCTION(void) ovr_Destroy(ovrHmd hmd)
{
if (!ovr_DestroyPtr)
return;
ovr_DestroyPtr(hmd); Here
}


In visual studio I can see that hmd=0x04bf3e80 and ovr_DestroyPtr=libOVRRT32_0_7.dll

EDIT SOLVED: i solved the error calling another method befor destructor. New method call ovrDestroy, the destructor only shutdown