Re: [Paraview] custom filter doesn't update property in the Paraview UI

2016-08-09 Thread corinna reuter
Hi Cory, that's fine, I have some experience developing Qt UIs. But there is one difficulty with ParaView: I couldn't find any examples or documentation how to extend the existing widgets? Where do I plug in the additional elements, is it possible in some xml plugin description, or do I have to har

Re: [Paraview] custom filter doesn't update property in the Paraview UI

2016-08-08 Thread Cory Quammen
Hi Corinna, Utkarsh addressed the updating of properties in his earlier response about the directionality of property changes in ParaView: " 2. ParaView's properties are not bi-directional. They are only intended to be set on the UI side and pushed to the VTK side. There are of course exceptions

Re: [Paraview] custom filter doesn't update property in the Paraview UI

2016-08-08 Thread corinna reuter
Dear Cory, I wonder, if you still have an idea how to implement a filter that initializes its properties from upstream objects and updates these properties when those objects change. Isn't the whole ParaView designed such that changes are propagated along the pipeline? Why is it so complicated to r

Re: [Paraview] custom filter doesn't update property in the Paraview UI

2016-08-02 Thread corinna reuter
Dear Cory, dear all, sorry for not getting back to this topic earlier. Your solution works perfectly for the described problem. When I create e.g. a SphereSource and attach the TestProperty filter with its NPoints property, this property is initialized with the correct number of points in the spher

Re: [Paraview] custom filter doesn't update property in the Paraview UI

2016-07-15 Thread Cory Quammen
Corinna, Looking at the ParaView source code, I believe that vector properties with information properties must have a domain associated with them. In your case, you can add an IntRangeDomain with only a minimum defined: 0 seems like a reasonable minimum in your case. Keep your informati

Re: [Paraview] custom filter doesn't update property in the Paraview UI

2016-07-15 Thread corinna reuter
Cory, thanks for mentioning the TIFFReader proxy. I tried to modify my previously attached code such that the NPoints property links to a NPointsInfo property. Plus, I have removed the call "this->SetNPoints(nset);" inside vtkTestProperty::RequestData as suggested by Utkarsh. The NPoints property i

Re: [Paraview] custom filter doesn't update property in the Paraview UI

2016-07-14 Thread Cory Quammen
Corinna, Take a look at the TIFFReader SourceProxy in ParaViewCore/ServerManager/SMApplication/Resources/readers.xml. It has a CustomDataSpacing property that enables you to set voxel spacing, and has an associated information property CustomDataSpacingInfo that should initially populate the spaci

Re: [Paraview] custom filter doesn't update property in the Paraview UI

2016-07-14 Thread corinna reuter
On Thu, Jul 14, 2016 at 4:40 PM, Utkarsh Ayachit < utkarsh.ayac...@kitware.com> wrote: > There are a couple of things wrong with your plugin :). > I was expecting this, because I am only starting to learn plugin programming right now :) > > 1. A RequestData() implementation should never change

Re: [Paraview] custom filter doesn't update property in the Paraview UI

2016-07-14 Thread Utkarsh Ayachit
> I'll check the meaning of MTime. See the implementation of vtkSetMacro() in vtkSetGet.h. Every time the value changes, it call this->Modified() which updates the MTime. Since VTK is a demand-driven pipeline, changes to MTime is what tells the pipeline that the algorithm has been modified and nee

Re: [Paraview] custom filter doesn't update property in the Paraview UI

2016-07-14 Thread Utkarsh Ayachit
There are a couple of things wrong with your plugin :). 1. A RequestData() implementation should never change MTime of the filter. You code call SetNPoints() which changes MTime. 2. ParaView's properties are not bi-directional. They are only intended to be set on the UI side and pushed to the VTK

[Paraview] custom filter doesn't update property in the Paraview UI

2016-07-14 Thread corinna reuter
Hello, I would like to work on a filter that updates some of its properties from the filter input. As a demonstration, I attach a (quite minimal) "vtkTestProperty" filter algorithm, which takes vtkPolyData input, and which is supposed to copy input->GetNumberOfPoints() into the filter's "NPoints" p