File: vtkparallelrendermanager.mdc

package info (click to toggle)
freemat 4.2%2Bdfsg1-4
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 141,800 kB
  • ctags: 14,082
  • sloc: ansic: 126,788; cpp: 62,046; python: 2,080; perl: 1,255; sh: 1,146; yacc: 1,019; lex: 239; makefile: 100
file content (421 lines) | stat: -rw-r--r-- 21,356 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421

 Usage

vtkParallelRenderManager operates in multiple processes. It
provides proper renderers and render windows for performing
the parallel rendering correctly. It can also attach itself
to render windows and propagate rendering events and camera
views.
.SECTION Note: Many parallel rendering schemes do not
correctly handle transparency. Unless otherwise documented,
assume a sub class does not.
.SECTION ToDo: Synchronization/barrier primitives.
Query ranges of scalar values of objects in addition to the
boundry in three-space
To create an instance of class vtkParallelRenderManager,
simply invoke its constructor as follows

    obj = vtkParallelRenderManager



 Methods

The class vtkParallelRenderManager has several methods that
can be used. They are listed below. Note that the
documentation is translated automatically from the VTK
sources, and may not be completely intelligible. When in
doubt, consult the VTK website. In the methods listed below,
obj is an instance of the vtkParallelRenderManager class.

* string = obj.GetClassName ()
* int = obj.IsA (string name)
* vtkParallelRenderManager = obj.NewInstance ()
* vtkParallelRenderManager = obj.SafeDownCast (vtkObject o)
* vtkRenderWindow = obj.MakeRenderWindow () - Builds a
  vtkRenderWindow compatible with this render manager. The
  user program is responsible for registering the render
  window with the SetRenderWindow method and calling Delete.
  It is not advisable to use a parallel render manager with
  a render window that was not built with this method.
* vtkRenderer = obj.MakeRenderer () - Builds a vtkRenderer
  compatible with this render manager. (Should we also
  register it?) The user program is responsible for calling
  Delete. It is not advisable to use a parallel render
  manager with a renderer that was not built with this
  method.
* vtkRenderWindow = obj.GetRenderWindow () - Set/Get the
  RenderWindow to use for compositing. We add a start and
  end observer to the window.
* obj.SetRenderWindow (vtkRenderWindow renWin) - Set/Get the
  RenderWindow to use for compositing. We add a start and
  end observer to the window.
* vtkMultiProcessController = obj.GetController () - Set/Get
  the vtkMultiProcessController which will handle
  communications for the parallel rendering.
* obj.SetController (vtkMultiProcessController controller) -
  Set/Get the vtkMultiProcessController which will handle
  communications for the parallel rendering.
* obj.InitializePieces () - This method sets the piece and
  number of pieces for each actor with a polydata mapper.
* obj.InitializeOffScreen () - Make all rendering windows
  not viewable set as off screen rendering. To make all
  renderwindows on screen rendering again, call
  OffScreenRenderingOff on all the render windows. This
  class assumes the window on root node is the only one
  viewable. Subclasses should change this as necessary.
* obj.StartInteractor () - Initializes the RMIs and then, if
  on root node, starts the interactor on the attached render
  window. Otherwise, starts processing RMIs. When the
  interactor returns, it breaks the RMI listening on all
  other processors.
* obj.StartServices () - If on node other than root, starts
  serving RMI requests for parallel renders.
* obj.StopServices () - If on root node, stops the RMI
  processing on all service nodes.
* obj.StartRender () - Callbacks that initialize and finish
  rendering and other tasks.
* obj.EndRender () - Callbacks that initialize and finish
  rendering and other tasks.
* obj.SatelliteStartRender () - Callbacks that initialize
  and finish rendering and other tasks.
* obj.SatelliteEndRender () - Callbacks that initialize and
  finish rendering and other tasks.
* obj.RenderRMI () - Callbacks that initialize and finish
  rendering and other tasks.
* obj.ResetCamera (vtkRenderer ren) - Callbacks that
  initialize and finish rendering and other tasks.
* obj.ResetCameraClippingRange (vtkRenderer ren) - Callbacks
  that initialize and finish rendering and other tasks.
* obj.ComputeVisiblePropBoundsRMI (int renderId) - Callbacks
  that initialize and finish rendering and other tasks.
* obj.InitializeRMIs ()
* obj.ResetAllCameras () - Resets the camera of each
  renderer contained in the RenderWindow. Should only be
  called in the "root" process, and all remote processes
  must be processing RMIs for this method to complete.
* obj.ComputeVisiblePropBounds (vtkRenderer ren, double
  bounds[6]) - Calculates the bounds by gathering
  information from all processes.
* obj.SetParallelRendering (int ) - Turns on/off parallel
  rendering. When on (the default) the object responds to
  render events of the attached window, propagates the
  render event to other processors, and otherwise enables
  the parallel rendering process.
* int = obj.GetParallelRendering () - Turns on/off parallel
  rendering. When on (the default) the object responds to
  render events of the attached window, propagates the
  render event to other processors, and otherwise enables
  the parallel rendering process.
* obj.ParallelRenderingOn () - Turns on/off parallel
  rendering. When on (the default) the object responds to
  render events of the attached window, propagates the
  render event to other processors, and otherwise enables
  the parallel rendering process.
* obj.ParallelRenderingOff () - Turns on/off parallel
  rendering. When on (the default) the object responds to
  render events of the attached window, propagates the
  render event to other processors, and otherwise enables
  the parallel rendering process.
* obj.SetRenderEventPropagation (int ) - Turns on/off render
  event propagation. When on (the default) and
  ParallelRendering is on, process 0 will send an RMI call
  to all remote processes to perform a synchronized render.
  When off, render must be manually called on each process.
* int = obj.GetRenderEventPropagation () - Turns on/off
  render event propagation. When on (the default) and
  ParallelRendering is on, process 0 will send an RMI call
  to all remote processes to perform a synchronized render.
  When off, render must be manually called on each process.
* obj.RenderEventPropagationOn () - Turns on/off render
  event propagation. When on (the default) and
  ParallelRendering is on, process 0 will send an RMI call
  to all remote processes to perform a synchronized render.
  When off, render must be manually called on each process.
* obj.RenderEventPropagationOff () - Turns on/off render
  event propagation. When on (the default) and
  ParallelRendering is on, process 0 will send an RMI call
  to all remote processes to perform a synchronized render.
  When off, render must be manually called on each process.
* obj.SetUseCompositing (int ) - This is used for tiled
  display rendering. When data has been duplicated on all
  processes, then we do not need to compositing. Cameras and
  renders are still propagated though.
* int = obj.GetUseCompositing () - This is used for tiled
  display rendering. When data has been duplicated on all
  processes, then we do not need to compositing. Cameras and
  renders are still propagated though.
* obj.UseCompositingOn () - This is used for tiled display
  rendering. When data has been duplicated on all processes,
  then we do not need to compositing. Cameras and renders
  are still propagated though.
* obj.UseCompositingOff () - This is used for tiled display
  rendering. When data has been duplicated on all processes,
  then we do not need to compositing. Cameras and renders
  are still propagated though.
* obj.SetImageReductionFactor (double factor) - Set/Get the
  reduction factor (for sort-last based parallel renderers).
  The size of rendered image is divided by the reduction
  factor and then is blown up to the size of the current
  vtkRenderWindow. Setting higher reduction factors enables
  shorter image transfer times (which is often the
  bottleneck) but will greatly reduce image quality. A
  reduction factor of 2 or greater should only be used for
  intermediate images in interactive applications. A
  reduction factor of 1 (or less) will result in no change
  in image quality. A parallel render manager may ignore the
  image reduction factor if it will result in little or no
  performance enhancements (eg. it does not do image space
  manipulations).
* double = obj.GetImageReductionFactor () - Set/Get the
  reduction factor (for sort-last based parallel renderers).
  The size of rendered image is divided by the reduction
  factor and then is blown up to the size of the current
  vtkRenderWindow. Setting higher reduction factors enables
  shorter image transfer times (which is often the
  bottleneck) but will greatly reduce image quality. A
  reduction factor of 2 or greater should only be used for
  intermediate images in interactive applications. A
  reduction factor of 1 (or less) will result in no change
  in image quality. A parallel render manager may ignore the
  image reduction factor if it will result in little or no
  performance enhancements (eg. it does not do image space
  manipulations).
* obj.SetMaxImageReductionFactor (double )
* double = obj.GetMaxImageReductionFactor ()
* obj.SetImageReductionFactorForUpdateRate (double
  DesiredUpdateRate) - Sets the ReductionFactor based on the
  given desired update rate and the rendering metrics taken
  from the last time UpdateServerInfo was called. Note that
  if AutoReductionFactor is on, this function is called with
  the desired update rate of the render window
  automatically.
* obj.SetAutoImageReductionFactor (int ) - If on, the
  ReductionFactor is automatically adjusted to best meet the
  the DesiredUpdateRate in the current RenderWindow based on
  metrics from the last render.
* int = obj.GetAutoImageReductionFactor () - If on, the
  ReductionFactor is automatically adjusted to best meet the
  the DesiredUpdateRate in the current RenderWindow based on
  metrics from the last render.
* obj.AutoImageReductionFactorOn () - If on, the
  ReductionFactor is automatically adjusted to best meet the
  the DesiredUpdateRate in the current RenderWindow based on
  metrics from the last render.
* obj.AutoImageReductionFactorOff () - If on, the
  ReductionFactor is automatically adjusted to best meet the
  the DesiredUpdateRate in the current RenderWindow based on
  metrics from the last render.
* double = obj.GetRenderTime () - Get rendering metrics.
* double = obj.GetImageProcessingTime () - Get rendering
  metrics.
* int = obj.GetSyncRenderWindowRenderers () - By default,
  the state of all renderers in the root's render window is
  propagated to the rest of the processes. In order for this
  to work, all render windows must have the same renderers
  in the same order. If this is not the case, you can turn
  off the SyncRenderWindowRenderers. When this flag is off,
  the list of renderers held by this parallel render manager
  (initially empty) is synced. You can modify the list of
  renderers with the AddRenderer, RemoveRenderer, and
  RemoveAllRenderers methods.
* obj.SetSyncRenderWindowRenderers (int ) - By default, the
  state of all renderers in the root's render window is
  propagated to the rest of the processes. In order for this
  to work, all render windows must have the same renderers
  in the same order. If this is not the case, you can turn
  off the SyncRenderWindowRenderers. When this flag is off,
  the list of renderers held by this parallel render manager
  (initially empty) is synced. You can modify the list of
  renderers with the AddRenderer, RemoveRenderer, and
  RemoveAllRenderers methods.
* obj.SyncRenderWindowRenderersOn () - By default, the state
  of all renderers in the root's render window is propagated
  to the rest of the processes. In order for this to work,
  all render windows must have the same renderers in the
  same order. If this is not the case, you can turn off the
  SyncRenderWindowRenderers. When this flag is off, the list
  of renderers held by this parallel render manager
  (initially empty) is synced. You can modify the list of
  renderers with the AddRenderer, RemoveRenderer, and
  RemoveAllRenderers methods.
* obj.SyncRenderWindowRenderersOff () - By default, the
  state of all renderers in the root's render window is
  propagated to the rest of the processes. In order for this
  to work, all render windows must have the same renderers
  in the same order. If this is not the case, you can turn
  off the SyncRenderWindowRenderers. When this flag is off,
  the list of renderers held by this parallel render manager
  (initially empty) is synced. You can modify the list of
  renderers with the AddRenderer, RemoveRenderer, and
  RemoveAllRenderers methods.
* obj.AddRenderer (vtkRenderer ) - By default, the state of
  all renderers in the root's render window is propagated to
  the rest of the processes. In order for this to work, all
  render windows must have the same renderers in the same
  order. If this is not the case, you can turn off the
  SyncRenderWindowRenderers. When this flag is off, the list
  of renderers held by this parallel render manager
  (initially empty) is synced. You can modify the list of
  renderers with the AddRenderer, RemoveRenderer, and
  RemoveAllRenderers methods.
* obj.RemoveRenderer (vtkRenderer ) - By default, the state
  of all renderers in the root's render window is propagated
  to the rest of the processes. In order for this to work,
  all render windows must have the same renderers in the
  same order. If this is not the case, you can turn off the
  SyncRenderWindowRenderers. When this flag is off, the list
  of renderers held by this parallel render manager
  (initially empty) is synced. You can modify the list of
  renderers with the AddRenderer, RemoveRenderer, and
  RemoveAllRenderers methods.
* obj.RemoveAllRenderers () - By default, the state of all
  renderers in the root's render window is propagated to the
  rest of the processes. In order for this to work, all
  render windows must have the same renderers in the same
  order. If this is not the case, you can turn off the
  SyncRenderWindowRenderers. When this flag is off, the list
  of renderers held by this parallel render manager
  (initially empty) is synced. You can modify the list of
  renderers with the AddRenderer, RemoveRenderer, and
  RemoveAllRenderers methods.
* obj.SetWriteBackImages (int ) - If on (the default), the
  result of any image space manipulations are written back
  to the render window frame buffer. If off, the image
  stored in the frame buffer may not be correct. Either way,
  the correct frame buffer images may be read with
  vtkParallelRenderManager::GetPixelData. Turning
  WriteBackImages off may result in a speedup if the render
  window is not visible to the user and images are read back
  for further processing or transit.
* int = obj.GetWriteBackImages () - If on (the default), the
  result of any image space manipulations are written back
  to the render window frame buffer. If off, the image
  stored in the frame buffer may not be correct. Either way,
  the correct frame buffer images may be read with
  vtkParallelRenderManager::GetPixelData. Turning
  WriteBackImages off may result in a speedup if the render
  window is not visible to the user and images are read back
  for further processing or transit.
* obj.WriteBackImagesOn () - If on (the default), the result
  of any image space manipulations are written back to the
  render window frame buffer. If off, the image stored in
  the frame buffer may not be correct. Either way, the
  correct frame buffer images may be read with
  vtkParallelRenderManager::GetPixelData. Turning
  WriteBackImages off may result in a speedup if the render
  window is not visible to the user and images are read back
  for further processing or transit.
* obj.WriteBackImagesOff () - If on (the default), the
  result of any image space manipulations are written back
  to the render window frame buffer. If off, the image
  stored in the frame buffer may not be correct. Either way,
  the correct frame buffer images may be read with
  vtkParallelRenderManager::GetPixelData. Turning
  WriteBackImages off may result in a speedup if the render
  window is not visible to the user and images are read back
  for further processing or transit.
* obj.SetMagnifyImages (int ) - If on (the default), when
  the ImageReductionFactor is greater than 1 and
  WriteBackImages is on, the image will be magnified to fill
  the entire render window.
* int = obj.GetMagnifyImages () - If on (the default), when
  the ImageReductionFactor is greater than 1 and
  WriteBackImages is on, the image will be magnified to fill
  the entire render window.
* obj.MagnifyImagesOn () - If on (the default), when the
  ImageReductionFactor is greater than 1 and WriteBackImages
  is on, the image will be magnified to fill the entire
  render window.
* obj.MagnifyImagesOff () - If on (the default), when the
  ImageReductionFactor is greater than 1 and WriteBackImages
  is on, the image will be magnified to fill the entire
  render window.
* obj.SetMagnifyImageMethod (int method) - Sets the method
  used to magnify images. Nearest simply replicates each
  pixel enough times to fill the image. Linear performs
  linear interpolation between the pixels.
* int = obj.GetMagnifyImageMethod () - Sets the method used
  to magnify images. Nearest simply replicates each pixel
  enough times to fill the image. Linear performs linear
  interpolation between the pixels.
* obj.SetMagnifyImageMethodToNearest () - Sets the method
  used to magnify images. Nearest simply replicates each
  pixel enough times to fill the image. Linear performs
  linear interpolation between the pixels.
* obj.SetMagnifyImageMethodToLinear () - Convenience
  functions for magnifying images.
* obj.MagnifyImage (vtkUnsignedCharArray fullImage, int
  fullImageSize[2], vtkUnsignedCharArray reducedImage, int
  reducedImageSize[2], int fullImageViewport[4]NULL, int
  reducedImageViewport[4]NULL) - Convenience functions for
  magnifying images.
* obj.GetPixelData (vtkUnsignedCharArray data) - The most
  appropriate way to retrieve full size image data after a
  render. Will work regardless of whether WriteBackImages or
  MagnifyImage is on or off. The data returned may be a
  shallow copy of an internal array. Therefore, the data may
  be invalid after the next render or if the
  ParallelRenderManager is destroyed.
* obj.GetPixelData (int x1, int y1, int x2, int y2,
  vtkUnsignedCharArray data) - The most appropriate way to
  retrieve full size image data after a render. Will work
  regardless of whether WriteBackImages or MagnifyImage is
  on or off. The data returned may be a shallow copy of an
  internal array. Therefore, the data may be invalid after
  the next render or if the ParallelRenderManager is
  destroyed.
* obj.GetReducedPixelData (vtkUnsignedCharArray data) - The
  most appropriate way to retrieve reduced size image data
  after a render. Will work regardless of whether
  WriteBackImages or MagnifyImage is on or off. The data
  returned may be a shallow copy of an internal array.
  Therefore, the data may be invalid after the next render
  or if the ParallelRenderManager is destroyed.
* obj.GetReducedPixelData (int x1, int y1, int x2, int y2,
  vtkUnsignedCharArray data) - The most appropriate way to
  retrieve reduced size image data after a render. Will work
  regardless of whether WriteBackImages or MagnifyImage is
  on or off. The data returned may be a shallow copy of an
  internal array. Therefore, the data may be invalid after
  the next render or if the ParallelRenderManager is
  destroyed.
* int = obj. GetFullImageSize () - Returns the full image
  size calculated at the last render.
* int = obj. GetReducedImageSize () - Returns the reduced
  image size calculated at the last render.
* obj.TileWindows (int xsize, int ysize, int nColumns) -
  Given the x and y size of the render windows, reposition
  them in a tile of n columns.
* obj.SetUseRGBA (int ) - Get/Set if all Images must use
  RGBA instead of RGB. By default, this flag is on.
* int = obj.GetUseRGBA () - Get/Set if all Images must use
  RGBA instead of RGB. By default, this flag is on.
* obj.SetForceRenderWindowSize (int ) - If
  ForceRenderWindowSize is set to true, the render manager
  will use the RenderWindowSize ivar instead of getting the
  size from the render window.
* int = obj.GetForceRenderWindowSize () - If
  ForceRenderWindowSize is set to true, the render manager
  will use the RenderWindowSize ivar instead of getting the
  size from the render window.
* obj.SetForcedRenderWindowSize (int , int ) - If
  ForceRenderWindowSize is set to true, the render manager
  will use the Size ivar instead of getting the size from
  the render window.
* obj.SetForcedRenderWindowSize (int a[2]) - If
  ForceRenderWindowSize is set to true, the render manager
  will use the Size ivar instead of getting the size from
  the render window.
* int = obj. GetForcedRenderWindowSize () - If
  ForceRenderWindowSize is set to true, the render manager
  will use the Size ivar instead of getting the size from
  the render window.
* obj.StartService () -


* FreeMat_Documentation
* Visualization_Toolkit_Parallel_Classes
* Generated on Thu Jul 25 2013 17:18:34 for FreeMat by
  doxygen_ 1.8.1.1