|
@@ -186,7 +186,6 @@ CMediaControllerEntity::CMediaControllerEntity(): m_capture(NULL), m_salesaudio_
|
|
|
m_bCameraOffTimerOn = false;
|
|
|
m_bVirtualCamOpened = false;
|
|
|
m_iVirtualCamLogLevel = 1;
|
|
|
- m_bInstallVirtualCam = false;
|
|
|
m_eDeviceType = eStand2sType;
|
|
|
m_nCameraErrorCode = Error_Succeed;
|
|
|
memset(&conf, 0, sizeof(capture_config_t));
|
|
@@ -833,15 +832,13 @@ void CMediaControllerEntity::OnStarted()
|
|
|
}
|
|
|
else {
|
|
|
if (Error_AllCamera != m_nCameraErrorCode) {
|
|
|
- if (m_bInstallVirtualCam) {
|
|
|
- InstallVirtualCamera(conf.strVideoOpt.GetData(), conf.strVideoOpt.GetLength());
|
|
|
- m_hVirtualCamStateThread = (HANDLE)_beginthreadex(NULL, 0, &virtulcam_state_func, this, 0, NULL);
|
|
|
- if (NULL == m_hVirtualCamStateThread) {
|
|
|
- DbgWithLink(LOG_LEVEL_WARN, LOG_TYPE_SYSTEM)("create virtual camera state listen thread failed.");
|
|
|
- }
|
|
|
- else {
|
|
|
- DbgWithLink(LOG_LEVEL_DEBUG, LOG_TYPE_SYSTEM)("create virtual camera state listen thread success.");
|
|
|
- }
|
|
|
+ InstallVirtualCamera(conf.strVideoOpt.GetData(), conf.strVideoOpt.GetLength());
|
|
|
+ m_hVirtualCamStateThread = (HANDLE)_beginthreadex(NULL, 0, &virtulcam_state_func, this, 0, NULL);
|
|
|
+ if (NULL == m_hVirtualCamStateThread) {
|
|
|
+ DbgWithLink(LOG_LEVEL_WARN, LOG_TYPE_SYSTEM)("create virtual camera state listen thread failed.");
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ DbgWithLink(LOG_LEVEL_DEBUG, LOG_TYPE_SYSTEM)("create virtual camera state listen thread success.");
|
|
|
}
|
|
|
}
|
|
|
}
|
|
@@ -1087,7 +1084,6 @@ ErrorCodeEnum CMediaControllerEntity::GetMediaConfig()
|
|
|
unsigned int intervaltime = RVC_CAM_INTERVAL_TIME;
|
|
|
int iaudiotimeout = AUDIO_BUG_THRESHOLD_TIME;
|
|
|
int ivcamloglevel = 1;
|
|
|
- bool bInstallVirtualCam = false;
|
|
|
|
|
|
Error = GetFunction()->OpenConfig(Config_CenterSetting, spConfig);
|
|
|
if (Error == Error_Succeed){
|
|
@@ -1096,7 +1092,6 @@ ErrorCodeEnum CMediaControllerEntity::GetMediaConfig()
|
|
|
table.AddEntryUInt("MediaController", "InterValTime", intervaltime, RVC_CAM_INTERVAL_TIME);
|
|
|
table.AddEntryInt("MediaController", "AudioTimeOut", iaudiotimeout, AUDIO_BUG_THRESHOLD_TIME);
|
|
|
table.AddEntryInt("MediaController", "VirtualCamLogLevel", ivcamloglevel, 1);
|
|
|
- table.AddEntryBoolean("MediaController", "InstallVirtualCam", bInstallVirtualCam, false);
|
|
|
Error= table.Load(spConfig);
|
|
|
}
|
|
|
|
|
@@ -1123,10 +1118,6 @@ ErrorCodeEnum CMediaControllerEntity::GetMediaConfig()
|
|
|
if ((ivcamloglevel >= 1) && (ivcamloglevel <= 3)) {
|
|
|
m_iVirtualCamLogLevel = ivcamloglevel;
|
|
|
}
|
|
|
-
|
|
|
- if (bInstallVirtualCam) {
|
|
|
- m_bInstallVirtualCam = true;
|
|
|
- }
|
|
|
}
|
|
|
|
|
|
return Error;
|