Wine HQ

  WineHQ Menu
  WineHQ
  AppDB
  Bugzilla
  Wine Wiki
  Wine Forums
  About
  Introduction
  Features
  Screenshots
  Contributing
  News Blog
  World Wine News
  Press
  License
  Download
  Get Wine Now
  Support
  Getting Help
  FAQ
  Documentation
  HowTo
  Live Support Chat
  Paid Support
  Development
  Developers Guide
  Mailing Lists
  GIT
  Sending Patches
  To Do Lists
  Fun Projects
  Janitorial
  Winelib
  Status
  Resources
  WineConf
  Languages
English English
Español Español
  Search WineHQ

DirectDrawSurface inheritance tree

13.2. DirectDrawSurface inheritance tree

             Main
              |--------------\
              |              |
             DIB        Fake Z-Buffer
              |
              |------\---------\
              |      |         |
             User   DGA2   DIBTexture
        

Main provides a very simple base class that does not implement any of the image-related functions. Therefore it does not place any constraints on how the surface data is stored.

DIB stores the surface data in a DIB section. It is used by the Main DirectDraw driver to create off-screen surfaces.

User implements primary and backbuffer surfaces for the User DirectDraw driver. If it is a primary surface, it will attempt to keep itself synchronized to the window.

DGA2 surfaces claims an appropriate section of framebuffer space and lets DIB build its DIB section on top of it.

Fake Z-Buffer surfaces are used by Direct3D to indicate that a primary surface has an associated z-buffer. For a first implementation, it doesn't need to store any image data since it is just a placeholder.

(Actually 3D programs will rarely use Lock or GetDC on primary surfaces, backbuffers or z-buffers so we may want to arrange for lazy allocation of the DIB sections.)