Commit 34bc9165 authored by Dave Demarle's avatar Dave Demarle

BUG: Fix visible cell selection in ParaViews MPIRenderServer mode by...

BUG: Fix visible cell selection in ParaViews MPIRenderServer mode by preventing interpolation. BUG: Make selection use back buffer in parallel rendering.
parent eac8b2b9
......@@ -23,7 +23,7 @@
#include "vtkTimerLog.h"
#include "vtkUnsignedCharArray.h"
vtkCxxRevisionMacro(vtkCompositeRenderManager, "1.9");
vtkCxxRevisionMacro(vtkCompositeRenderManager, "1.10");
vtkStandardNewMacro(vtkCompositeRenderManager);
vtkCxxSetObjectMacro(vtkCompositeRenderManager, Compositer, vtkCompositer);
......@@ -68,7 +68,10 @@ void vtkCompositeRenderManager::PreRenderProcessing()
{
// Turn swap buffers off before the render so the end render method has a
// chance to add to the back buffer.
this->RenderWindow->SwapBuffersOff();
if (this->UseBackBuffer)
{
this->RenderWindow->SwapBuffersOff();
}
}
//----------------------------------------------------------------------------
......@@ -108,8 +111,11 @@ void vtkCompositeRenderManager::PostRenderProcessing()
this->WriteFullImage();
// Swap buffers here.
this->RenderWindow->SwapBuffersOn();
// Swap buffers here
if (this->UseBackBuffer)
{
this->RenderWindow->SwapBuffersOn();
}
this->RenderWindow->Frame();
}
......
......@@ -70,7 +70,7 @@ const int vtkParallelRenderManager::REN_INFO_DOUBLE_SIZE =
const int vtkParallelRenderManager::LIGHT_INFO_DOUBLE_SIZE =
sizeof(vtkParallelRenderManager::LightInfoDouble)/sizeof(double);
vtkCxxRevisionMacro(vtkParallelRenderManager, "1.67");
vtkCxxRevisionMacro(vtkParallelRenderManager, "1.68");
//----------------------------------------------------------------------------
vtkParallelRenderManager::vtkParallelRenderManager()
......@@ -125,6 +125,8 @@ vtkParallelRenderManager::vtkParallelRenderManager()
this->AddedRMIs = 0;
this->Timer = vtkTimerLog::New();
this->UseBackBuffer = 1;
}
//----------------------------------------------------------------------------
......@@ -218,6 +220,10 @@ void vtkParallelRenderManager::PrintSelf(ostream &os, vtkIndent indent)
os << indent << "ForceRenderWindowSize: "
<< this->ForceRenderWindowSize
<< endl;
os << indent << "UseBackBuffer: "
<< (this->UseBackBuffer ? "on" : "off") << endl;
}
//----------------------------------------------------------------------------
......
......@@ -378,6 +378,15 @@ public:
# pragma reset woff 3303
#endif
//Description:
//The default is to allow the use of the back buffer for compositing.
//If set to false, this will prevent to manager from swapping buffers.
//This allows something else (for instance VisibleCellSelection) to
//control front/back buffer swapping.
vtkSetMacro(UseBackBuffer, int);
vtkGetMacro(UseBackBuffer, int);
vtkBooleanMacro(UseBackBuffer, int);
protected:
vtkParallelRenderManager();
~vtkParallelRenderManager();
......@@ -553,6 +562,8 @@ protected:
//ETX
int AddedRMIs;
int UseBackBuffer;
private:
vtkParallelRenderManager(const vtkParallelRenderManager &); //Not implemented
void operator=(const vtkParallelRenderManager &); //Not implemented
......
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