Is there any event to get video dimension if the video dimension refreshed?

Hi. One of the things you can try first is SystemConfigurationChangedIndication event. See ConfigUpdated sample.

Please subscribe to “VideoOS.Platform.Messaging.MessageId.System.SystemConfigurationChangedIndication” in ConfigurationMonitor.cs like this:

_obj = _messageCommunication.RegisterCommunicationFilter(SystemConfigurationChangedIndicationHandler, new VideoOS.Platform.Messaging.CommunicationIdFilter(VideoOS.Platform.Messaging.MessageId.System.SystemConfigurationChangedIndication));
  1. When you get this event, then you need to go through all your cameras and read resolutions. See the Camera Stream Resolution sample to see how we read resolution for camera.

Please ask us if you have a further question.

Hi Rie,

I found ImageDisplayedEvent in VideoViewerQuality sample

_imageViewerControl1.ImageDisplayedEvent += _imageViewerControl1_ImageDisplayedEvent;

void _imageViewerControl1_ImageDisplayedEvent(object sender, ImageDisplayedEventArgs e)

{

  textBoxInfo.Text = e.ImageTime.ToLongTimeString() + 

    ", Org=" + e.OriginalImageSize.Width + "x" + e.OriginalImageSize.Height + 

    ", Display=" + e.WindowSize.Width + "x" + e.WindowSize.Height;

}

Now I can get livestream time and image size from this event.

But in this Event the sender is not same as VideoOs.Platform.Client.ImageviewerWpfControl. Instead It is VideoOS.Platform.SDK.UI.PlatformImageViewerWpfControl,

So I can not check which ImageviewerWpfControl raised this event. [I have 16 ImageviewerWpfControls]

Is there any way to check which ImageviewerWpfControl raised this event?

In VideoViewerQuality sample I can get the parent by adding fallowing piece of code to the ImageDisplayedEvent

var trigger = sender as VideoOS.Platform.SDK.PlatformImageViewerControl;

  Panel panel = trigger.Parent as Panel;

But in the Wpf version i can not find VideoOS.Platform.SDK.UI.PlatformImageViewerWpfControl

Please help me to get the parent of ImageDisplayedEvent raiser.

Hi. Thank you for the report, Milestone development will investigate this symptom. Please keep eye on this question.

I looked into the code and as far as I can see the ImageViewerWpfControl.ImageDisplayed event has always provided the ImageViewerWpfControl itself in the sender argument to the event handler, so it seems to me that it is working as it should. I also tried with the PlaybackWpfUser sample and confirmed this.

We are using Milestone SDK 2017 R3 and in this ImageViewerWpfControl.ImageDisplayed event returns VideoOS.Platform.SDK.UI.PlatformImageViewerWpfControl

Please upgrade to later version of the SDK then. Preferably the latest one (MIP SDK 2019 R2). Later versions will still work with the older versions of the VMS (as long as they are still officially supported by Milestone).

Yes, MIP SDK 2019 R2 works as expected