[vtk-developers] Re: [vtkusers] problem with vtk3DWidgets and observer order
Prabhu Ramachandran
prabhu at aero.iitm.ernet.in
Tue May 14 06:59:41 EDT 2002
>>>>> "CPB" == Charl P Botha <c.p.botha at its.tudelft.nl> writes:
CPB> On Tue, May 14, 2002 at 08:45:21AM +0200, Robert Belleman
CPB> wrote:
>> It's broken here; I have camera movemement. Even worse: if I
>> move one of the balls, the camera moves a little, then all
>> interaction freezes. Vtk then consumes 99% CPU.
>>
>> May 13th nightly.
CPB> Thanks for testing Rob!
CPB> Okay, it's working for John and Sebastien and it's broken for
CPB> you, me and Prabhu. I'm also working with a CVS checkout of
CPB> May 11 / 12. I've also seen the interaction freeze, and so
CPB> has Prabhu. Common denominators: I believe John and
CPB> Sebastien are testing on Windows; Rob, Prabhu and I are on
CPB> Linux.
CPB> Any more testers?
FWIW, I just tested again under Debian GNU/Linux (woody) with the
latest CVS checkout and have exactly the same problem reported by you
and Rob (i.e. camera moving + CPU going to 99%).
$ python -c "import vtk; print vtk.vtkVersion.GetVTKSourceVersion()"
vtk version 4.1.1, vtk source $Revision: 1.1215 $, $Date: 2002/05/14 02:47:00 $ (GMT)
So this is a problem. Note: I did a clean rebuild (make clean; make).
I also found that there is another wierd (not trivially repeatable)
problem with the RenderWindowInteractors in general. Simply create a
sample example (one attached below) that uses a
vtkRenderWindowInteractor (of any sort) and then hit 't' and 'j' along
with random interactions thrown in and I get a segfault! :( Here is a
backtrace. As I said, its not easy to replicate. Just kit a random
sequence of 'j' and 't' and interact with the window.
>>> execfile('t.py')
(no debugging symbols found)...(no debugging symbols found)...
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1024 (LWP 27204)]
vtkSubjectHelper::InvokeEvent (this=0x821db80, event=21, callData=0x0,
self=0x81982e0) at /skratch/prabhu/vtk/cvs/VTK/Common/vtkObject.cxx:457
457 next = elem->Next;
Current language: auto; currently c++
(gdb) back
#0 vtkSubjectHelper::InvokeEvent (this=0x821db80, event=21, callData=0x0,
self=0x81982e0) at /skratch/prabhu/vtk/cvs/VTK/Common/vtkObject.cxx:457
#1 0x404f51be in vtkObject::InvokeEvent (this=0x81982e0, event=21,
callData=0x0) at /skratch/prabhu/vtk/cvs/VTK/Common/vtkObject.cxx:581
#2 0x41c94483 in vtkXRenderWindowInteractorCallback (client_data=0x81982e0,
event=0xbffff4ac)
at /skratch/prabhu/vtk/cvs/VTK/Rendering/vtkXRenderWindowInteractor.cxx:629
#3 0x41e583ff in XtDispatchEventToWidget () from /usr/X11R6/lib/libXt.so.6
#4 0x41e58d7e in _XtOnGrabList () from /usr/X11R6/lib/libXt.so.6
#5 0x41e58fc8 in XtDispatchEvent () from /usr/X11R6/lib/libXt.so.6
#6 0x41c929a8 in vtkXRenderWindowInteractor::Start (this=0x81982e0)
at /skratch/prabhu/vtk/cvs/VTK/Rendering/vtkXRenderWindowInteractor.cxx:165
#7 0x4190232c in PyvtkXRenderWindowInteractor_Start (self=0x821de48,
args=0x80ccee4)
at /skratch/prabhu/vtk/cvs/VTK/Rendering/vtkXRenderWindowInteractorPython.cxx:322
Its not really a vtkXRenderWindow bug because it happens with the new
widgets that I added last night as well.
Here is my test code:
# ----------------------------------------
from vtk import *
ren = vtkRenderer()
renWin = vtkRenderWindow()
renWin.AddRenderer(ren)
renWin.SetSize(300,300)
iren = vtkRenderWindowInteractor()
iren.SetRenderWindow(renWin)
# create an actor and give it cone geometry
cone = vtkConeSource()
cone.SetResolution(8)
coneMapper = vtkPolyDataMapper()
coneMapper.SetInput(cone.GetOutput())
coneActor = vtkActor()
coneActor.SetMapper(coneMapper)
# assign our actor to the renderer
ren.AddActor(coneActor)
# enable user interface interactor
iren.Initialize()
iren.Start()
# ----------------------------------------
prabhu
More information about the vtk-developers
mailing list