<div dir="ltr">You have to provide the whole extent in the request information pass.</div><div class="gmail_extra"><br clear="all"><div><div class="gmail_signature">David E DeMarle<br>Kitware, Inc.<br>R&D Engineer<br>21 Corporate Drive<br>Clifton Park, NY 12065-8662<br>Phone: 518-881-4909</div></div>
<br><div class="gmail_quote">On Wed, May 13, 2015 at 1:19 PM, Wu, James <span dir="ltr"><<a href="mailto:James.Wu@kla-tencor.com" target="_blank">James.Wu@kla-tencor.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I add a programmable data source using vtkImageData. The following is the script.<br>
There is nothing displayed after click "Apply". I am new user to paraview. Can any point me what's wrong with the script?<br>
<br>
Thanks,<br>
James<br>
<br>
dim = 10<br>
pdo = self.GetImageDataOutput()<br>
pdo.SetDimensions(dim, dim, dim)<br>
pdo.SetOrigin(0, 0, 0)<br>
pdo.SetSpacing(1, 1, 1)<br>
pdo.SetExtent(0, dim - 1, 0, dim - 1, 0, dim - 1)<br>
pdo.AllocateScalars(vtk.VTK_FLOAT, 1)<br>
<br>
for x in range(0, dim):<br>
for y in range(0, dim):<br>
for z in range(0, dim):<br>
pdo.SetScalarComponentFromFloat(x, y, z, 0, 0.2)<br>
_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the ParaView Wiki at: <a href="http://paraview.org/Wiki/ParaView" target="_blank">http://paraview.org/Wiki/ParaView</a><br>
<br>
Search the list archives at: <a href="http://markmail.org/search/?q=ParaView" target="_blank">http://markmail.org/search/?q=ParaView</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://public.kitware.com/mailman/listinfo/paraview" target="_blank">http://public.kitware.com/mailman/listinfo/paraview</a><br>
</blockquote></div><br></div>