On 1 March 2010 23:55, David Doria <span dir="ltr"><<a href="mailto:daviddoria%2Bvtk@gmail.com">daviddoria+vtk@gmail.com</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div class="im"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"><div><div>I will have to build VTK CVS to be able to test this (I currently have</div>
</div>
5.4.2 on all platforms). Hopefully I can reproduce the crash, in<br>
which case I have a better chance of being able to diagnose it. I'm<br>
currently swamped, so this is not going to happen very soon.<br>
<br>
Please continue with your own debugging in the meanwhile. First thing<br>
you could try, is to modify the attribList to contain only<br>
wx.glcanvas.WX_GL_DOUBLEBUFFER bringing it more in linux with<br>
wxVTKRenderWindow.<br>
<br>
Good luck,<br>
<font color="#888888">Charl<br>
</font></blockquote></div><div><br></div></div>I tried modifying attribList - there was no change. I believe the crash happens in the Render function. I put a <div>print "before" </div><div>and</div><div>print "after" </div>
<div>in the function:<br><div><br></div><div><div> def Render(self):</div><div> """Actually renders the VTK scene on screen.</div><div> """</div><div> RenderAllowed = 1</div>
<div> <span style="white-space: pre;">        </span>print "before"</div><div> if not self.__RenderWhenDisabled:</div><div> # the user doesn't want us to render when the toplevel frame</div>
<div> # is disabled - first find the top level parent</div><div> topParent = wx.GetTopLevelParent(self)</div><div> if topParent:</div><div> # if it exists, check whether it's enabled</div>
<div> # if it's not enabeld, RenderAllowed will be false</div><div> RenderAllowed = topParent.IsEnabled()</div><div><br></div><div> if RenderAllowed:</div><div> if self.__handle and self.__handle == self.GetHandle():</div>
<div> self._Iren.GetRenderWindow().Render()</div><div><br></div><div> elif self.GetHandle() and self.__has_painted:</div><div> # this means the user has reparented us; let's adapt to the</div>
<div> # new situation by doing the WindowRemap dance</div><div> self._Iren.GetRenderWindow().SetNextWindowInfo(</div><div> str(self.GetHandle()))</div><div><br></div><div>
# make sure the DisplayId is also set correctly</div>
<div> d = self.GetDisplayId()</div><div> if d:</div><div> self._Iren.GetRenderWindow().SetDisplayId(d)</div><div> </div><div> # do the actual remap with the new parent information</div>
<div> self._Iren.GetRenderWindow().WindowRemap()</div><div><br></div><div> # store the new situation</div><div> self.__handle = self.GetHandle()</div><div> self._Iren.GetRenderWindow().Render()</div>
<div><span style="white-space: pre;">        </span>print "after"</div></div><div><br></div><div>The output is:</div><div><div class="im"><div>[doriad@davedesktop wx]$ python wxVTKRenderWindowInteractor.py</div></div>
<div>
before</div><div>after</div><div>before</div><div>Segmentation fault</div><div><br></div><div>I am not at all a python guru so I don't know how the buffers work/flush, so maybe this is misleading because the buffer is not flushed - but if not, I think it indicates that the crash happens in this function (the second time it is called)?</div>
</div><div><br clear="all">Thanks,<br><br>David<br></div></div>
<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 VTK FAQ at: <a href="http://www.vtk.org/Wiki/VTK_FAQ" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.vtk.org/mailman/listinfo/vtkusers" target="_blank">http://www.vtk.org/mailman/listinfo/vtkusers</a><br>
<br></blockquote></div><br><br>Hi,<br><br>I tried the last cvs version ( 1.556 ) and wxRenderWindowInteractor is still crashing with a segmentation fault in 64 bit Ubuntu 10.04, gcc 4.4.3, wxPython 2.8.10.1. <br><br>I tried in Windows XP 32 bit too and it worked.<br>
<br>Regards,<br>Paulo<br><br><br><br><br><br>