<!DOCTYPE html>
<html>
<head>
<title>LEXSDL_InitIMG</title>
<link rel="stylesheet" href="styles.css">
</head>
<header>
<h1>LEXSDL_InitIMG</h1>
<hr>
</header>
<body>
<p>
Initialises <a href=https://wiki.libsdl.org/SDL_image>SDL_image</a> with the desired flags or default ones.
</p>
<p>
A full list of init flags and info on Initializing SDL_image can be found in the <a href=https://wiki.libsdl.org/SDL_image/IMG_Init>Official Documentation</a>.<br>
The normal <a href=https://wiki.libsdl.org/SDL_image/IMG_Init>IMG_Init()</a> can be used without problems or doing something special, this function is for completness and adding defaults.<br>
</p>
<h2>Function</h2>
<code><ul>
<span style="color:#2980b9">int</span> LEXSDL_InitIMG<a style="color:#66cf8d">(</a><a style="color:#2980b9">int</a> flags<a style="color:#66cf8d">);</a>
</ul></code>
<h2>Return</h2>
<ul>
<span style="color:#f67400">0</span><a style="color:#66cf8d">:</a> Initialization was succesfull.<br>
<a style="color:#66cf8d">-</a><a style="color:#f67400">1</a><a style="color:#66cf8d">:</a> Initialization failed.<br>
</ul>
<span style="color:#66cf8d">*</span><b>Note</b> : If a error ocurres call <a href=https://wiki.libsdl.org/SDL2/SDL_GetError>SDL_GetError<span style="color:#66cf8d">()</span></a> for more information.<br>
<h2>Parameters</h2>
<ul>
<b>flags</b> : if set to <a style="color:#f67400">0</a> it will use the <a href=LEXSDL_InitIMG.html#defauts>default flags</a>.
</ul>
<h2 id=defaults>Defaults</h2>
<ul>
<span style="color:#27ae60">LEXSDL_IMAGEINITFLAGS</span> = IMG_INIT_PNG | IMG_INIT_JPG
</ul>
</body>
<footer>
<br>
<hr>
<a href=FrontPage.html>FrontPage</a> <b>|</b> <a href=https://gitlab.com/Alexevier/lexsdl>GitLab</a> <b>|</b> <a href=https://crates.io/crates/lexsdl>Crates.io</a>
</footer>
</html>