[Paraview] Algorithm causing reader RequestData when running

Berk Geveci berk.geveci at kitware.com
Fri Mar 26 11:46:09 EDT 2010


Burlen is correct.

On Fri, Mar 26, 2010 at 11:30 AM, Burlen Loring <burlen.loring at gmail.com> wrote:
> If I'm not mistaken, when creating a VTK pipeline inside of a PV filter, you
> need to make a shallow copy of the input dataset in order to keep the PV
> pipeline isolated as your VTK pipeline executes.
>
> Try making a shallow copy of "input" and passing that into
> "extractBlockFilter", and see if it helps.
>
> Burlen
>
> Paul Edwards wrote:
>>
>> Hi,
>>
>> I am writing an algorithm to operate on a vtkMultiBlockDataSet where I
>> would like to extract blocks depending on field data that is set.
>> Internally in my algorithm I am using the vtkExtractBlock filter and
>> when this is updated it causes the RequestData for my reader to be
>> executed again.  This doesn't happen when applying ExtractBlock in
>> ParaView.  Below I have included an example RequestData that causes
>> the data to be reloaded (note: this only happens when running in
>> parallel):
>>
>> 8<-----------------------------------------------------------------
>> int vtkTestMulti::RequestData(
>>        vtkInformation* vtkNotUsed(request),
>>        vtkInformationVector** inputVector,
>>        vtkInformationVector* outputVector)
>> {
>>
>>    vtkInformation* inInfo = inputVector[0]->GetInformationObject(0);
>>    vtkMultiBlockDataSet* input = vtkMultiBlockDataSet::SafeDownCast(
>>            inInfo->Get(vtkDataObject::DATA_OBJECT()));
>>
>>    vtkInformation* outInfo = outputVector->GetInformationObject(0);
>>    vtkMultiBlockDataSet* output = vtkMultiBlockDataSet::SafeDownCast(
>>            outInfo->Get(vtkDataObject::DATA_OBJECT()));
>>
>>    VTK_CREATE(vtkExtractBlock, extractBlockFilter);
>>    extractBlockFilter->SetInput(input);
>>    extractBlockFilter->AddIndex(1);
>>    extractBlockFilter->Update();
>>    output->ShallowCopy(extractBlockFilter->GetOutput());
>>
>>    return 1;
>> }
>> ----------------------------------------------------------------->8
>>
>> Can anyone see what I am doing wrong or provide any pointers for where to
>> look?
>>
>> Thanks in advance,
>> Paul
>> _______________________________________________
>> 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
>>
>
> _______________________________________________
> 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
>


More information about the ParaView mailing list