dive icon indicating copy to clipboard operation
dive copied to clipboard

Multi-Cam Simultaneous Display [FEATURE]

Open BryonLewis opened this issue 3 years ago • 5 comments

Having multiple cameras side-by-side in the main viewing area instead of utilizing the drop-down tool.

Tasks:

  • Main geoJS context needs to be loaded multiple times
  • Includes multiple loading of Image/Video annotators, each Media Annotator has it's own source video/images.
  • Syncing of Media Annotators, current time/frame synchronization
  • A LayerManager for each camera connected to the proper dataset in the trackStore. So each camera view will draw it's own annotations in it's own GeoJS context/layers.
  • If the trackStore modifications are done properly the selection of a track should be handled in there.
  • May need to have the ability to create a new track for a specific camera instead of a generic new track. This may need some more thought as to implementation.

BryonLewis avatar Dec 21 '21 19:12 BryonLewis

I have technically started working on this already because it flowed naturally into what I was testing.

Currently I have modified the Vue Templates to create an AnnotationWrapper.vue which allows for multiple ImmageAnnotators.vue or multiple VideoAnnotators.vue to be loaded at once.

To get this working though useMediaController needed to be modified to support multiple cameras which required using Object[camera] keys for several of the components in useMediaController like the geoViewerRef, containerRef and others. I also modified the useMediaController symbol reference to create a new symbol for each individual camera. That way the LayerManayer.vue can request a specific camera's useMediaController through injectMediaController(camera) instead of a generic one.

Next up I need to modify the ControlContainer for the UI controlls. It has a fairly standard interface which uses injectMediaController to get back some universal functions like seek, nextFrame, prevFrame, setSpeed, pause/play which are actions that should be applied over all cameras instead of specific to individual cameras. I think I can take AnnotationWrapper collect the media controllers and create root function for seek, play/pause and the others which will call each of the individual camera's version of that function, This should hopefully make it so a single controller container can be used across multiple cameras (with the limit that the cameras are all the same length).

BryonLewis avatar Jan 19 '22 15:01 BryonLewis

Looking at this a bit more the ControlsContainer has a sub component called Controls which also injects the media controller to grab a few other items like lockedCamera and resetZoom so these need to be modified as well.

BryonLewis avatar Jan 19 '22 19:01 BryonLewis

Looking at it, I may have to do a thing where I inject(aggregateMediaController) and that is used for the reactivity purposes of communicating to the controllers properly.

BryonLewis avatar Jan 19 '22 21:01 BryonLewis

This morning I worked on getting true multiview to display properly. I was able to get 3 cameras up and loaded by modifying the loading procedure to use the camera name as a key and load it up.

Below is a brief summary of what it is doing right now:

Main annoyance with this was the chicken/egg problem with useMediaController. useMediaController was rewritten to contain camera indexes into the list of the geoViewRef (geoJS stuff), containerRef (used for sizing). Each camera annotator will call useMedaController.addCamera(cameraName) before calling useMediaController.initialize(cameraName) which will then use inject/project to add use<media-controller-${cameraName}> then the LayerManager can call injectMediaController(cameraName) to get access to correct geoViewerRef (geoJS context)

Finally a new context needed to be created for the unified controls. There is a computed property which takes all of the cameras mediaControllers and compiles their 'global' functions (seek, pause, play, prevFrame, nextFrame) into a single function which calls them all, as well as their global properties (frame, maxFrame, lockedCamera). There are things that need to be key-paired out like filename .

BryonLewis avatar Jan 20 '22 16:01 BryonLewis

Next Up:

  • [x] - Handle CSS/Sizing issues with the GeoViewer
  • [x] - Possibly Add a delimiter between them like a border
  • [x] - Handle the existing Dropdown tool removal or if it should be a toggle between different modes?
  • [ ] - Camera Selection based on selecting a track within the window probably needs to be handled as well.

BryonLewis avatar Jan 20 '22 19:01 BryonLewis