[vtkusers] ErrorEvent observer on algorithms (or vtkClipClosedSurface)

Bryn Lloyd lloyd at itis.ethz.ch
Thu Feb 2 07:48:36 EST 2012


Hi

I am trying to catch the ErrorEvent on the vtkClipClosedSurface filter 
in python.

I have tried the code from David Gobbi:
http://www.cognitive-antics.net/mw/index.php?title=VTK/Python_ErrorObserver

I also tried a simple callback:
def errorEventCallback(obj,eventId):
     print >>sys.stderr, "ERROR:",obj

clipper.AddObserver('ErrorEvent', errorEventCallback)
clipper.Update()


But it seems the ErrorEvent is not invoked by the vtkErrorMacro. I 
assume I have not attached the error observer to the correct object, but 
am unclear about where I should attach the observer.

This seems to be a question raised again and again. Most examples use 
e.g. a imagereader, some say the observer should be attached to the 
executive ... Mysterious.

Thanks for any clarification
Bryn






More information about the vtkusers mailing list