Triple buffering

From Wikipedia, the free encyclopedia

In computer graphics, triple buffering is a variant on double buffering, a technique for drawing graphics that shows no (or less) flicker, shearing, and tearing artifacts.

Triple buffering attempts to provide a speed improvement over double buffering. In real life applications, this often involves trying to abstract the graphics drawing operations from being synchronized with the monitor's refresh rate. Typically this involves frames being drawn at a rate lower than or higher than the monitor's frame rate (a variable frame rate) without the usual effects this would cause (namely flickering, shearing and tearing).

Due to the software algorithm not having to poll the graphics hardware for monitor refresh events, the algorithm is free to run as fast as possible. This is not the only method of triple buffering available, but is the most prevalent on the PC architecture where the speed of the target machine is highly variable.

Another method of triple buffering involves synchronising with the monitor frame rate, and simply using the third buffer as a method of providing breathing room for changing demands in the amount of graphics drawn. This is the use of a buffer in the true sense whereby the buffer acts as a reservoir. Such a method requires a higher minimum specification of the target hardware but provides a consistent (vs. variable) frame rate.

Triple buffering implies three buffers, but the method can be extended to as many buffers as is practical for the application. Usually, there is no advantage to using more than three buffers.

If the system has two color buffers A and B, it can display buffer B while drawing a new picture (rendering) into buffer A. When it is done rendering into buffer A, the system needs to wait until buffer B is in the monitor's vertical blank period before swapping buffers. This waiting period could be several milliseconds (an eternity to a computer) during which neither buffer can be touched. When the monitor is in vertical blank it can either swap buffers A and B and then start rendering into buffer B (page flipping) or copy buffer A into buffer B and render into buffer A.

If the system has three color buffers A, B and C, it does not have to wait to swap buffers. It can display buffer B while rendering into buffer A. When done rendering into buffer A, it can start rendering into buffer C immediately. When the monitor is in vertical blank, it can display buffer A and make buffer B available for reuse.

If the system always renders buffers in less time than it takes to display a buffer once on the monitor, the computer will wait for the monitor regardless of how many buffers there are. In this particular case triple buffering has no advantage over double buffering.

Also, third buffer uses additional memory, which could be used for other data (like textures).

Advanced Search
Included Web Search Engines


Safe Search

close

Top Matching Results

Occasionally Search.com will highlight specialized results that are based on the context of your query. Examples of specialized results include specific links to news, images, or video.

Top Matching Results may highlight information from other Search.com pages, content from the CNET Network of sites, or third party content. The listings are based purely on relevance. Search.com does not receive payment for listings in this section but our partners that provide this data may get paid for listing these products.

Sponsored Links

This section contains paid listings which have been purchased by companies that want to have their sites appear for specific search terms and related content. These listings are administered, sorted and maintained by a third party and are not endorsed by Search.com.

Search Results

Search.com sends your search query to several search engines at one time and integrates the results into one list which has been sorted by relevance using Search.com's proprietary algorithm. You can customize the list of search engines included in your metasearch from the preferences.

The search engines that are used in your metasearch may allow companies to pay to have their Web sites included within the results. To view the Paid Inclusion policy for a specific search engine, please visit their Web site. Search.com does not accept payment or share revenue with any search engine partner for listings in this section.