added mutex and std::map to keep track of tasks in progress; Scene waits for their completion

git-svn-id: svn://anubis/fart/trunk@232 7f9b0f55-74a9-4bce-be96-3c2cd072584d
This commit is contained in:
Josh Holtrop committed 2009-04-13 03:31:44 +00:00
1 parent 97392f2271
commit 898bf3a01c
3 files changed
+31 -5

No files matched your search

+7 -1
View File
@@ -160,7 +160,13 @@ void Scene::render()
{
/* work on tasks in this thread until there are no more */
taskLoop();
/* TODO: wait until all data has arrived */
/* TODO: change wait condition */
for (;;)
{
if (m_distrib.getNumTasksInProgress() == 0)
break;
usleep(100000);
}
}
if (m_verbose)