Comparative Visualization Implementation
Overview
This document describes the current implementation for Comparative Visualization and Film-strip views in ParaView as desribed in the Comparative Visualization and Time-strip View.
Representations/Views
Representations/Views and replacements for Displays/ViewModules in ParaView 2.6. The motivation behind this redesign was to make it simple to create new views/representations esp for render views since based of the type of render view, we needed to create a different type of display which would support the data distribution pipeline, as needed by view. In the new design the representation hierarchy is independent of view hierarchy. The view provides the representations with a strategy for data-distribution-delivery pipeline based on the views requirements. This makes it possible to use same representations in all similar views irrespective of whether it is operating in client-server mode, tile-display mode etc.
Comparative Visualization
The new design implements the entire comparative visualization framework within a single view proxy (vtkSMComparativeViewProxy). Since all the windows used in the comparative viz will now be part of the same view, ParaView GUI puts all the windows in a single view pane as shown in following figure.
This means that unlike paraview 2, we don't have to go into a special limited functionality mode to view a comparative visualization. One can create sources, change display properties and all will simply be shown in the comparative view, just like any other view, except that comparative view will make it appear in a MxN grid. This is achieved by internally creating all the view proxies and linking them together, so that one the user interacts with one window in the grid, all windows are updated (not unlink camera linking among different views already supported in ParaView 3). When a new representation is added to the CV (Comparative Vis) view, it creates internal copies of the representation to put in each of the internal views. These representations are linked together as well, so that one user changes properties the representation that was added to the CV (eg. color, scale etc), all the internal copies are also updated.
Now, to create a useful parameter comparison, one needs to specify the parameter being varied alone each axis. Similar to ParaView 2, we will achieve this by allowing the user to create two animation cues (or tracks) for each axis (and only one track for film-strip view). Similar to editing an animation, the user can add key frames for change any parameter of any source/filter/reader along each axis. Once the animation cues to use are set, the CV internally plays the cues, caching the data produced at each step and showing that in a single internal view. All this editing of the animation cues will be done through a Comparative View Inspector, currently being developed.
Above is film strip view generated using the current implementation. Since the CV Inspector is not complete yet, one cannot set up the animation cues on the CV directly. However, for the above test, I created a animation track on the standard animation inspector and ran the following script in the python shell to use the track created on the animation scene for the CV and then generate the CV.
import paraview pxm = paraview.pyProxyManager() cview = pxm.GetProxy("view_modules", "ComparativeView1"); cview = pxm.GetProxy("view_modules", "ComparativeRenderView1"); scene = pxm.GetProxy("animation", "PVAnimationScene1"); cue = scene.GetProperty("Cues").GetProxy(0) cview.AddToXCues(cue); cview.UpdateVTKObjects(); sphere = paraview.GetProxy("sources", "SphereSource1"); sphere.SetRadius(1.1); # to overcome an update bug which will be fixed soon. cview.UpdateVisualization(); cview.StillRender();