[vtkusers] activiz vtkPolydataAlgorithm
Benjamin Jähn
jaminus_jahnatos at freenet.de
Sat Dec 1 04:58:11 EST 2012
I found a topic where someone was able to inherit successfully from a
Activiz/vtk class.
[QUOTE]
Note: All classes are static, that's the reason why you cannot inherit
from any wrapped vtk class.
But as I learned a few days ago there's a way to extent a static class.
If you like I can show you how to do that.
[/QUOTE]
http://vtk.1045678.n5.nabble.com/vtkCallbackCommand-in-ActiveViz-td5714143.html#a5714197
And there is also an example how the guy managed it to do that. The
example he wrote worked for me but I have tried it with another class
and I get a InvalidCastException at the constructor.
public class myCommand : vtkCommand
{
private vtkPolyData Points;
public myCommand()
{
Points = vtkPolyData.New();
}
//public override void Execute(vtkObject caller, uint eventId,
IntPtr callData)
//{
// base.Execute(caller, eventId, callData);
// Console.WriteLine("Callback!");
//}
}
I did not understand so far why this not work and the other example works.
Am 24.11.2012 11:21, schrieb I_like_activiz:
> Basically you can write something like
>
> public class myFilter: vtkPolydataAlgorithm
>
> but if it would work to override any method, I can not say either.
> I did not subclass any avtiviz class before. I tried it the first time,
> but was not able to make it work and so I opened this topic.
>
> So maybe you are right.
>
>
>
> --
> View this message in context: http://vtk.1045678.n5.nabble.com/activiz-vtkPolydataAlgorithm-tp5717071p5717263.html
> Sent from the VTK - Users mailing list archive at Nabble.com.
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
More information about the vtkusers
mailing list