Commit 6c314a22 authored by Jon Woodring's avatar Jon Woodring
Browse files

Unrolled loops in vtkPoints::CalculateBounds.

Change-Id: Id5688c83454be94057dd126e9e1a3040e82fc58a
parent a218f1e8
......@@ -101,17 +101,12 @@ void vtkPoints::ComputeBounds()
for (i=0; i<this->GetNumberOfPoints(); i++)
{
x = this->GetPoint(i);
for (j=0; j<3; j++)
{
if ( x[j] < this->Bounds[2*j] )
{
this->Bounds[2*j] = x[j];
}
if ( x[j] > this->Bounds[2*j+1] )
{
this->Bounds[2*j+1] = x[j];
}
}
this->Bounds[0] = x[0] < this->Bounds[0] ? x[0] : this->Bounds[0];
this->Bounds[1] = x[0] > this->Bounds[1] ? x[0] : this->Bounds[1];
this->Bounds[2] = x[1] < this->Bounds[2] ? x[1] : this->Bounds[2];
this->Bounds[3] = x[1] > this->Bounds[3] ? x[1] : this->Bounds[3];
this->Bounds[4] = x[2] < this->Bounds[4] ? x[2] : this->Bounds[4];
this->Bounds[5] = x[2] > this->Bounds[5] ? x[2] : this->Bounds[5];
}
this->ComputeTime.Modified();
......
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