[Paraview] vtkSMProperty and vtkSet
papa ndéné NDIAYE
pnwireframe at gmail.com
Tue Jul 12 09:59:06 EDT 2011
*Hi Utkarsh,
I just wanted to modify the BlockIndices property of the extract filter on
the fly.
Since in the source code it is linked to a vtkstd::Set attribute in the
extractblock class,
I was trying to create a set vtkSet and put it in a vtkSMProperty so that I
just had to
call getProperty method and set the property pointer to the @ of my created
vtkSMProperty.
but with help from John Biddiscomb I got the way to do it.
It's something like:
QList<QVariant> blocks;*
* vtkPVCompositeDataInformation *pvcdi = out->GetDataInformation()->
GetCompositeDataInformation();*
* QList<QVariant> blocks;*
* int N = pvcdi->GetNumberOfChildren();*
* for (int i=0; i<N; i++) {*
* if (...) blocks.append(i+1);*
* }*
* pqSMAdaptor::setMultipleElementProperty(*
* this-> Pipeline->GetProperty("BlockIndices"), blocks); *
* this->Pipeline->UpdateProperty("BlockIndices");*
Great thanks for the interest you gave to my request!
Regards
Papa
2011/7/11 Utkarsh Ayachit <utkarsh.ayachit at kitware.com>
> Not sure I understand the question. Can you elaborate please?
>
> Utkarsh
>
> Sent from my iPad
>
> On Jun 30, 2011, at 8:41 AM, papa ndéné NDIAYE <pnwireframe at gmail.com>
> wrote:
>
> > Hi all,
> >
> > I have a GUI that builds extract block filters and want to modify the
> BlockIndices property in it.
> > I got the thing about indices but how do I put a vtkSet in a
> vtkSMProperty?
> > should I fire a signal after modifying a property?
> >
> > I thank you in advance,
> > Regards,
> > Papa
> > _______________________________________________
> > 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 ParaView Wiki at:
> http://paraview.org/Wiki/ParaView
> >
> > Follow this link to subscribe/unsubscribe:
> > http://www.paraview.org/mailman/listinfo/paraview
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.paraview.org/pipermail/paraview/attachments/20110712/c1071278/attachment.htm>
More information about the ParaView
mailing list