Commit 3486bf78 authored by Amy Squillacote's avatar Amy Squillacote
Browse files

BUG: fixing bug #2107; vtkTransmit***Piece filters were broken....

BUG: fixing bug #2107; vtkTransmit***Piece filters were broken. UPDATE_NUMBER_OF_PIECES was being overwritten/reinitialized so that the first process got part 0 of 1 instead of part 0 of <# procs>.
parent c66e7f9a
......@@ -24,7 +24,7 @@
#include "vtkPolyData.h"
#include "vtkStreamingDemandDrivenPipeline.h"
vtkCxxRevisionMacro(vtkTransmitPolyDataPiece, "1.19.4.1");
vtkCxxRevisionMacro(vtkTransmitPolyDataPiece, "1.19.4.2");
vtkStandardNewMacro(vtkTransmitPolyDataPiece);
vtkCxxSetObjectMacro(vtkTransmitPolyDataPiece,Controller,
......@@ -194,19 +194,25 @@ void vtkTransmitPolyDataPiece::RootExecute(vtkPolyData *input,
int ext[3];
int numProcs, i;
vtkStreamingDemandDrivenPipeline *extractExecutive =
vtkStreamingDemandDrivenPipeline::SafeDownCast(extract->GetExecutive());
vtkInformation *extractInfo = extractExecutive->GetOutputInformation(0);
// First, set up the pipeline and handle local request.
tmp->ShallowCopy(input);
tmp->SetReleaseDataFlag(0);
extract->SetCreateGhostCells(this->CreateGhostCells);
extract->SetInput(tmp);
vtkInformation *extractInfo = extract->GetExecutive()->GetOutputInformation(0);
extractExecutive->UpdateDataObject();
extractInfo->Set(vtkStreamingDemandDrivenPipeline::UPDATE_NUMBER_OF_PIECES(),
outInfo->Get(vtkStreamingDemandDrivenPipeline::UPDATE_NUMBER_OF_PIECES()));
extractInfo->Set(vtkStreamingDemandDrivenPipeline::UPDATE_PIECE_NUMBER(),
outInfo->Get(vtkStreamingDemandDrivenPipeline::UPDATE_PIECE_NUMBER()));
extractInfo->Set(vtkStreamingDemandDrivenPipeline::UPDATE_NUMBER_OF_GHOST_LEVELS(),
outInfo->Get(vtkStreamingDemandDrivenPipeline::UPDATE_NUMBER_OF_GHOST_LEVELS()));
extractInfo->Set(
vtkStreamingDemandDrivenPipeline::UPDATE_EXTENT_INITIALIZED(), 1);
extract->Update();
// Copy geometry without copying information.
output->CopyStructure(extract->GetOutput());
......
......@@ -24,7 +24,7 @@
#include "vtkStreamingDemandDrivenPipeline.h"
#include "vtkUnstructuredGrid.h"
vtkCxxRevisionMacro(vtkTransmitUnstructuredGridPiece, "1.18.8.1");
vtkCxxRevisionMacro(vtkTransmitUnstructuredGridPiece, "1.18.8.2");
vtkStandardNewMacro(vtkTransmitUnstructuredGridPiece);
vtkCxxSetObjectMacro(vtkTransmitUnstructuredGridPiece,Controller,
......@@ -165,13 +165,17 @@ void vtkTransmitUnstructuredGridPiece::RootExecute(vtkUnstructuredGrid *input,
<< "Altering request to try to avoid a deadlock.");
}
vtkStreamingDemandDrivenPipeline *extractExecutive =
vtkStreamingDemandDrivenPipeline::SafeDownCast(extract->GetExecutive());
// First, set up the pipeline and handle local request.
tmp->ShallowCopy(input);
tmp->SetReleaseDataFlag(0);
extract->SetCreateGhostCells(this->CreateGhostCells);
extract->SetInput(tmp);
vtkInformation *extractOutInfo =
extract->GetExecutive()->GetOutputInformation(0);
extractExecutive->UpdateDataObject();
vtkInformation *extractOutInfo = extractExecutive->GetOutputInformation(0);
extractOutInfo->Set(
vtkStreamingDemandDrivenPipeline::UPDATE_NUMBER_OF_PIECES(),
outInfo->Get(vtkStreamingDemandDrivenPipeline::UPDATE_NUMBER_OF_PIECES()));
......@@ -181,6 +185,8 @@ void vtkTransmitUnstructuredGridPiece::RootExecute(vtkUnstructuredGrid *input,
extractOutInfo->Set(
vtkStreamingDemandDrivenPipeline::UPDATE_NUMBER_OF_GHOST_LEVELS(),
outInfo->Get(vtkStreamingDemandDrivenPipeline::UPDATE_NUMBER_OF_GHOST_LEVELS()));
extractOutInfo->Set(
vtkStreamingDemandDrivenPipeline::UPDATE_EXTENT_INITIALIZED(), 1);
extract->Update();
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment