View Full Version : glTexSubImage2D blocking?

08-06-2011, 12:35 PM
I'm working on an application with alot of device -> host and host -> device transfers using PBOs.

I know that the device -> host transfer will be blocking on the glMapBuffer call which follows the async glReadPixels call. So in order to avoid stalling the rendering thread on should delay the glMapBuffer call as much as possible.

However, what about the host -> device transfer? Will any of the calls after the async glTexSubImage2D call block the rendering thread? Should one add a delay between the glTexSubImage2D call and binding and using the device texture?

08-07-2011, 10:49 PM
Most of ISV will choose to defer the host->device transfer,It's usually happen when next draw issued and the texture is active. but thing may different when the glTexSubImage2D call is updated a PBO,the transfer may take place immediately.