<font color="#000000"><font size="2"><font face="tahoma,sans-serif">Hi<br><br>I created pvd files from vtm file series to enable animation in ParaView via Python script. I want to modify the display properties of the dataset before animating them. But i got a runtime exception in the "AnimateReader" step. That's understandable since "dp" is not a reader. How can I animate the modified data? <br>
<br></font></font></font>from paraview.simple import *
<p style="margin: 0px; text-indent: 0px;">from paraview import servermanager</p><p style="margin: 0px; text-indent: 0px;">reader = PVDReader(FileName="TestCase.pvd")</p>
<p style="margin: 0px; text-indent: 0px;">dp = GetDisplayProperties(reader)</p>
<p style="margin: 0px; text-indent: 0px;">dp.Representation='Surface'</p>
<p style="margin: 0px; text-indent: 0px;"><br></p><p style="margin: 0px; text-indent: 0px;">for a in reader.PointData:</p>
<p style="margin: 0px; text-indent: 0px;"> if (a.GetName() == 'Velocity'):</p>
<p style="margin: 0px; text-indent: 0px;"> range = a.GetRange()</p>
<p style="margin: 0px; text-indent: 0px;"> dp.LookupTable = GetLookupTableForArray(a.GetName(), 1,RGBPoints = [range[0], 0, 0, 1, range[1], 1, 0, 0],ColorSpace = "Diverging")</p>
<p style="margin: 0px; text-indent: 0px;"> dp.ColorArrayName = a.GetName()</p>
<p style="margin: 0px; text-indent: 0px;"> Render() </p>
<p style="margin: 0px; text-indent: 0px;"> AnimateReader(dp,filename="TestCase.avi")</p><p style="margin: 0px; text-indent: 0px;"><br></p><p style="margin: 0px; text-indent: 0px;"><br></p><br clear="all"><br clear="all">
<br>-- <br>Regards,<br>Alexis<br><br>