[Paraview] Extracting a block from a vtkMultiBlockDataSet in Paraview (Bug?)

Favre Jean jfavre at cscs.ch
Wed Nov 25 03:16:18 EST 2015


You are missing a RequestInformation Script to indicate the dimensions of the grid you wish to create.

Set the type of the Output Data to "vtkStructuredGrid"

you will need, at the minimum, the following two sections of python code

in the "Script"

mbds = inputs[0]

block0 = mbds.GetBlock(0)

output.ShallowCopy(block0)

(make sure to toggle the Advanced Properties to make the second text input widget to appear, and fill in the "RequestInformation Script" with the following text:


executive = self.GetExecutive()

outInfo = executive.GetOutputInformation(0)

mbds = inputs[0]

block0 = mbds.GetBlock(0)

dims = block0.GetDimensions()

outInfo.Set(executive.WHOLE_EXTENT(), 0, dims[0]-1 , 0, dims[1]-1 , 0, dims[2]-1)

==============
That's all!

Jean/CSCS


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/paraview/attachments/20151125/11c1e2ba/attachment.html>


More information about the ParaView mailing list