OSDN Git Service

SDL_atomic_t サンプルコードを修正 https://wiki.libsdl.org/SDL_atomic_t?action=diff&rev1=3&rev2=4
[sdl2referencejp/sdl2referencejp.git] / SDL_CreateRGBSurfaceWithFormat.html
1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2 <html lang="ja-JP">
3 <head>
4 <meta http-equiv="Content-Type" content="text/html; charset=Shift_JIS">
5 <meta http-equiv="Content-Style-Type" content="text/css">
6 <meta name="keywords" content="Simple Directmedia Layer SDL2.0">
7 <link rel="top" href="index.html" title="\83z\81[\83\80">
8 <link rel="parent" href="CategorySurface.html" title="1\82Â\8fã">
9 <title>SDL_CreateRGBSurfaceWithFormat</title>
10 </head>
11 <body>
12 <a href="index.html">\96Ú\8e\9f</a> - <a href="ApiByCategory.html">API(\8b@\94\\95Ê)</a> - <a href="CategorySurface.html">\83T\81[\83t\83F\83C\83X\82Ì\90\90¬\82Æ\92P\8f\83\82È\95`\89æ</a> - SDL_CreateRGBSurfaceWithFormat
13 <hr>
14 <h1>SDL_CreateRGBSurfaceWithFormat</h1>
15 \8aù\91\82Ì\83s\83N\83Z\83\8b\83f\81[\83^\82©\82ç\90V\82µ\82¢RGB\83T\81[\83t\83F\83C\83X\82ð\90\90¬\82·\82é
16 <h2>\8d\\95¶</h2>
17 <code>SDL_Surface* SDL_CreateRGBSurfaceWithFormat(Uint32 flags, int width, int height, int depth, Uint32 format)</code>
18 <h2>\88ø\90\94</h2>
19 <table border="1" summary="SDL_CreateRGBSurfaceWithFormat">
20 <tr><td>flags</td><td>\8c»\8dÝ\82Í\8eg\82í\82ê\82È\82¢. \8fí\82É0\82Æ\82·\82é\82±\82Æ.</td></tr>
21 <tr><td>width</td><td>\83T\81[\83t\83F\83C\83X\82Ì\95\9d</td></tr>
22 <tr><td>height</td><td>\83T\81[\83t\83F\83C\83X\82Ì\8d\82\82³</td></tr>
23 <tr><td>depth</td><td>\83T\81[\83t\83F\83C\83X\82Ì\83r\83b\83g\90[\93x</td></tr>
24 <tr><td>format</td><td>\83T\81[\83t\83F\83C\83X\82Ì<a href="SDL_PixelFormatEnum.html">\83s\83N\83Z\83\8b\8c`\8e®</a></td></tr>
25 </table>
26 <h2>\96ß\82è\92l</h2>
27 \90¬\8c÷\82Ì\82Æ\82«\90\90¬\82³\82ê\82½<a href="SDL_Surface.html">SDL_Surface</a>, \8e¸\94s\82Ì\82Æ\82«NULL\82ð\96ß\82·.
28 <a href="SDL_GetError.html">SDL_GetError()</a>\82ð\8cÄ\82ñ\82Å\8fÚ\8d×\82ð\92m\82é\82±\82Æ\82ª\82Å\82«\82é.
29 <h2>\8fÚ\8d×</h2>
30 <p>
31 \83\81\83\82\83\8a\82ð\8am\95Û\82Å\82«\82È\82©\82Á\82½\82Æ\82«\82ÍNULL\82ð\96ß\82·.
32 </p>
33 <h2>\83T\83\93\83v\83\8b\83R\81[\83h</h2>
34 <p>
35 <code>
36 <pre>
37     /* \8ae\83s\83N\83Z\83\8b\82Ì\83o\83C\83g\8f\87\82ªR,G,B,A\82Ì32bit\83T\81[\83t\83F\83C\83X\82ð
38        \83e\83N\83X\83`\83\83\97p\82ÉOpenGL\82ð\8eg\82¤\82æ\82¤\82É\97v\8b\81\82µ\82Ä\90\90¬\82·\82é */
39
40     SDL_Surface* surf;
41     surf = SDL_CreateRGBSurfaceWithFormat(0, width, height, 32, SDL_PIXELFORMAT_RGBA32);
42     if (surf == NULL) {
43         SDL_Log("SDL_CreateRGBSurfaceWithFormat() \8e¸\94s: %s", SDL_GetError());
44         exit(1);
45     }
46 </pre>
47 </code>
48 </p>
49 <h2>\83o\81[\83W\83\87\83\93</h2>
50 <p>
51 \82±\82Ì\8aÖ\90\94\82ÍSDL 2.0.5\88È\8d~\82Å\8eg\82¦\82é.
52 </p>
53 <h2>\8aÖ\98A\8d\80\96Ú(\8aÖ\90\94)</h2>
54 <a href="SDL_CreateRGBSurface.html">SDL_CreateRGBSurface</a><br>
55 <a href="SDL_CreateRGBSurfaceWithFormatFrom.html">SDL_CreateRGBSurfaceWithFormatFrom</a><br>
56 <a href="SDL_FreeSurface.html">SDL_FreeSurface</a><br>
57 <h2>SDL Wiki\82Ö\82Ì\83\8a\83\93\83N</h2>
58 <a href="https://wiki.libsdl.org/SDL_CreateRGBSurfaceWithFormat">SDL_CreateRGBSurfaceWithFormat - SDL Wiki</a>
59 <hr>
60 </body>
61 </html>