Commit cb2a3b67 authored by Charles Law's avatar Charles Law
Browse files

Never use an lod if we do not have to

parent 830c27ad
......@@ -146,12 +146,12 @@ void vtkLODActor::Render(vtkRenderer *ren)
bestMapper = this->Mapper;
bestTime = bestMapper->GetRenderTime();
// cerr << " Start (" << bestMapper << ") with time: " << bestTime << endl;
if (bestTime > myTime)
{
this->Mappers->InitTraversal();
while ((mapper = this->Mappers->GetNextItem()) != NULL && bestTime != 0.0)
{
tempTime = mapper->GetRenderTime();
// cerr << " Mapper (" << mapper << ") RenderTime: " << tempTime <<endl;
// If the LOD has never been rendered, select it!
if (tempTime == 0.0)
......@@ -176,6 +176,7 @@ void vtkLODActor::Render(vtkRenderer *ren)
}
}
}
}
// record start rendering time
aTime = vtkTimerLog::GetCurrentTime();
......@@ -213,7 +214,6 @@ void vtkLODActor::Render(vtkRenderer *ren)
if (bestTime == 0.0)
{ // This is the first render.
bestMapper->SetRenderTime(myTime);
// cerr << " SETTING (" << bestMapper << ") RenderTime to " << myTime << endl;
}
else
{ // Running average of render time as a temporary fix for
......
Markdown is supported
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