<meta charset="utf-8"><span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; ">Hi ParaViewers,<div><br></div><div>(Sorry if this double-posts!)</div><div><br></div>
<div>I am writing a ParaView Reader Plugin to get my data into ParaView via a vtkStructuredGrid object. I can load my plugin into ParaView via "Manage Plugins". My file type shows up in the "File-> Open" dialog. When PV_PLUGIN_DEBUG is set, the "Output Messages" window shows that the library was loaded successfully.</div>
<div><br></div><div>When I select a file and click "Apply" in the object inspector, Paraview thinks for a split second before returning to an interactive state. However, no data appears & the "Information" tab of the object inspector sets nCells = 0; nPoints = 0; Memory = 0 MB and the X,Y,Z extents are "NA".</div>
<div><br></div><div>My plugin reader derives from "vtkStructuredGridReader" and implements:</div><div><br></div><div>* SetFileName</div><div>* GetFileName</div><div>* CanReadFile </div><div>* RequestInformation, where I set the extents via:</div>
<div><div> outInfo->Set(vtkStreamingDemandDrivenPipeline::WHOLE_EXTENT(),extent,6);</div></div><div>* RequestData, where I obtain a vtkStructuredGrid via:</div><div><div> vtkStructuredGrid *output =</div><div> vtkStructuredGrid::SafeDownCast(outInfo->Get(vtkDataObject::DATA_OBJECT()));</div>
</div><div><br></div><div>I am not sure why the "Information" tab is showing an empty structured grid. My questions are:</div><div><br></div><div>1. How can I print debugging messages to stdout or Paraview's own "Output Messages" window? Specifically, I'd like to make sure that my X,Y,Z extents are being read properly from file. I tried vtkDebugMacro, but the data isn't being printed.</div>
<div><br></div><div>2. Have I implemented the appropriate functions that derive from vtkStructuredGridReader? </div><div><br></div><div>3. Should I derive instead from another class? When I derive from vtkStructuredGridAlgorithm, I get three error messages from vtkCompositeDataPipeline: "Input port 0 of algorithm vtkLFMReader(0x11f98a720) has 0 connections but is not optional".</div>
<div><br></div><div>Can you offer any hints of how I can proceed to debug my reader?</div><div><br></div><div>Thanks!</div><div>Pete</div></span>