<div class="gmail_quote">On Fri, Apr 29, 2011 at 6:06 AM, Rentschler Martin <span dir="ltr"><<a href="mailto:martin.rentschler@gmail.com">martin.rentschler@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
Hi,<br><br>I want to access the PointData of a Source using a python script. <br><br>So first I choose the Source by<br><br>
<p style="margin:0px;text-indent:0px"><span style="font-family:'Courier';font-size:10pt;color:rgb(0, 0, 0)">>>> bla=GetActiveSource()</span></p>
<p style="margin:0px;text-indent:0px"><span style="font-family:'Courier';font-size:10pt;color:rgb(0, 0, 0)">>>> bla</span></p>
<p style="margin:0px;text-indent:0px"><span style="font-family:'Courier';font-size:10pt;color:rgb(0, 150, 0)"><paraview.servermanager.H5Part object at 0x46a39d0></span></p><br>and then I would to access the data of that object, but <br>
<br>
<p style="margin:0px;text-indent:0px"><span style="font-family:'Courier';font-size:10pt;color:rgb(0, 0, 0)">>>> Arrays=SOLID25_h5part.PointArrays</span></p>
<p style="margin:0px;text-indent:0px"><span style="font-family:'Courier';font-size:10pt;color:rgb(0, 0, 0)">>>> Arrays</span></p>
<p style="margin:0px;text-indent:0px"><span style="font-family:'Courier';font-size:10pt;color:rgb(0, 150, 0)">['Coords_0',
'Coords_1', 'Coords_2', 'SOLID25_h', 'SOLID25_index',
'SOLID25_normals_0', 'SOLID25_normals_1', 'SOLID25_normals_2',
'SOLID25_pressure', 'SOLID25_velocity_0', 'SOLID25_velocity_1',
'SOLID25_velocity_2', 'SOLID25_vmob_0', 'SOLID25_vmob_1',
'SOLID25_vmob_2', 'SOLID25_w']</span></p>
<p style="margin:0px;text-indent:0px"><br></p><p style="margin:0px;text-indent:0px">Only gives me the names of the arrays. How do I then access to the Values of for example 'Coords_0' ?</p><p style="margin:0px;text-indent:0px">
<br></p><p style="margin:0px;text-indent:0px">Best regards</p><p style="margin:0px;text-indent:0px"><br></p><font color="#888888">Martin
</font><br></blockquote><div><br>Is this what you're looking for?<br>
<br>
<a href="http://www.itk.org/Wiki/ParaView/Python_Scripting#Source_Proxies" target="_blank">http://www.itk.org/Wiki/ParaView/Python_Scripting#Source_Proxies</a><br clear="all">
<font color="#888888"><br></font><br>David<br></div></div><br>