Welcome to mirror list, hosted at ThFree Co, Russian Federation.

oglcontextfactory.cpp « drape - github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: f4ffcc19fc0c4406900eb88970acc8eef163ae68 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#include "drape/oglcontextfactory.hpp"

namespace dp
{

ThreadSafeFactory::ThreadSafeFactory(OGLContextFactory * factory)
  : m_factory(factory)
{
}

ThreadSafeFactory::~ThreadSafeFactory()
{
  delete m_factory;
}

OGLContext *ThreadSafeFactory::getDrawContext()
{
  threads::MutexGuard lock(m_mutex);
  return m_factory->getDrawContext();
}

OGLContext *ThreadSafeFactory::getResourcesUploadContext()
{
  threads::MutexGuard lock(m_mutex);
  return m_factory->getResourcesUploadContext();
}

} // namespace dp