<div dir="ltr">Rich,<div><br></div><div>Attached is a sample script that you can run using pvpython or pvbatch or vtkpython executables.</div><div><br></div><div>Utkarsh</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Mar 29, 2016 at 1:35 PM, Cook, Rich <span dir="ltr"><<a href="mailto:cook47@llnl.gov" target="_blank">cook47@llnl.gov</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div style="word-wrap:break-word">
<div>I'm still trying to solve my ellipsoid puzzle. </div>
<div>From looking around online, I've found a promising avenue. Create a vtk.vtkParametricEllipsoid, rotate it, and then write to VTK for my user. </div>
<div>My question is, can someone help me finish this script? I am hoping for an experienced user it's trivial. My objective is to hand the user a python script to convert her data to VTK. </div>
<div><br>
</div>
<div>from ? import ? # WHAT GOES HERE? Do I need to run this from paraview? </div>
<div>for ellipsoid in ellipsoids: </div>
<blockquote style="margin:0 0 0 40px;border:none;padding:0px">ellipsoid = vtk.vtkParametricEllipsoid()<br>
ellipsoid.SetXRadius(50)<br>
ellipsoid.SetYRadius(10)<br>
ellipsoid.SetZRadius(10)<br>
transform = vtk.vtkTransform()<br>
transform.RotateWXYZ(45,0,1,0)</blockquote>
<blockquote style="margin:0 0 0 40px;border:none;padding:0px">transform.Translate(100,200,50)</blockquote>
<blockquote style="margin:0 0 0 40px;border:none;padding:0px"># The magic: connect the transform to the ellipsoid and add it to the scene.</blockquote>
<blockquote style="margin:0 0 0 40px;border:none;padding:0px"># HOW??? </blockquote>
<div><br>
</div>
<div># write all objects in the scene to a VTK file Again, HOW? <span class="HOEnZb"><font color="#888888"><br>
<br>
<div><span style="border-collapse:separate;font-size:13px;border-spacing:0px"><span style="border-collapse:separate;color:rgb(0,0,0);font-family:Monaco;font-size:13px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><span style="border-collapse:separate;color:rgb(0,0,0);font-family:Monaco;font-size:13px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><span style="border-collapse:separate;color:rgb(0,0,0);font-family:Monaco;font-size:13px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><span style="border-collapse:separate;color:rgb(0,0,0);font-family:Monaco;font-size:13px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><span style="border-collapse:separate;color:rgb(0,0,0);font-family:Monaco;font-size:13px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><span style="border-collapse:separate;color:rgb(0,0,0);font-family:Monaco;font-size:13px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><span style="border-collapse:separate;color:rgb(0,0,0);font-family:Monaco;font-size:13px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px">
<div>-- </div>
<div>✐Richard Cook </div>
<div>✇ Lawrence Livermore National Laboratory</div>
<div>Bldg-453 Rm-4024, Mail Stop L-557 </div>
<div>7000 East Avenue, Livermore, CA, 94550, USA</div>
<div>☎ (office) <a href="tel:%28925%29%20423-9605" value="+19254239605" target="_blank">(925) 423-9605</a> </div>
<div>☎ (fax) <a href="tel:%28925%29%20423-6961" value="+19254236961" target="_blank">(925) 423-6961</a></div>
<div>---</div>
<div>Information Management & Graphics Grp., Services & Development Div., Integrated Computing & Communications Dept.</div>
<div>(opinions expressed herein are mine and not those of LLNL)</div>
<br>
</span></span></span></span></span></span></span><br>
</span></div>
<br>
</font></span></div>
</div>
<br>_______________________________________________<br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" 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" rel="noreferrer" target="_blank">http://paraview.org/Wiki/ParaView</a><br>
<br>
Search the list archives at: <a href="http://markmail.org/search/?q=ParaView" rel="noreferrer" 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" rel="noreferrer" target="_blank">http://public.kitware.com/mailman/listinfo/paraview</a><br>
<br></blockquote></div><br></div>