[vtkusers] CONTINUE_EXECUTING with vtkinformation
Felipe Bordeu
felipe.bordeu at ec-nantes.fr
Thu Jul 25 12:29:41 EDT 2013
Finally I found a hack. If I add this line
inInfo->Set(vtkStreamingDemandDrivenPipeline::UPDATE_RESOLUTION(), 1.0);
in the RequestUpdateExtent() of the filter, the source is recomputed
every iteration of the CONTINUE_EXECUTING.
(using vtk included in Paraview 4.0.1, and an unstructured mesh).
Felipe
Le 25/07/2013 14:46, Biddiscombe, John A. a écrit :
>
> Normally you'd modify the UPDATE_EXTENT itself and the pipeline would
> trigger the source to regenerate data because it would 'know' that the
> new UPDATE_EXTENT didn't match the old one.
>
> if you are instead sending your own custom key and using that to
> indirectly modify the update extent, then your best bet would be to
> simply stuff a this->Modified() inside the request update extent
> method of the source,( if the new key doesn't match the last value,
> and so a reexecution is required).
>
> [As long as you don't put a modified in after the request data --
> because the pipeline will get confused about the true modified time]
> then you should be ok.
>
> JB
>
> *From:*vtkusers-bounces at vtk.org [mailto:vtkusers-bounces at vtk.org] *On
> Behalf Of *Felipe Bordeu
> *Sent:* 25 July 2013 14:36
> *Cc:* vtkusers
> *Subject:* Re: [vtkusers] CONTINUE_EXECUTING with vtkinformation
>
> Thanks, now I can pass the information from the filter to the source
> using:
> - The CONTINUE_EXECUTING in the RequestData() in the filter
> - In the RequestUpdateExtent() of the filter I have
>
> vtkInformation *inInfo = inputVector[0]->GetInformationObject(0);
> double val[3] ...
> inInfo->Set(vtkPXDMFDocumentBaseStructure::UPDATE_FIXED_DIMENSIONS(),
> val, 3);
> request->AppendUnique(vtkExecutive::KEYS_TO_COPY(),
> vtkPXDMFDocumentBaseStructure::UPDATE_FIXED_DIMENSIONS());
>
> -The information key is recovered in the REQUEST_UPDATE_EXTENT()
> request in the source (when I change something in the source).
>
> When I create the filter, the filter gets executed the correct number
> of times, BUT the source is never executed (the ProcessRequest member
> function in the source is never called).
>
> What key or option I have to enable to re execute a source for a
> downstream filter??
> Or a way to tell the source is out-of-date?
>
> Felipe
>
>
>
>
>
> Le 25/07/2013 10:19, Biddiscombe, John A. a écrit :
>
> did you add the vector you want to pass upstream to the
> KEYS_TO_COPY vector. My memory is hazy, but what you are trying to
> do ought to work.
>
> JB
>
> *From:*vtkusers-bounces at vtk.org <mailto:vtkusers-bounces at vtk.org>
> [mailto:vtkusers-bounces at vtk.org] *On Behalf Of *Felipe Bordeu
> *Sent:* 25 July 2013 10:02
> *To:* vtkusers
> *Subject:* [vtkusers] CONTINUE_EXECUTING with vtkinformation
>
> Hello,
>
> I have a source (home made reader) that is capable of generate
> data depending on some options.
> I like to control theses options using a filter way down in the
> pipeline. This means that I would like to send a vtkinformation
> upstream in the pipeline and also iterate for different values of
> this options. Something like the TemporalStatistics filter but not
> over time.
>
> Till now, I tried to use the
> vtkStreamingDemandDrivenPipeline::CONTINUE_EXECUTING information
> (in the filter) to iterate over the data. My filter is re-executed
> but my source get executed only once.
>
> Also tried to set a vtkInformationDoubleVectorKey to the
> inputVector in the RequestUpdateExtent() of my filter with some
> data but this information is never passed upstream.
>
> Is this possible??? or we can do this only for time.
>
> Thanks for all
> Felipe
>
>
>
>
> --
>
> Felipe Bordeu Weldt
>
> Ingénieur de Recherche
>
> -------------------------------------
>
> Tél. : 33 (0)2 40 37 16 57
>
> Fax. : 33 (0)2 40 74 74 06
>
> Felipe.Bordeu at ec-nantes.fr <mailto:Felipe.Bordeu at ec-nantes.fr>
>
> Institut GeM - UMR CNRS 6183
>
> École Centrale Nantes
>
> 1 Rue de La Noë, 44321 Nantes, FRANCE
>
> -------------------------------------
>
>
>
>
> --
> Felipe Bordeu Weldt
> Ingénieur de Recherche
> -------------------------------------
> Tél. : 33 (0)2 40 37 16 57
> Fax. : 33 (0)2 40 74 74 06
> Felipe.Bordeu at ec-nantes.fr <mailto:Felipe.Bordeu at ec-nantes.fr>
> Institut GeM - UMR CNRS 6183
> École Centrale Nantes
> 1 Rue de La Noë, 44321 Nantes, FRANCE
> -------------------------------------
--
Felipe Bordeu Weldt
Ingénieur de Recherche
-------------------------------------
Tél. : 33 (0)2 40 37 16 57
Fax. : 33 (0)2 40 74 74 06
Felipe.Bordeu at ec-nantes.fr
Institut GeM - UMR CNRS 6183
École Centrale Nantes
1 Rue de La Noë, 44321 Nantes, FRANCE
-------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20130725/bc4e97d2/attachment.htm>
More information about the vtkusers
mailing list