VTKExamples
VTKExamples copied to clipboard
CSharp example custom interactor exception
This CSharp example: https://lorensen.github.io/VTKExamples/site/CSharp/IO/ReadDICOMSeries/
Produces the following exception somewhat randomly:
System.Exception: 'error: could not get registered type - mteIndex='4294967295' classNameKey='''
If you scroll through enough slices, eventually you should get the exception. The exception appears to be caused by the custom vtkObjectEventHandlers that are added to interactorStyle on these two lines:
interactorStyle.MouseWheelForwardEvt += new vtkObject.vtkObjectEventHandler(interactor_MouseWheelForwardEvt);
interactorStyle.MouseWheelBackwardEvt += new vtkObject.vtkObjectEventHandler(interactor_MouseWheelBackwardEvt);