In our current development of (CMS) Central Management System here we use Milestone SDK as the third party, in here we found there some delay and stuck when play live-stream Videos, even when there is only one video window is opened; In here we used WPF to develop our system and the Milestone Management Server version is 2021 R2 with SDK 21.2.0 .
Is there the same issue when you see live video on Smart Client without any complex installations?
No Sir, When we saw live video on Smart Client it very smooth。
There is the youtube link about the issue down below
(https://youtu.be/WoLBzjE4B64)
You can see that left screen is Milestone Smart Client, on the right side is our system using Milestone SDK to develop, playing same live video.
This is how we connect our CMS to Milestone SDK live video:
.
server_guid = dataSet.Tables[0].Rows[0][“server_guid”].ToString();
parent_guid = dataSet.Tables[0].Rows[0][“parent_guid”].ToString();
camera_guid = dataSet.Tables[0].Rows[0][“object_guid”].ToString();
Camera_address = dataSet.Tables[0].Rows[0][“address”].ToString();
Camera_Name = videoName;
if (_playbackFQID == null)
{
_playbackFQID = ClientControl.Instance.GeneratePlaybackController();
playbackWpfUser1.ShowTimeSpanControl = true;
playbackWpfUser1.ShowSpeedControl = true;
playbackWpfUser1.ShowTallUserControl = true;
EnvironmentManager.Instance.SendMessage(new VideoOS.Platform.Messaging.Message(
MessageId.SmartClient.PlaybackSkipModeCommand,
PlaybackSkipModeData.Skip), \_playbackFQID);
playbackWpfUser1.Init(_playbackFQID);
}
List list = Configuration.Instance.GetItemsByKind(Kind.Camera);
ServerId serverId = new ServerId(ServerId.CorporateRecordingServerType, dataSet.Tables[0].Rows[0][“server_host_name”].ToString(), “7563”, new Guid(server_guid));
serverId.UserContext = list[0].FQID.ServerId.UserContext;
ImageViewWpf1.CameraFQID = new FQID(serverId,
new Guid(parent_guid), new Guid(camera_guid), FolderType.No, Kind.Camera);
ImageViewWpf1.EnableMouseControlledPtz = true;
ImageViewWpf1.EnableBrowseMode = true;
ImageViewWpf1.EnableMousePtzEmbeddedHandler = true;
ImageViewWpf1.EnableDigitalZoom = true;
ImageViewWpf1.Selected = true;
ImageViewWpf1.EnableVisibleHeader = false;
ImageViewWpf1.PlaybackControllerFQID = _playbackFQID;
ImageViewWpf1.Initialize();
ImageViewWpf1.Connect();
playbackWpfUser1.SetCameras(new List() { ImageViewWpf1.CameraFQID });
ImageViewWpf1.StartLive();
ImageViewWpf1.SetVideoResolutionAndFps(RenderSize, 15);
ImageViewWpf1.UpdateStates();
If you want to see the video as smooth as Smart Client, it is important to use efficient video graphic card and use Hardware acceleration.
We assume that you are using ImageViewerWpfControl, so please set SetVideoQuality (int smoothBufferSize, int cpusToUtilize).
Note – In case to see video without delay, you cannot see video smoothly. On the other hand, to see video smoothly, you will see delay.