perandersson / playstate

PlayState
2 stars 0 forks source link

You cannot have thread-independent OpenGL states #29

Open perandersson opened 11 years ago

perandersson commented 11 years ago

OpenGL states are not thread local, which means that we cannot use the GfxProgram in more than one thread (the main thread).

perandersson commented 11 years ago

Potential solutions:

  1. Use THREAD_LOCAL macro
  2. Each RenderContext returns a state, which can be used by the GfxProgram.
perandersson commented 11 years ago

This issue is on hold until the need for when a GfxProgram is actually needed in multiple threads.