OSDN Git Service

SDL_atomic_t サンプルコードを修正 https://wiki.libsdl.org/SDL_atomic_t?action=diff&rev1=3&rev2=4
[sdl2referencejp/sdl2referencejp.git] / SDL_SetError.html
1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">\r
2 <html lang="ja-JP">\r
3 <head>\r
4 <meta http-equiv="Content-Type" content="text/html; charset=Shift_JIS">\r
5 <meta http-equiv="Content-Style-Type" content="text/css">\r
6 <meta name="keywords" content="Simple Directmedia Layer SDL2.0">\r
7 <link rel="top" href="index.html" title="\83z\81[\83\80">\r
8 <link rel="parent" href="CategoryError.html" title="1\82Â\8fã">\r
9 <title>SDL_SetError</title>\r
10 </head>\r
11 <body>\r
12 <a href="index.html">\96Ú\8e\9f</a> - <a href="ApiByCategory.html">API(\8b@\94\\95Ê)</a> - <a href="CategoryError.html">\83G\83\89\81[\8f\88\97\9d</a> - SDL_SetError\r
13 <hr>\r
14 <h1>SDL_SetError</h1>\r
15 SDL\83G\83\89\81[\83\81\83b\83Z\81[\83W\82ð\90Ý\92è\82·\82é\r
16 <h2>\8d\\95¶</h2>\r
17 <code>int SDL_SetError(const char* fmt, ...)</code>\r
18 <h2>\88ø\90\94</h2>\r
19 <table border="1" summary="SDL_SetError">\r
20 <tr><td>fmt</td><td>printf()\8c`\8e®\82Ì\95\8e\9a\97ñ\8c`\8e®</td></tr>\r
21 <tr><td>...</td><td>fmt\95\8e\9a\97ñ\82Ì%\83g\81[\83N\83\93\82É\88ê\92v\82·\82é\92Ç\89Á\82Ì\88ø\90\94</td></tr>\r
22 </table>\r
23 <h2>\96ß\82è\92l</h2>\r
24 \8fí\82É-1\82ð\96ß\82·.\r
25 <h2>\83T\83\93\83v\83\8b\83R\81[\83h</h2>\r
26 <h3>(1)</h2>\r
27 <p>\r
28 <code>\r
29 <pre>\r
30 SDL_SetError("\97\\8aú\82µ\82È\82¢\88Ù\8fí\82ª\94­\90\82µ\82½!");\r
31 </pre>\r
32 </code>\r
33 </p>\r
34 <h3>(2)</h2>\r
35 <p>\r
36 <code>\r
37 <pre>\r
38 int errorCode = 0;\r
39 ...\r
40 errorCode = -37;\r
41 ...\r
42 if (errorCode &lt; 0)\r
43     SDL_SetError("\97\\8aú\82µ\82È\82¢\88Ù\8fí\82ª\94­\90\82µ\82½: \83G\83\89\81[\83R\81[\83h %d", errorCode);\r
44 </pre>\r
45 </code>\r
46 </p>\r
47 <h2>\8fÚ\8d×</h2>\r
48 \82±\82Ì\8aÖ\90\94\82ð\8cÄ\82Ô\82Æ, \88È\91O\82Ì\83G\83\89\81[\83\81\83b\83Z\81[\83W\82Í\8fã\8f\91\82«\82³\82ê\82é.\r
49 <h2>\8aÖ\98A\8d\80\96Ú(\8aÖ\90\94)</h2>\r
50 <a href="SDL_ClearError.html">SDL_ClearError</a><br>\r
51 <a href="SDL_GetError.html">SDL_GetError</a><br>\r
52 <h2>SDL Wiki\82Ö\82Ì\83\8a\83\93\83N</h2>\r
53 <a href="https://wiki.libsdl.org/SDL_SetError">SDL_SetError - SDL Wiki</a>\r
54 <hr>\r
55 </body>\r
56 </html>\r