home *** CD-ROM | disk | FTP | other *** search
/ RISCWORLD 7 / RISCWORLD_VOL7.iso / Software / Issue4 / SDL / gcc346 / !SDL / man / SDL_Palette.3 < prev    next >
Encoding:
Text File  |  2006-09-20  |  1.8 KB  |  61 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_Palette"("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_Palette- Color palette for 8-bit pixel formats 
  13. <h2><a name='sect1' href='#toc1'>Structure Definition</a></h2>
  14. <p>
  15. <br>
  16. <pre>CWtypedef struct{
  17.   int ncolors;
  18.   SDL_Color *colors;
  19. } SDL_Palette;
  20. </pre><p>
  21.  
  22. <h2><a name='sect2' href='#toc2'>Structure Data</a></h2>
  23.  
  24. <dl>
  25.  
  26. <dt><b>ncolors</b> </dt>
  27. <dd>Number of colors used in this palette </dd>
  28.  
  29. <dt><b>colors</b> </dt>
  30. <dd>Pointer
  31. to <i><b>SDL_Color</b></i> structures that make up the palette. </dd>
  32. </dl>
  33.  
  34. <h2><a name='sect3' href='#toc3'>Description</a></h2>
  35. <p>
  36. Each pixel
  37. in an 8-bit surface is an index into the <b>colors</b> field of the <b>SDL_Palette</b>
  38. structure store in <i><b>SDL_PixelFormat</b></i>. A <b>SDL_Palette</b> should never need to be
  39. created manually. It is automatically created when SDL allocates a <b>SDL_PixelFormat</b>
  40. for a surface. The colors values of a <i><b>SDL_Surface</b></i>s palette can be set with
  41. the <i><b>SDL_SetColors</b></i>. 
  42. <h2><a name='sect4' href='#toc4'>See Also</a></h2>
  43. <p>
  44. <i><b>SDL_Color</b></i>, <i><b>SDL_Surface</b></i>, <i><b>SDL_SetColors</b></i> <i><b>SDL_SetPalette</b></i>
  45.  
  46. <!--
  47.   
  48.  <p>
  49.  
  50. <hr><p>
  51. <a name='toc'><b>Table of Contents</b></a><p>
  52. <ul>
  53. <li><a name='toc0' href='#sect0'>Name</a></li>
  54. <li><a name='toc1' href='#sect1'>Structure Definition</a></li>
  55. <li><a name='toc2' href='#sect2'>Structure Data</a></li>
  56. <li><a name='toc3' href='#sect3'>Description</a></li>
  57. <li><a name='toc4' href='#sect4'>See Also</a></li>
  58. </ul>
  59. </body>
  60. </html>
  61.