Kaydet (Commit) ca537697 authored tarafından Michael Meeks's avatar Michael Meeks

chart2: take the mutex to update the chart structures.

Change-Id: I8ee6ec81913c008eeb67cd70a2490b523b0d8177
üst 65277f99
......@@ -128,6 +128,8 @@ void RenderThread::renderFrame()
mpChart->mpWindow->getContext().makeCurrent();
mpChart->renderFrame();
// FIXME: SwapBuffers can take a considerable time, it'd be
// nice if we didn't hold the chart mutex while doing that.
mpChart->mpWindow->getContext().swapBuffers();
mpChart->mpWindow->getContext().resetCurrent();
}
......@@ -1176,6 +1178,7 @@ int GL3DBarChart::calcTimeInterval(TimeValue &startTime, TimeValue &endTime)
void GL3DBarChart::updateScreenText()
{
SharedResourceAccess(maCond1, maCond2);
osl::MutexGuard aGuard(maMutex);
maScreenTextShapes.clear();
mpRenderer->ReleaseScreenTextShapes();
updateRenderFPS();
......
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