[vtkusers] Qt + Vtk - Callbacks and signals/slots
Julien Finet
julien.finet at kitware.com
Thu Aug 22 16:16:51 EDT 2013
Hi,
You should not be deriving from vtkObject AND QObject, it won't work.
In your case, the callback could have a QObject as member variable (the
QVTKWidget?) and call a method on that QObject (which potentially could
fire a signal observed by other QObjects).
Julien.
On Thu, Aug 22, 2013 at 10:22 AM, Anka Kochanowska <pluszcz at gmail.com>wrote:
> Does your class has a
>
> Q_OBJECT
>
> macro included?
>
> Anka
>
>
>
>
>
>
> On Wed, Aug 21, 2013 at 6:09 PM, Jose Ignacio Prieto <
> joseignacio.prieto at gmail.com> wrote:
>
>> Hi all,
>> I think I am not fully understanding callbacks and signals. I have a qt
>> project where the ui loads a vtk renderwindow. That render window has a
>> callback (a box widget that has to update the clipping planes of the
>> vtkvolume). After that I would like that inside the callback it emits a
>> signal and the qvtkwidget then calls its renderwindow and renders all.
>> I couldn't emit a signal, so I made the class mycallback to inherit both
>> from vtkcommand and qobject, and now it doesn't compile showing
>>
>> undefined reference to `vtable for vtkBoxCallback'
>>
>>
>> What should I do?
>> Thanks
>>
>> --
>> José Ignacio Prieto
>> celular(nuevo): 94348182
>>
>> _______________________________________________
>> 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
>>
>>
>
> _______________________________________________
> 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
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20130822/41745034/attachment.htm>
More information about the vtkusers
mailing list