153 lines
16 KiB
HTML
153 lines
16 KiB
HTML
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
|
|
<meta name="generator" content="Doxygen 1.9.1"/>
|
|
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
|
<title>SDL Utility: C:/Users/Robert/source/repos/SDLU/include/graphics/RenderWindow.hpp Source File</title>
|
|
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="jquery.js"></script>
|
|
<script type="text/javascript" src="dynsections.js"></script>
|
|
<link href="navtree.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="resize.js"></script>
|
|
<script type="text/javascript" src="navtreedata.js"></script>
|
|
<script type="text/javascript" src="navtree.js"></script>
|
|
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="search/searchdata.js"></script>
|
|
<script type="text/javascript" src="search/search.js"></script>
|
|
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
|
</head>
|
|
<body>
|
|
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
|
<div id="titlearea">
|
|
<table cellspacing="0" cellpadding="0">
|
|
<tbody>
|
|
<tr style="height: 56px;">
|
|
<td id="projectalign" style="padding-left: 0.5em;">
|
|
<div id="projectname">SDL Utility
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
<!-- end header part -->
|
|
<!-- Generated by Doxygen 1.9.1 -->
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
var searchBox = new SearchBox("searchBox", "search",false,'Search','.html');
|
|
/* @license-end */
|
|
</script>
|
|
<script type="text/javascript" src="menudata.js"></script>
|
|
<script type="text/javascript" src="menu.js"></script>
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
$(function() {
|
|
initMenu('',true,false,'search.php','Search');
|
|
$(document).ready(function() { init_search(); });
|
|
});
|
|
/* @license-end */</script>
|
|
<div id="main-nav"></div>
|
|
</div><!-- top -->
|
|
<div id="side-nav" class="ui-resizable side-nav-resizable">
|
|
<div id="nav-tree">
|
|
<div id="nav-tree-contents">
|
|
<div id="nav-sync" class="sync"></div>
|
|
</div>
|
|
</div>
|
|
<div id="splitbar" style="-moz-user-select:none;"
|
|
class="ui-resizable-handle">
|
|
</div>
|
|
</div>
|
|
<script type="text/javascript">
|
|
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
$(document).ready(function(){initNavTree('_render_window_8hpp_source.html',''); initResizable(); });
|
|
/* @license-end */
|
|
</script>
|
|
<div id="doc-content">
|
|
<!-- window showing the filter options -->
|
|
<div id="MSearchSelectWindow"
|
|
onmouseover="return searchBox.OnSearchSelectShow()"
|
|
onmouseout="return searchBox.OnSearchSelectHide()"
|
|
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
|
</div>
|
|
|
|
<!-- iframe showing the search results (closed by default) -->
|
|
<div id="MSearchResultsWindow">
|
|
<iframe src="javascript:void(0)" frameborder="0"
|
|
name="MSearchResults" id="MSearchResults">
|
|
</iframe>
|
|
</div>
|
|
|
|
<div class="header">
|
|
<div class="headertitle">
|
|
<div class="title">RenderWindow.hpp</div> </div>
|
|
</div><!--header-->
|
|
<div class="contents">
|
|
<a href="_render_window_8hpp.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno"> 1</span>  </div>
|
|
<div class="line"><a name="l00007"></a><span class="lineno"> 7</span> <span class="preprocessor">#pragma once</span></div>
|
|
<div class="line"><a name="l00008"></a><span class="lineno"> 8</span> <span class="preprocessor">#include <string></span></div>
|
|
<div class="line"><a name="l00009"></a><span class="lineno"> 9</span> <span class="preprocessor">#include <chrono></span></div>
|
|
<div class="line"><a name="l00010"></a><span class="lineno"> 10</span>  </div>
|
|
<div class="line"><a name="l00011"></a><span class="lineno"> 11</span> <span class="preprocessor">#include "<a class="code" href="_vector2_8hpp.html">structures/Vector2.hpp</a>"</span></div>
|
|
<div class="line"><a name="l00012"></a><span class="lineno"> 12</span> <span class="preprocessor">#include "<a class="code" href="_color_8hpp.html">structures/Color.hpp</a>"</span></div>
|
|
<div class="line"><a name="l00013"></a><span class="lineno"> 13</span> <span class="preprocessor">#include "<a class="code" href="_window_8hpp.html">structures/Window.hpp</a>"</span></div>
|
|
<div class="line"><a name="l00014"></a><span class="lineno"> 14</span> <span class="preprocessor">#include "<a class="code" href="_render_target_8hpp.html">graphics/RenderTarget.hpp</a>"</span></div>
|
|
<div class="line"><a name="l00015"></a><span class="lineno"> 15</span>  </div>
|
|
<div class="line"><a name="l00016"></a><span class="lineno"> 16</span> <a class="code" href="_util_8hpp.html#ad0494d8896dbc587136819e261afdc91">SDLU_BEGIN</a></div>
|
|
<div class="line"><a name="l00017"></a><span class="lineno"> 17</span> <span class="comment">// TODO: Probably break up into sdlu::Window and sdlu::Renderer</span></div>
|
|
<div class="line"><a name="l00018"></a><span class="lineno"> 18</span> <span class="comment">// to avoid passing around the Renderer when only the Window is</span></div>
|
|
<div class="line"><a name="l00019"></a><span class="lineno"> 19</span> <span class="comment">// needed. (See Mouse::GetPosition for example)</span></div>
|
|
<div class="line"><a name="l00020"></a><span class="lineno"> 20</span>  </div>
|
|
<div class="line"><a name="l00028"></a><span class="lineno"><a class="line" href="class_render_window.html"> 28</a></span> <span class="keyword">class </span><a class="code" href="class_render_window.html">RenderWindow</a> : <span class="keyword">public</span> <a class="code" href="class_window.html">Window</a>, <span class="keyword">public</span> <a class="code" href="class_render_target.html">RenderTarget</a></div>
|
|
<div class="line"><a name="l00029"></a><span class="lineno"> 29</span> {</div>
|
|
<div class="line"><a name="l00030"></a><span class="lineno"> 30</span> <span class="keyword">public</span>:</div>
|
|
<div class="line"><a name="l00034"></a><span class="lineno"><a class="line" href="class_render_window.html#ac644ce5a7654e4cdbc5a644bd9e02952"> 34</a></span>  <a class="code" href="class_render_window.html#ac644ce5a7654e4cdbc5a644bd9e02952">RenderWindow</a>();</div>
|
|
<div class="line"><a name="l00035"></a><span class="lineno"> 35</span>  </div>
|
|
<div class="line"><a name="l00042"></a><span class="lineno"><a class="line" href="class_render_window.html#a47e4b099bacd3f79ae03ca56770d38a4"> 42</a></span>  <a class="code" href="class_render_window.html#a47e4b099bacd3f79ae03ca56770d38a4">RenderWindow</a>(<a class="code" href="struct_vector2.html">Vector2u</a> dimension, <span class="keyword">const</span> std::string& title, </div>
|
|
<div class="line"><a name="l00043"></a><span class="lineno"> 43</span>  <a class="code" href="_util_8hpp.html#add440eff171ea5f55cb00c4a9ab8672d">Uint32</a> windowFlags = Window::Flags::Shown);</div>
|
|
<div class="line"><a name="l00044"></a><span class="lineno"> 44</span>  </div>
|
|
<div class="line"><a name="l00045"></a><span class="lineno"><a class="line" href="class_render_window.html#a8f395ca25a39a29631b4c5df6dfa9eef"> 45</a></span>  <a class="code" href="class_render_window.html#a8f395ca25a39a29631b4c5df6dfa9eef">RenderWindow</a>(<span class="keyword">const</span> <a class="code" href="class_render_window.html">RenderWindow</a>& other) = <span class="keyword">delete</span>;</div>
|
|
<div class="line"><a name="l00046"></a><span class="lineno"><a class="line" href="class_render_window.html#a42b60cb6ec327448c03b64610e25c38b"> 46</a></span>  <a class="code" href="class_render_window.html#a42b60cb6ec327448c03b64610e25c38b">RenderWindow</a>(<span class="keyword">const</span> <a class="code" href="class_render_window.html">RenderWindow</a>&& other) = <span class="keyword">delete</span>;</div>
|
|
<div class="line"><a name="l00047"></a><span class="lineno"> 47</span>  </div>
|
|
<div class="line"><a name="l00048"></a><span class="lineno"><a class="line" href="class_render_window.html#ab19eb1b76839ea7961275d19d805f9dc"> 48</a></span>  <span class="keyword">virtual</span> <a class="code" href="class_render_window.html#ab19eb1b76839ea7961275d19d805f9dc">~RenderWindow</a>();</div>
|
|
<div class="line"><a name="l00049"></a><span class="lineno"> 49</span>  </div>
|
|
<div class="line"><a name="l00050"></a><span class="lineno"> 50</span> <span class="keyword">protected</span>:</div>
|
|
<div class="line"><a name="l00054"></a><span class="lineno"><a class="line" href="class_render_window.html#a5b54652402d9eafb0677045cc54bb5ab"> 54</a></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="class_render_window.html#a5b54652402d9eafb0677045cc54bb5ab">OnCreate</a>();</div>
|
|
<div class="line"><a name="l00055"></a><span class="lineno"> 55</span>  </div>
|
|
<div class="line"><a name="l00062"></a><span class="lineno"><a class="line" href="class_render_window.html#ab73b98b3d1b7336243e3f782d00b9884"> 62</a></span>  <span class="keyword">virtual</span> <span class="keywordtype">bool</span> <a class="code" href="class_render_window.html#ab73b98b3d1b7336243e3f782d00b9884">OnResize</a>();</div>
|
|
<div class="line"><a name="l00063"></a><span class="lineno"> 63</span>  </div>
|
|
<div class="line"><a name="l00067"></a><span class="lineno"><a class="line" href="class_render_window.html#af15b3acc63e48d82a512e16455d47ef0"> 67</a></span>  <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code" href="class_render_window.html#af15b3acc63e48d82a512e16455d47ef0">OnClose</a>();</div>
|
|
<div class="line"><a name="l00068"></a><span class="lineno"> 68</span> };</div>
|
|
<div class="line"><a name="l00069"></a><span class="lineno"> 69</span> SDLU_END</div>
|
|
<div class="ttc" id="a_color_8hpp_html"><div class="ttname"><a href="_color_8hpp.html">Color.hpp</a></div><div class="ttdoc">Provides utility for creating and handling colors.</div></div>
|
|
<div class="ttc" id="a_render_target_8hpp_html"><div class="ttname"><a href="_render_target_8hpp.html">RenderTarget.hpp</a></div></div>
|
|
<div class="ttc" id="a_util_8hpp_html_ad0494d8896dbc587136819e261afdc91"><div class="ttname"><a href="_util_8hpp.html#ad0494d8896dbc587136819e261afdc91">SDLU_BEGIN</a></div><div class="ttdeci">#define SDLU_BEGIN</div><div class="ttdef"><b>Definition:</b> Util.hpp:32</div></div>
|
|
<div class="ttc" id="a_util_8hpp_html_add440eff171ea5f55cb00c4a9ab8672d"><div class="ttname"><a href="_util_8hpp.html#add440eff171ea5f55cb00c4a9ab8672d">Uint32</a></div><div class="ttdeci">uint32_t Uint32</div><div class="ttdef"><b>Definition:</b> Util.hpp:23</div></div>
|
|
<div class="ttc" id="a_vector2_8hpp_html"><div class="ttname"><a href="_vector2_8hpp.html">Vector2.hpp</a></div><div class="ttdoc">Provides a structure for simple vector calculations.</div></div>
|
|
<div class="ttc" id="a_window_8hpp_html"><div class="ttname"><a href="_window_8hpp.html">Window.hpp</a></div><div class="ttdoc">Contains window related objects.</div></div>
|
|
<div class="ttc" id="aclass_render_target_html"><div class="ttname"><a href="class_render_target.html">RenderTarget</a></div><div class="ttdoc">Acts as a wrapper for SDL_Renderer*. You can't (and shouldn't) instantiate this, but rather derive fr...</div><div class="ttdef"><b>Definition:</b> RenderTarget.hpp:22</div></div>
|
|
<div class="ttc" id="aclass_render_window_html"><div class="ttname"><a href="class_render_window.html">RenderWindow</a></div><div class="ttdoc">A class that handles window related functionality.</div><div class="ttdef"><b>Definition:</b> RenderWindow.hpp:29</div></div>
|
|
<div class="ttc" id="aclass_render_window_html_a42b60cb6ec327448c03b64610e25c38b"><div class="ttname"><a href="class_render_window.html#a42b60cb6ec327448c03b64610e25c38b">RenderWindow::RenderWindow</a></div><div class="ttdeci">RenderWindow(const RenderWindow &&other)=delete</div></div>
|
|
<div class="ttc" id="aclass_render_window_html_a47e4b099bacd3f79ae03ca56770d38a4"><div class="ttname"><a href="class_render_window.html#a47e4b099bacd3f79ae03ca56770d38a4">RenderWindow::RenderWindow</a></div><div class="ttdeci">RenderWindow(Vector2u dimension, const std::string &title, Uint32 windowFlags=Window::Flags::Shown)</div><div class="ttdoc">Creates a window and renderer with the given parameters.</div></div>
|
|
<div class="ttc" id="aclass_render_window_html_a5b54652402d9eafb0677045cc54bb5ab"><div class="ttname"><a href="class_render_window.html#a5b54652402d9eafb0677045cc54bb5ab">RenderWindow::OnCreate</a></div><div class="ttdeci">virtual void OnCreate()</div><div class="ttdoc">Function called after Window creation.</div></div>
|
|
<div class="ttc" id="aclass_render_window_html_a8f395ca25a39a29631b4c5df6dfa9eef"><div class="ttname"><a href="class_render_window.html#a8f395ca25a39a29631b4c5df6dfa9eef">RenderWindow::RenderWindow</a></div><div class="ttdeci">RenderWindow(const RenderWindow &other)=delete</div></div>
|
|
<div class="ttc" id="aclass_render_window_html_ab19eb1b76839ea7961275d19d805f9dc"><div class="ttname"><a href="class_render_window.html#ab19eb1b76839ea7961275d19d805f9dc">RenderWindow::~RenderWindow</a></div><div class="ttdeci">virtual ~RenderWindow()</div></div>
|
|
<div class="ttc" id="aclass_render_window_html_ab73b98b3d1b7336243e3f782d00b9884"><div class="ttname"><a href="class_render_window.html#ab73b98b3d1b7336243e3f782d00b9884">RenderWindow::OnResize</a></div><div class="ttdeci">virtual bool OnResize()</div><div class="ttdoc">Function called after resize event.</div></div>
|
|
<div class="ttc" id="aclass_render_window_html_ac644ce5a7654e4cdbc5a644bd9e02952"><div class="ttname"><a href="class_render_window.html#ac644ce5a7654e4cdbc5a644bd9e02952">RenderWindow::RenderWindow</a></div><div class="ttdeci">RenderWindow()</div><div class="ttdoc">Default Constructor. No window or renderer is created.</div></div>
|
|
<div class="ttc" id="aclass_render_window_html_af15b3acc63e48d82a512e16455d47ef0"><div class="ttname"><a href="class_render_window.html#af15b3acc63e48d82a512e16455d47ef0">RenderWindow::OnClose</a></div><div class="ttdeci">virtual void OnClose()</div><div class="ttdoc">Function called after closing the window.</div></div>
|
|
<div class="ttc" id="aclass_window_html"><div class="ttname"><a href="class_window.html">Window</a></div><div class="ttdoc">Stores information about a window. You probably want RenderWindow.</div><div class="ttdef"><b>Definition:</b> Window.hpp:26</div></div>
|
|
<div class="ttc" id="astruct_vector2_html"><div class="ttname"><a href="struct_vector2.html">Vector2</a></div><div class="ttdoc">A struct to handle basic 2D vector operations.</div><div class="ttdef"><b>Definition:</b> Vector2.hpp:22</div></div>
|
|
</div><!-- fragment --></div><!-- contents -->
|
|
</div><!-- doc-content -->
|
|
<!-- start footer part -->
|
|
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
|
|
<ul>
|
|
<li class="navelem"><a class="el" href="dir_d44c64559bbebec7f509842c48db8b23.html">include</a></li><li class="navelem"><a class="el" href="dir_c17ed8a99c2aafc6034c524ffcf900dc.html">graphics</a></li><li class="navelem"><a class="el" href="_render_window_8hpp.html">RenderWindow.hpp</a></li>
|
|
<li class="footer">Generated by <a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.1 </li>
|
|
</ul>
|
|
</div>
|
|
</body>
|
|
</html>
|