Hi all,<div><br></div><div>I'm working on a programmable filter that needs to produce a vtkImageData object. So far it appears to work, inspection of the properties panel shows the object has the correct number of points/cells and the data array contains the correct data. However I cannot get a visualisation with any of the representations (surface, outline, wireframe etc). Curiously, if i set the display to my data array then the color bar appears with the correct values, but still not visualization.</div><div><br></div><div>I am using the following code to produce the image data object.</div><div><br></div><div>from vtk import *<br></div><div><br></div><div><div>output = self.GetOutputDataObject(0);</div><div><br></div><div># Create a VTK Grid<br></div><div>grid = vtkImageData()</div><div>grid.SetOrigin(0, 0, 0) # default values</div><div>dx=10;</div><div>grid.SetSpacing(dx, dx, dx)</div><div>grid.SetDimensions(5, 8, 10) # number of points in each direction</div><div># print grid.GetNumberOfPoints()</div><div># print grid.GetNumberOfCells()</div><div>array = vtkDoubleArray()</div><div>array.SetNumberOfComponents(1) # this is 3 for a vector</div><div>array.SetNumberOfTuples(grid.GetNumberOfPoints())</div><div>for i in range(grid.GetNumberOfPoints()):</div><div>    if i < 200:</div><div>        array.SetValue(i, 1)</div><div>    else:</div><div>        array.SetValue(i, 2)</div><div><br></div><div>grid.GetPointData().AddArray(array)</div><div># print grid.GetPointData().GetNumberOfArrays()</div><div>array.SetName("unit array")</div><div>output.ShallowCopy(grid);</div></div><div><br></div><div>Cheers,</div><div>Bruce</div>