After Shutdown(), WaitForInitialization() fails
Posted: Thu Jan 02, 2014 1:37 pm
Please correct me if my understanding of using CameraSDK is wrong.
So, the regular routine to use CameraSDK is:
I noticed that, after shut down Camera Library (the last line), if we call "CameraManager::X().WaitForInitialization();" again, error occurs:
"
Unhandled exception at 0xfeeefeee in test.exe: 0xC0000005: Access violation.
"
Also, before calling "CameraManager::X().WaitForInitialization();" (line 3 in above example), "CameraLibrary::CameraManager::X().AreCamerasShutdown()" will return "False".
Logically, shouldn't it return "True"?
Another observation is that, after shut down the camera library (the last line in above example), "CameraLibrary::CameraManager::X().AreCamerasInitialized()" will return "True".
Shouldn't it return "False"?
Any help/info will be appreciated.
Thanks!
So, the regular routine to use CameraSDK is:
Code: Select all
#include "cameralibrary.h"
using namespace CameraLibrary;
CameraManager::X().WaitForInitialization();
Camera *camera = CameraManager::X().GetCamera();
if(!camera)
{
// failure
}
camera->Start();
// ... Do the work
camera->Stop();
camera->Release();
CameraManager::X().Shutdown();
"
Unhandled exception at 0xfeeefeee in test.exe: 0xC0000005: Access violation.
"
Also, before calling "CameraManager::X().WaitForInitialization();" (line 3 in above example), "CameraLibrary::CameraManager::X().AreCamerasShutdown()" will return "False".
Logically, shouldn't it return "True"?
Another observation is that, after shut down the camera library (the last line in above example), "CameraLibrary::CameraManager::X().AreCamerasInitialized()" will return "True".
Shouldn't it return "False"?
Any help/info will be appreciated.
Thanks!