View Full Version : "ping-pong" scheme
So I'm reading a paper that uses two 3d textures to hold data at 2 time steps(previous and current). The paper states that after each step the textures are swapped using a "so-called ping pong scheme". . .does anyone know what this means? :confused:
10-20-2004, 08:58 PM
I've seen nvidia use "ping-pong" to refer to the technique of drawing from one texture while updating another, then swapping their roles at the end of each frame. This lets the gpu pipeline the process of updating and drawing from a texture.
gmeed,where did you find this info, on their dev site? Did they say anything about how to implement this?
10-21-2004, 08:53 AM
I used google to find a vague reference to it in this presentation (http://developer.nvidia.com/attach/6795) . I'm not sure, but it sounds like they're doing what I mentioned in my previous post.
I'm pretty new to opengl, so no guarantees this is right, but here's my guess of how the technique works:
(1) Do glTexSubImage, or whatever you use to update textures, on, say, texture A. The call will return immediately even though the data is still being transferred to the card in the background. While this transfer is happening, you go about your normal drawing, using texture B.
(2) Then, when you draw the next frame, you'll update texture B with glTexSubImage and draw with texture A, essentially just swapping the roles of the textures.
Then, next frame, update A while you draw from B, etc.
"Ping-pong" seems like a pretty poor description of this technique, so I wouldn't be surprised if all this speculation is wrong. :p
Powered by vBulletin® Version 4.2.2 Copyright © 2015 vBulletin Solutions, Inc. All rights reserved.