I have designed a custom view in SmartClient application including some cameras and I need to change some of the view’s cameras based on my running application decision.
(I am using MIP SDK)
The steps that I have done:
EnvironmentManager.Instance.RegisterReceiver(ViewChangedHandler, new MessageIdFilter(MessageId.SmartClient.SetCameraInViewCommand));
OR
MessageCommunicationManager.Start(EnvironmentManager.Instance.MasterSite.ServerId);
MessageCommunication \_messageCommunication = MessageCommunicationManager.Get(EnvironmentManager.Instance.MasterSite.ServerId);
\_messageCommunication.RegisterCommunicationFilter(ChangedAlarmMessageHandler,
new VideoOS.Platform.Messaging.CommunicationIdFilter(VideoOS.Platform.Messaging.MessageId.SmartClient.SetCameraInViewCommand), null, EndPointType.Server);
EnvironmentManager.Instance.SendMessage(new Message(MessageId.SmartClient.SetCameraInViewCommand, new SetCameraInViewCommandData()
{
Index = 1,
CameraFQID = \_cameraitem.FQID,
StreamId = streamId
}));
I expected the camera index 1 in my view change to a new camera, but nothing happened?
any Idea how to get this working?