Retained mode

From Wikipedia, the free encyclopedia
Jump to navigation Jump to search

Template:Short description Template:More citations needed

Retained mode in computer graphics is a major pattern of API design in graphics libraries,[1] in which

Immediate mode is an alternative approach. Historically, retained mode has been the dominant style in GUI libraries;[4] however, both can coexist in the same library and are not necessarily exclusionary in practice.[5]

Overview

File:Retail-mode-graphics-api.png
Schematic explanation of a retained mode graphics API

In retained mode the client calls do not directly cause actual rendering, but instead update an abstract internal model (typically a list of objects) which is maintained within the library's data space. This allows the library to optimize when actual rendering takes place along with the processing of related objects.[2]

Some techniques to optimize rendering include:

Example of coexistence with immediate mode in the same library is OpenGL.Script error: No such module "Unsubst".Script error: No such module "Unsubst".[10] OpenGL has immediate mode functions that can use previously defined server side objects (textures, vertex buffers and index buffers, shaders, etc.) without resending unchanged data.[11][12]

Examples of retained mode rendering systems include Windows Presentation Foundation,[2] SceneKit on macOS,[13] and PHIGS.

File:Immediate-mode-graphics-api.png
Schematic explanation of an immediate mode graphics API in contrast

See also

References

Template:Reflist

  1. Script error: No such module "citation/CS1".
  2. a b c Script error: No such module "citation/CS1".
  3. Script error: No such module "citation/CS1".
  4. Script error: No such module "citation/CS1".
  5. Script error: No such module "citation/CS1".
  6. Script error: No such module "citation/CS1".
  7. Script error: No such module "citation/CS1".
  8. Script error: No such module "citation/CS1".
  9. Script error: No such module "citation/CS1".
  10. Script error: No such module "citation/CS1".
  11. Script error: No such module "citation/CS1".
  12. Script error: No such module "citation/CS1".
  13. Script error: No such module "citation/CS1".