Fix video mode notifications.

This commit is contained in:
Peter Johnson
2017-01-05 01:42:19 -08:00
parent 23462ec7df
commit 3c3236c5d5
2 changed files with 4 additions and 6 deletions

View File

@@ -628,8 +628,7 @@ CS_StatusValue UsbCameraImpl::DeviceCmdSetMode(
DeviceConnect();
}
if (wasStreaming) DeviceStreamOn();
Notifier::GetInstance().NotifySource(*this,
CS_SOURCE_VIDEOMODE_CHANGED);
Notifier::GetInstance().NotifySourceVideoMode(*this, newMode);
lock.lock();
} else if (newMode.fps != m_mode.fps) {
m_mode = newMode;
@@ -639,8 +638,7 @@ CS_StatusValue UsbCameraImpl::DeviceCmdSetMode(
if (wasStreaming) DeviceStreamOff();
DeviceSetFPS();
if (wasStreaming) DeviceStreamOn();
Notifier::GetInstance().NotifySource(*this,
CS_SOURCE_VIDEOMODE_CHANGED);
Notifier::GetInstance().NotifySourceVideoMode(*this, newMode);
lock.lock();
}
@@ -873,7 +871,7 @@ void UsbCameraImpl::DeviceCacheMode() {
if (formatChanged) DeviceSetMode();
if (fpsChanged) DeviceSetFPS();
Notifier::GetInstance().NotifySource(*this, CS_SOURCE_VIDEOMODE_CHANGED);
Notifier::GetInstance().NotifySourceVideoMode(*this, m_mode);
}
void UsbCameraImpl::DeviceCacheProperty(