home *** CD-ROM | disk | FTP | other *** search
/ RISCWORLD 7 / RISCWORLD_VOL7.iso / Software / Issue4 / SDL / gcc346 / !SDL / man / SDL_Surface.3 < prev    next >
Encoding:
Text File  |  2006-09-20  |  3.9 KB  |  143 lines

  1. <!-- manual page source format generated by PolyglotMan v3.0.8+X.Org, -->
  2. <!-- available at http://polyglotman.sourceforge.net/ -->
  3.  
  4. <html>
  5. <head>
  6. <title>"SDL_Surface"("3") manual page</title>
  7. </head>
  8. <body bgcolor='#efefef' text='black' link='blue' vlink='#551A8B' alink='red'>
  9. <a href='#toc'>Table of Contents</a><p>
  10.  
  11. <h2><a name='sect0' href='#toc0'>Name</a></h2>
  12. SDL_Surface- Graphical Surface Structure 
  13. <h2><a name='sect1' href='#toc1'>Structure Definition</a></h2>
  14. <p>
  15. <br>
  16. <pre>CWtypedef struct SDL_Surface {
  17.         Uint32 flags;                           /* Read-only */
  18.         SDL_PixelFormat *format;                /* Read-only */
  19.         int w, h;                               /* Read-only */
  20.         Uint16 pitch;                           /* Read-only */
  21.         void *pixels;                           /* Read-write */
  22.         /* clipping information */
  23.         SDL_Rect clip_rect;                     /* Read-only */
  24.         /* Reference count -- used when freeing surface */
  25.         int refcount;                           /* Read-mostly */
  26. <tt> </tt> <tt> </tt> /* This structure also contains private fields not shown here */
  27. } SDL_Surface;
  28. </pre><p>
  29.  
  30. <h2><a name='sect2' href='#toc2'>Structure Data</a></h2>
  31.  
  32. <dl>
  33.  
  34. <dt><b>flags</b> </dt>
  35. <dd>Surface flags </dd>
  36.  
  37. <dt><b>format</b> </dt>
  38. <dd>Pixel <i>format</i> </dd>
  39.  
  40. <dt><b>w, h</b> </dt>
  41. <dd>Width and height
  42. of the surface </dd>
  43.  
  44. <dt><b>pitch</b> </dt>
  45. <dd>Length of a surface scanline in bytes </dd>
  46.  
  47. <dt><b>pixels</b> </dt>
  48. <dd>Pointer
  49. to the actual pixel data </dd>
  50.  
  51. <dt><b>clip_rect</b> </dt>
  52. <dd>surface clip <i>rectangle</i> </dd>
  53. </dl>
  54.  
  55. <h2><a name='sect3' href='#toc3'>Description</a></h2>
  56. <p>
  57. <b>SDL_Surface</b>'s
  58. represent areas of "graphical" memory, memory that can be drawn to. The
  59. video framebuffer is returned as a <b>SDL_Surface</b> by <i><b>SDL_SetVideoMode</b></i> and
  60. <i><b>SDL_GetVideoSurface</b></i>. Most of the fields should be pretty obvious. <b>w</b> and <b>h</b>
  61. are the width and height of the surface in pixels. <b>pixels</b> is a pointer to
  62. the actual pixel data, the surface should be <i>locked</i> before accessing this
  63. field. The <b>clip_rect</b> field is the clipping rectangle as set by <i><b>SDL_SetClipRect</b></i>.
  64. <p>
  65. The following are supported in the <b>flags</b> field. 
  66. <dl>
  67.  
  68. <dt><b>SDL_SWSURFACE</b> </dt>
  69. <dd>Surface is
  70. stored in system memory </dd>
  71.  
  72. <dt><b>SDL_HWSURFACE</b> </dt>
  73. <dd>Surface is stored in video memory
  74. </dd>
  75.  
  76. <dt><b>SDL_ASYNCBLIT</b> </dt>
  77. <dd>Surface uses asynchronous blits if possible </dd>
  78.  
  79. <dt><b>SDL_ANYFORMAT</b>
  80. </dt>
  81. <dd>Allows any pixel-format (Display surface) </dd>
  82.  
  83. <dt><b>SDL_HWPALETTE</b> </dt>
  84. <dd>Surface has exclusive
  85. palette </dd>
  86.  
  87. <dt><b>SDL_DOUBLEBUF</b> </dt>
  88. <dd>Surface is double buffered (Display surface) </dd>
  89.  
  90. <dt><b>SDL_FULLSCREEN</b>
  91. </dt>
  92. <dd>Surface is full screen (Display Surface) </dd>
  93.  
  94. <dt><b>SDL_OPENGL</b> </dt>
  95. <dd>Surface has an OpenGL
  96. context (Display Surface) </dd>
  97.  
  98. <dt><b>SDL_OPENGLBLIT</b> </dt>
  99. <dd>Surface supports OpenGL blitting
  100. (Display Surface) </dd>
  101.  
  102. <dt><b>SDL_RESIZABLE</b> </dt>
  103. <dd>Surface is resizable (Display Surface)
  104. </dd>
  105.  
  106. <dt><b>SDL_HWACCEL</b> </dt>
  107. <dd>Surface blit uses hardware acceleration </dd>
  108.  
  109. <dt><b>SDL_SRCCOLORKEY</b> </dt>
  110. <dd>Surface
  111. use colorkey blitting </dd>
  112.  
  113. <dt><b>SDL_RLEACCEL</b> </dt>
  114. <dd>Colorkey blitting is accelerated with
  115. RLE </dd>
  116.  
  117. <dt><b>SDL_SRCALPHA</b> </dt>
  118. <dd>Surface blit uses alpha blending </dd>
  119.  
  120. <dt><b>SDL_PREALLOC</b> </dt>
  121. <dd>Surface
  122. uses preallocated memory </dd>
  123. </dl>
  124.  
  125. <h2><a name='sect4' href='#toc4'>See Also</a></h2>
  126. <p>
  127. <i><b>SDL_PixelFormat</b></i> 
  128. <!--
  129.   
  130.  <p>
  131.  
  132. <hr><p>
  133. <a name='toc'><b>Table of Contents</b></a><p>
  134. <ul>
  135. <li><a name='toc0' href='#sect0'>Name</a></li>
  136. <li><a name='toc1' href='#sect1'>Structure Definition</a></li>
  137. <li><a name='toc2' href='#sect2'>Structure Data</a></li>
  138. <li><a name='toc3' href='#sect3'>Description</a></li>
  139. <li><a name='toc4' href='#sect4'>See Also</a></li>
  140. </ul>
  141. </body>
  142. </html>
  143.