[Paraview] Problems with structured grid source plugin

Moreland, Kenneth kmorel at sandia.gov
Wed Jul 30 11:53:04 EDT 2008


The problem is that vtkStructuredGridGenerator needs to declare the whole
extents in RequestInformation.  ParaView will first take the whole extents
reported in RequestInformation to determine the size of the data that is
going to be created, and then pass an update extent during the RequestData
phase to tell your generator what part of the data to actually load.

Attached is a modified version of vtkStructuredGridGenerator.cxx that adds a
RequestInformation method that reports the WHOLE_EXTENT.  I also modified
the RequestData to query the UPDATE_EXTENT to create a structured grid that
is the subregion ParaView requests.  I also took the liberty to fix a bug in
the order of the for loops that create the point data.  I've tried this in
ParaView in serial and it works fine.  I have not tried it in parallel, but
these changes should make it work in parallel too.

-Ken


On 7/30/08 8:21 AM, "Paul Edwards" <paul.m.edwards at gmail.com> wrote:

> Hi,
>
> I am trying to create a structured grid with a plugin.  The number of
> points is correct at the end of request data but nothing appears in
> ParaView.  Can anyone see what I am doing wrong?
>
> Thanks in advance,
> Paul

-------------- next part --------------
A non-text attachment was scrubbed...
Name: vtkStructuredGridGenerator.cxx
Type: application/octet-stream
Size: 3680 bytes
Desc: vtkStructuredGridGenerator.cxx
URL: <http://www.paraview.org/pipermail/paraview/attachments/20080730/699c8440/attachment.obj>


More information about the ParaView mailing list