Hi, I’m trying to create a custom render pass using just python. It seems that it’s impossible create a subclass in python using vtkRenderDelegate
class myPass(vtk.vtkRendererDelegate):
# def __init__(self, *args, **kwargs):
# super().__init__(*args, **kwargs)
def Render(self, s):
"""
s: vtkRenderState
"""
pass
myPass()
# TypeError: this is an abstract class and cannot be instantiated
I think it’s the same issue explained here http://vtk.1045678.n5.nabble.com/vtkParametricFunction-sub-classes-in-Python-td5740029.html
In addition, as explained here
https://gitlab.kitware.com/vtk/vtk/blob/master/Wrapping/Python/README.md
It is possible to subclass a VTK class from within Python, but it
is NOT possible to properly override the virtual methods of the class.
Therefore, there is no reason to peform the following approach
class myPass(vtk.vtkGaussianBlurPass):
....
def Render( renderState):
pass
Is there any way to create a custom render pass in python?
Thanks