Using PlaybackWpfUserControl and ImageViewerWpfControl together to develop custom Playback Workspace.

The topic in the attached link is very much inline with my question but I just wanted some clarification. I am attempting to create a custom workspace that dynamically creates a view and will operate like playback. It appears that @Salvatore La Placa (Multicom s.r.l.)​ was able use a single PlaybackWpfUserControl to control two ImageViewerWpfControl controls in his question, but he only had an issue with the timeline. As I my intent is to hide the timeline and create a custom one, my first question more directed to @Salvatore La Placa (Multicom s.r.l.)​. Was this done with a single ViewItem containing all the controls? As the example code I have reviewed place both controls in a single ViewItem. This, will help me confirm what is possible.

UPDATE: Was able to create a single ViewItem/Plugin to that had a single PlaybackWpfUserControl controlling four ImageViewWpfControls configured with properties to four different cameras. So the question remains is it possible and how would one go about to having these controls placed in difference ViewItem/Plugins to facilitate a dynamic number of ImageViewWpfContols and to place these into a Workspace?

To put into context I am attempting to create a Workspace with a configurable view layout grid (Workspace properties to configure no image viewers). So I created custom ViewItemPlugin around the ImageViewerWpfControl and a separate ViewItemPlugin for the PlaybackWpfUserControl controlling the timeline and playback view of all the cameras in the different . This so I can use ViewAndLayoutItem.InsertViewItemPlugin to place the controls. I assume that if I can handle the life cycle of the objects correctly and utilise messaging this is possible.

Thus, generally to @Bo Ellegård Andersen (Milestone Systems)​ am I approaching this in the correct manner or is there a better approach? Any advice would be most appreciated. Thank you.

@Salvatore La Placa (Multicom s.r.l.)​ @Bo Ellegård Andersen (Milestone Systems)​

https://developer.milestonesys.com/s/question/0D50O000046I3stSAC/one-playbackwpfusercontrol-to-viewdrag-2-or-more-timelines-of-2-different-cameras

Hi Jose,

From your description it sounds to me like you are going in the right direction and have a fairly good understanding of what is going on.

But just to clarify: There is not as such any direct connection between ImageViewerWpfControls and PlaybackWpfUserControl. What connects them is that they both refer to a PlaybackController. PlaybackControllers are kept in an (internal) globally shared list in the Smart Client, so as long as they all refer to the same PlaybackController you can put the individual user controls pretty much wherever you want and they will still ‘work together’.

There is of course a consideration to be made about when and where to create the PlaybackController so that it is always available to the different view items, and also something about what to do if one of the user control types are not present at all (which is not as such a problem, but will make the remaining control fairly unusable), but especially in a workspace that should be pretty easy to handle.

Thanks Peter,

This helps clarify things for me. So in principle once I have the ImageViewerWpfControls and PlaybackWpfUserControl binded with the PlaybackController, we just need to update the Camera sources dynamically via ImageViewerWpfControl methods/properties Disconnect(), CameraFQID, Initialize(), Connect() and PlaybackWpfUserControl via SetCameras.

As this stage I believe I may have to drop the use of PlaybackWpfUserControl as my requirement involves going through a list of analytical events that our solution creates and dynamically connect ImageViewerWpfControls to cameras for each of these periods. I have raised another Topic along the lines how we customise the PlaybackWpfUserControl as I would need it to navigate through a list of our events, but have found that the PlaybackWpfUserControl is sealed.