| IGLib 1.7.2 The IGLib base library for development of numerical, technical and business applications.

- Main Page
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Events Macros
Static Public Member Functions | List of all members
IG.Gr3d.UtilVtk Class Reference

Various VTK utilities that extend functionality of the ActiViz VTK wrappers. More...

## Static Public Member Functions
static bool | ContainsActor (vtkRenderer renderer, vtkActor actor)
| Returns true if the specified renderer contains the specified actor. More...
static vtkActor | GetFirstActor (vtkRenderer renderer)
| Returns the first non-null VTK actor contained in the specified vtkRenderer object. More...
static int | GetNumActors (vtkRenderer renderer)
| Returns number of actors contained on the specified vtkRenderer object. If the specified renderer is null then 0 returned. More...
static List< vtkActor > | GetActors (vtkRenderer renderer)
| Returns a list of all non-null renderers contained in the specified vtkRenderWindow object. If VTK render window is null then an empty list is returned. More...
static vtkActor[] | GetActorsArray (vtkRenderer renderer)
| Returns an array of all non-null actors contained in the specified vtkRenderer object. If the specified VTK renderer is null then an empty array is returned. More...
static void | RemoveAllActors (vtkRenderer renderer)
| Removes all actors form the specified renderer. More...
static bool | ContainsActor2D (vtkRenderer renderer, vtkActor2D actor2D)
| Returns true if the specified renderer contains the specified actor2D. More...
static vtkActor2D | GetFirstActor2D (vtkRenderer renderer)
| Returns the first non-null VTK actor2D contained in the specified vtkRenderer object. More...
static int | GetNumActors2D (vtkRenderer renderer)
| Returns number of actors2D contained on the specified vtkRenderer object. If the specified renderer is null then 0 returned. More...
static List< vtkActor2D > | GetActors2D (vtkRenderer renderer)
| Returns a list of all non-null renderers contained in the specified vtkRenderWindow object. If VTK render window is null then an empty list is returned. More...
static vtkActor2D[] | GetActors2DArray (vtkRenderer renderer)
| Returns an array of all non-null actors2D contained in the specified vtkRenderer object. If the specified VTK renderer is null then an empty array is returned. More...
static void | RemoveAllActors2D (vtkRenderer renderer)
| Removes all actors form the specified renderer. More...
static bool | ContainsRenderer (vtkRenderWindow window, vtkRenderer renderer)
| Returns true if the specified renderer window contains the specified renderer. More...
static vtkRenderer | GetFirstRenderer (vtkRenderWindow win)
| Returns the first non-null VTK renderrer contained in the specified vtkRenderWindow object. More...
static int | GetNumRenderers (vtkRenderWindow win)
| Returns number of renderers contained on the specified vtkRenderWindow object. If VTK render window is null then 0 returned. More...
static List< vtkRenderer > | GetRenderers (vtkRenderWindow win)
| Returns a list of all non-null renderers contained in the specified vtkRenderWindow object. If VTK render window is null then an empty list is returned. More...
static vtkRenderer[] | GetRenderersArray (vtkRenderWindow win)
| Returns an array of all non-null renderers contained in the specified vtkRenderWindow object. If the specified VTK render window is null then an empty array is returned. More...
static void | SetBounds (vtkCubeAxesActor actor, IBoundingBox bounds)
static BoundingBox | CreateBounds (params vtkRenderer[] renderers)
| Creates and returns the minimal volume bounding box that contains all graphical objects of the specified vtkRenderer. More...
static void | UpdateBounds (IBoundingBox bounds, params vtkRenderer[] renderers)
| Updates the specified bounding box in such a way that it also contains all graphic primitives of the specified VTK Renderers. More...
static void | UpdateBounds (ref IBoundingBox bounds, params vtkRenderer[] renderers)
| Updates the specified bounding box in such a way that it also contains all graphic primitives of the specified VTK Renderers. More...
static BoundingBox | CreateBounds (params vtkActor[] actors)
| Creates and returns the minimal volume bounding box that contains all graphical objects of the specified vtkActor. More...
static void | UpdateBounds (IBoundingBox bounds, params vtkActor[] actors)
| Updates the specified bounding box in such a way that it also contains all graphic primitives of the specified VTK Actors. More...
static void | UpdateBounds (ref IBoundingBox bounds, params vtkActor[] actors)
| Updates the specified bounding box in such a way that it also contains all graphic primitives of the specified VTK Actor. More...
static bool | IsVtkForm (this IVtkFormContainer control)
| Returns a boolean value telling whether the specified object of type IVtkFormContainer actually contains a VTK rendering control (type RenderWindowControl). More...
static Kitware.VTK.RenderWindowControl | GetVtkRenderWindowControl (this IVtkFormContainer control)
  | Returns a VTK rendering control of type Kitware.VTK.RenderWindowControl that is contained in the specified object, or null if such a control is not contained or is null. Parameters
  control | Control (or more generally control container) whose rendering control is attempted to be returned.
More...
static Kitware.VTK.vtkRenderWindow | GetVtkRenderWindow (this IVtkFormContainer control)
  | Returns a VTK rendering window of type Kitware.VTK.vtkRenderWindow that is contained in the specified object, or null if such a control is not contained or is null. Parameters
  control | Control (or more generally control container) whose rendering window is attempted to be returned.
More...
static Kitware.VTK.vtkRenderer | GetVtkRenderer (this IVtkFormContainer control)
  | Returns a VTK renderer of type Kitware.VTK.vtkRenderer that is contained in the specified object, or null if such a VTK render control is not contained or its renderer is null. Parameters
  control | Control (or more generally control container) whose VTK renderer is attempted to be returned.
More...
static Kitware.VTK.vtkCamera | GetVtkCamera (this IVtkFormContainer control)
  | Returns the active VTK camera of type Kitware.VTK.vtkCamera that is contained in the specified object, or null if VTK render control is not contained or its camera is null. Parameters
  control | Control (or more generally control container) whose VTK camera is attempted to be returned.
More...
static void | LookUpTableRange (ColorScale scalarBarColorScale, int numValues, ref vtkLookupTable ScalarBarLookUpTable)
| Transform colorScale range to LookUpTable range directly. More...
static void | LookUpTableRange (ColorScale scalarBarColorScale, int numValues, double minRangeLT, double maxRangeLT, ref vtkLookupTable ScalarBarLookUpTable)
| Transform colorScale range to LookUpTable range. Ranges are different. More...

## Detailed Description

Various VTK utilities that extend functionality of the ActiViz VTK wrappers.

$A Igor Sep11;

## Member Function Documentation

static bool IG.Gr3d.UtilVtk.ContainsActor | ( | vtkRenderer | renderer,
|  | vtkActor | actor
| ) |  |
| inline static

Returns true if the specified renderer contains the specified actor.

Parameters

  renderer | Vtk renderer that is queried for containing the specified actor.
  actor | Actor for which we querry whether it is contained.

Referenced by IG.Gr3d.VtkPlotter.AddActor(), and IG.Gr3d.VtkPlotter.RemoveActor().

static vtkActor IG.Gr3d.UtilVtk.GetFirstActor | ( | vtkRenderer | renderer | ) |
| inline static

Returns the first non-null VTK actor contained in the specified vtkRenderer object.

Parameters

  renderer | VTK renderer window (type) vtkRenderWindow for which a contained renderer is returned.

static int IG.Gr3d.UtilVtk.GetNumActors | ( | vtkRenderer | renderer | ) |
| inline static

Returns number of actors contained on the specified vtkRenderer object. If the specified renderer is null then 0 returned.

Parameters

  win | VTK renderer (type vtkRenderer) for which the number of contained actors is returned.

static List<vtkActor> IG.Gr3d.UtilVtk.GetActors | ( | vtkRenderer | renderer | ) |
| inline static

Returns a list of all non-null renderers contained in the specified vtkRenderWindow object. If VTK render window is null then an empty list is returned.

Parameters

  win | VTK renderer window (type) vtkRenderWindow for which a list of contained renderers is returned.

static vtkActor [] IG.Gr3d.UtilVtk.GetActorsArray | ( | vtkRenderer | renderer | ) |
| inline static

Returns an array of all non-null actors contained in the specified vtkRenderer object. If the specified VTK renderer is null then an empty array is returned.

Parameters

  renderer | VTK renderer (type vtkRenderer) for which an array of contained renderers is returned.

static void IG.Gr3d.UtilVtk.RemoveAllActors | ( | vtkRenderer | renderer | ) |
| inline static

Removes all actors form the specified renderer.

Parameters

  renderer | The renderer from which all actors are removed.

Referenced by IG.Gr3d.VtkPlotter.RemoveAllActors().

static bool IG.Gr3d.UtilVtk.ContainsActor2D | ( | vtkRenderer | renderer,
|  | vtkActor2D | actor2D
| ) |  |
| inline static

Returns true if the specified renderer contains the specified actor2D.

Parameters

  renderer | Vtk renderer that is queried for containing the specified actor2D.
  actor | Actor2D for which we querry whether it is contained.

$A Igor Oct11, Tako78 Dec13;

Referenced by IG.Gr3d.VtkPlotter.AddActor2D(), and IG.Gr3d.VtkPlotter.RemoveActor2D().

static vtkActor2D IG.Gr3d.UtilVtk.GetFirstActor2D | ( | vtkRenderer | renderer | ) |
| inline static

Returns the first non-null VTK actor2D contained in the specified vtkRenderer object.

Parameters

  renderer | VTK renderer window (type) vtkRenderWindow for which a contained renderer is returned.

$A Igor Oct11, Tako78 Dec13;

static int IG.Gr3d.UtilVtk.GetNumActors2D | ( | vtkRenderer | renderer | ) |
| inline static

Returns number of actors2D contained on the specified vtkRenderer object. If the specified renderer is null then 0 returned.

Parameters

  win | VTK renderer (type vtkRenderer) for which the number of contained actors2D is returned.

$A Igor Oct11, Tako78 Dec13;

static List<vtkActor2D> IG.Gr3d.UtilVtk.GetActors2D | ( | vtkRenderer | renderer | ) |
| inline static

Returns a list of all non-null renderers contained in the specified vtkRenderWindow object. If VTK render window is null then an empty list is returned.

Parameters

  win | VTK renderer window (type) vtkRenderWindow for which a list of contained renderers is returned.

$A Igor Oct11, Tako78 Dec13;

static vtkActor2D [] IG.Gr3d.UtilVtk.GetActors2DArray | ( | vtkRenderer | renderer | ) |
| inline static

Returns an array of all non-null actors2D contained in the specified vtkRenderer object. If the specified VTK renderer is null then an empty array is returned.

Parameters

  renderer | VTK renderer (type vtkRenderer) for which an array of contained renderers is returned.

$A Igor Oct11, Tako78 Dec13;

static void IG.Gr3d.UtilVtk.RemoveAllActors2D | ( | vtkRenderer | renderer | ) |
| inline static

Removes all actors form the specified renderer.

Parameters

  renderer | The renderer from which all actors are removed.

Referenced by IG.Gr3d.VtkPlotter.RemoveAllActor2Ds().

static bool IG.Gr3d.UtilVtk.ContainsRenderer | ( | vtkRenderWindow | window,
|  | vtkRenderer | renderer
| ) |  |
| inline static

Returns true if the specified renderer window contains the specified renderer.

Parameters

  renderer | Vtk renderer window that is queried for containing the specified renderer.
  actor | Renderer for which we querry whether it is contained.

Referenced by IG.Gr3d.VtkPlotter.AddRenderer().

static vtkRenderer IG.Gr3d.UtilVtk.GetFirstRenderer | ( | vtkRenderWindow | win | ) |
| inline static

Returns the first non-null VTK renderrer contained in the specified vtkRenderWindow object.

Parameters

  win | VTK renderer window (type vtkRenderWindow) for which a contained renderer is returned.

Returns

static int IG.Gr3d.UtilVtk.GetNumRenderers | ( | vtkRenderWindow | win | ) |
| inline static

Returns number of renderers contained on the specified vtkRenderWindow object. If VTK render window is null then 0 returned.

Parameters

  win | VTK renderer window (type vtkRenderWindow) for which the number of contained renderers is returned.

Referenced by IG.Gr3d.VtkPlotter.AddRenderer().

static List<vtkRenderer> IG.Gr3d.UtilVtk.GetRenderers | ( | vtkRenderWindow | win | ) |
| inline static

Returns a list of all non-null renderers contained in the specified vtkRenderWindow object. If VTK render window is null then an empty list is returned.

Parameters

  win | VTK renderer window (type vtkRenderWindow) for which a list of contained renderers is returned.

Referenced by IG.Gr3d.VtkPlotter.GetRendererIndex(), IG.Gr3d.VtkPlotter.RemoveActor(), IG.Gr3d.VtkPlotter.RemoveActor2D(), IG.Gr3d.VtkPlotter.RemoveAllActor2Ds(), and IG.Gr3d.VtkPlotter.RemoveAllActors().

static vtkRenderer [] IG.Gr3d.UtilVtk.GetRenderersArray | ( | vtkRenderWindow | win | ) |
| inline static

Returns an array of all non-null renderers contained in the specified vtkRenderWindow object. If the specified VTK render window is null then an empty array is returned.

Parameters

  win | VTK renderer window (type vtkRenderWindow) for which an array of contained renderers is returned.

static void IG.Gr3d.UtilVtk.SetBounds | ( | vtkCubeAxesActor | actor,
|  | IBoundingBox | bounds
| ) |  |
| inline static

References IG.Num.IBoundingBox.Dimension, IG.Num.IBoundingBox.GetMax(), and IG.Num.IBoundingBox.GetMin().

Referenced by IG.Gr3d.TestVtkGraphicBase.ExampleAxisHendler(), and IG.Gr3d.TestVtkGraphicBase.ExampleStructuredGrid().

static BoundingBox IG.Gr3d.UtilVtk.CreateBounds | ( | params vtkRenderer[] | renderers | ) |
| inline static

Creates and returns the minimal volume bounding box that contains all graphical objects of the specified vtkRenderer.

Parameters

  actors | vtkRendererobjects for which the bounding box is created. Must not be null or empty array.

Referenced by IG.Gr3d.TestVtkGraphicBase.ExampleAxisHendler(), and IG.Gr3d.TestVtkGraphicBase.ExampleStructuredGrid().

static void IG.Gr3d.UtilVtk.UpdateBounds | ( | IBoundingBox | bounds,
|  | params vtkRenderer[] | renderers
| ) |  |
| inline static

Updates the specified bounding box in such a way that it also contains all graphic primitives of the specified VTK Renderers.

Parameters

  renderers | VTK Renderers for which the bounding box is eventually resized in such a way that the renderers fit in it. All non-null elements must have the same dimension.
  bounds | Bounding box to be updated. It must be allocated and of the same dimension as the VTK actor according to which the bounding box is updated.

Referenced by IG.Gr3d.TestVtkGraphicBase.ExampleQuadCells(), and IG.Gr3d.VtkDecorationHandler.UpdateBoundsInternal().

static void IG.Gr3d.UtilVtk.UpdateBounds | ( | ref IBoundingBox | bounds,
|  | params vtkRenderer[] | renderers
| ) |  |
| inline static

Updates the specified bounding box in such a way that it also contains all graphic primitives of the specified VTK Renderers.

Parameters

  renderers | VTK Renderers for which the bounding box is eventually resized in such a way that the renderers fit in it. All non-null elements must have the same dimension.
  bounds | Bounding box to be updated. It must be allocated and of the same dimension as the VTK actor according to which the bounding box is updated.

static BoundingBox IG.Gr3d.UtilVtk.CreateBounds | ( | params vtkActor[] | actors | ) |
| inline static

Creates and returns the minimal volume bounding box that contains all graphical objects of the specified vtkActor.

Parameters

  actors | vtkActorobjects for which the bounding box is created. Must not be null or empty array.

static void IG.Gr3d.UtilVtk.UpdateBounds | ( | IBoundingBox | bounds,
|  | params vtkActor[] | actors
| ) |  |
| inline static

Updates the specified bounding box in such a way that it also contains all graphic primitives of the specified VTK Actors.

Parameters

  actors | VTK Actors for which the bounding box is eventually resized in such a way that the actor fits in it. If different than null then the first element must not be null. All non-null elements must have the same dimension.
  bounds | Bounding box to be updated. It must be allocated and of the same dimension as the VTK actor according to which the bounding box is updated.

References IG.Num.IBoundingBox.Dimension, and IG.Num.IBoundingBox.Update().

static void IG.Gr3d.UtilVtk.UpdateBounds | ( | ref IBoundingBox | bounds,
|  | params vtkActor[] | actors
| ) |  |
| inline static

Updates the specified bounding box in such a way that it also contains all graphic primitives of the specified VTK Actor.

Parameters

  actors | VTK Actor for which the bounding box is eventually resized in such a way that the actor fits in it. If null then noting happens.
  bounds | Bounding box to be updated. If allocated then it must be of the same dimension as actors .

Exceptions

  ArgumentException | When bounding box is not of the same dimension than actors and actors is different than 0.

static bool IG.Gr3d.UtilVtk.IsVtkForm | ( | this IVtkFormContainer | control | ) |
| inline static

Returns a boolean value telling whether the specified object of type IVtkFormContainer actually contains a VTK rendering control (type RenderWindowControl).

Parameters

  control | Control (or more generally control container) that is checked.

There is a possibility that its appropriate sub-control is of another type such as Panel, and the object just emulates a container of VTK render control. This may be the case because of conditional compilation, which enables manipulation of forms by form designer, since the VTK form is not compatible with the designer.

References IG.Gr3d.IVtkFormContainerGen< VtkControlType >.VtkRenderWindowControl.

static Kitware.VTK.RenderWindowControl IG.Gr3d.UtilVtk.GetVtkRenderWindowControl | ( | this IVtkFormContainer | control | ) |
| inline static

Returns a VTK rendering control of type Kitware.VTK.RenderWindowControl that is contained in the specified object, or null if such a control is not contained or is null.

Parameters

  control | Control (or more generally control container) whose rendering control is attempted to be returned.

There is a possibility that its appropriate sub-control is of another type such as Panel, and the object just emulates a container of VTK render control. This may be the case because of conditional compilation, which enables manipulation of forms by form designer, since the VTK form is not compatible with the designer.

References IG.Gr3d.IVtkFormContainerGen< VtkControlType >.VtkRenderWindowControl.

static Kitware.VTK.vtkRenderWindow IG.Gr3d.UtilVtk.GetVtkRenderWindow | ( | this IVtkFormContainer | control | ) |
| inline static

Returns a VTK rendering window of type Kitware.VTK.vtkRenderWindow that is contained in the specified object, or null if such a control is not contained or is null.

Parameters

  control | Control (or more generally control container) whose rendering window is attempted to be returned.

There is a possibility that its appropriate sub-control is of another type such as Panel, and the object just emulates a container of VTK render control. This may be the case because of conditional compilation, which enables manipulation of forms by form designer, since the VTK form is not compatible with the designer.

References IG.Gr3d.IVtkFormContainerGen< VtkControlType >.VtkRenderWindowControl.

static Kitware.VTK.vtkRenderer IG.Gr3d.UtilVtk.GetVtkRenderer | ( | this IVtkFormContainer | control | ) |
| inline static

Returns a VTK renderer of type Kitware.VTK.vtkRenderer that is contained in the specified object, or null if such a VTK render control is not contained or its renderer is null.

Parameters

  control | Control (or more generally control container) whose VTK renderer is attempted to be returned.

There is a possibility that its appropriate sub-control is of another type such as Panel, and the object just emulates a container of VTK render control. This may be the case because of conditional compilation, which enables manipulation of forms by form designer, since the VTK form is not compatible with the designer.

References IG.Gr3d.IVtkFormContainerGen< VtkControlType >.VtkRenderWindowControl.

static Kitware.VTK.vtkCamera IG.Gr3d.UtilVtk.GetVtkCamera | ( | this IVtkFormContainer | control | ) |
| inline static

Returns the active VTK camera of type Kitware.VTK.vtkCamera that is contained in the specified object, or null if VTK render control is not contained or its camera is null.

Parameters

  control | Control (or more generally control container) whose VTK camera is attempted to be returned.

There is a possibility that its appropriate sub-control is of another type such as Panel, and the object just emulates a container of VTK render control. This may be the case because of conditional compilation, which enables manipulation of forms by form designer, since the VTK form is not compatible with the designer.

References IG.Gr3d.IVtkFormContainerGen< VtkControlType >.VtkRenderWindowControl.

static void IG.Gr3d.UtilVtk.LookUpTableRange | ( | ColorScale | scalarBarColorScale,
|  | int | numValues,
|  | ref vtkLookupTable | ScalarBarLookUpTable
| ) |  |
| inline static

Transform colorScale range to LookUpTable range directly.

Parameters

  scalarBarColorScale | Color scale.
  numValues | Number of cells in ScalarBar.
  ScalarBarLookUpTable | LookUpTable

Tako78 Dec23;

References IG.Lib.ColorScale.MaxValue, and IG.Lib.ColorScale.MinValue.

static void IG.Gr3d.UtilVtk.LookUpTableRange | ( | ColorScale | scalarBarColorScale,
|  | int | numValues,
|  | double | minRangeLT,
|  | double | maxRangeLT,
|  | ref vtkLookupTable | ScalarBarLookUpTable
| ) |  |
| inline static

Transform colorScale range to LookUpTable range. Ranges are different.

Parameters

  scalarBarColorScale | Color scale.
  numValues | Number of cells in ScalarBar.
  minRangeLT | Minimum range in LookUpTable.
  maxRangeLT | Maximum range in LookUpTable.
  ScalarBarLookUpTable | LookUpTable

Tako78 Dec23;

References IG.Lib.color.B, IG.Lib.color.G, IG.Lib.ColorScaleBase.GetColor(), IG.Lib.ColorScale.MaxValue, IG.Lib.ColorScale.MinValue, IG.Lib.color.Opacity, and IG.Lib.color.R.

The documentation for this class was generated from the following file:

- extensions/igplot3d/plot3d/vtkbased/UtilVtk.cs