-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path_nine_patch_8h_source.html
213 lines (213 loc) · 35.3 KB
/
_nine_patch_8h_source.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
<!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=11"/>
<meta name="generator" content="Doxygen 1.9.3"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Gamedev Framework (gf): NinePatch.h 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>
<script type="text/x-mathjax-config">
MathJax.Hub.Config({
extensions: ["tex2jax.js"],
jax: ["input/TeX","output/HTML-CSS"],
});
</script>
<script type="text/javascript" async="async" src="https://cdn.jsdelivr.net/npm/mathjax@2/MathJax.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="custom.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 id="projectrow">
<td id="projectlogo"><img alt="Logo" src="gf_logo.png"/></td>
<td id="projectalign">
<div id="projectname">Gamedev Framework (gf)<span id="projectnumber"> 0.22.0</span>
</div>
<div id="projectbrief">A C++17 framework for 2D games</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.9.3 -->
<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:d3d9a9a6595521f9666a5e94cc830dab83b65699&dn=expat.txt MIT */
$(function() {
initMenu('',false,false,'search.php','Search');
});
/* @license-end */
</script>
<div id="main-nav"></div>
<div id="nav-path" class="navpath">
<ul>
<li class="navelem"><a class="el" href="dir_d44c64559bbebec7f509842c48db8b23.html">include</a></li><li class="navelem"><a class="el" href="dir_6d069d519ae9d12fa11dd8e685586b60.html">gf</a></li> </ul>
</div>
</div><!-- top -->
<div class="header">
<div class="headertitle"><div class="title">NinePatch.h</div></div>
</div><!--header-->
<div class="contents">
<div class="fragment"><div class="line"><a id="l00001" name="l00001"></a><span class="lineno"> 1</span><span class="comment">/*</span></div>
<div class="line"><a id="l00002" name="l00002"></a><span class="lineno"> 2</span><span class="comment"> * Gamedev Framework (gf)</span></div>
<div class="line"><a id="l00003" name="l00003"></a><span class="lineno"> 3</span><span class="comment"> * Copyright (C) 2016-2022 Julien Bernard</span></div>
<div class="line"><a id="l00004" name="l00004"></a><span class="lineno"> 4</span><span class="comment"> *</span></div>
<div class="line"><a id="l00005" name="l00005"></a><span class="lineno"> 5</span><span class="comment"> * This software is provided 'as-is', without any express or implied</span></div>
<div class="line"><a id="l00006" name="l00006"></a><span class="lineno"> 6</span><span class="comment"> * warranty. In no event will the authors be held liable for any damages</span></div>
<div class="line"><a id="l00007" name="l00007"></a><span class="lineno"> 7</span><span class="comment"> * arising from the use of this software.</span></div>
<div class="line"><a id="l00008" name="l00008"></a><span class="lineno"> 8</span><span class="comment"> *</span></div>
<div class="line"><a id="l00009" name="l00009"></a><span class="lineno"> 9</span><span class="comment"> * Permission is granted to anyone to use this software for any purpose,</span></div>
<div class="line"><a id="l00010" name="l00010"></a><span class="lineno"> 10</span><span class="comment"> * including commercial applications, and to alter it and redistribute it</span></div>
<div class="line"><a id="l00011" name="l00011"></a><span class="lineno"> 11</span><span class="comment"> * freely, subject to the following restrictions:</span></div>
<div class="line"><a id="l00012" name="l00012"></a><span class="lineno"> 12</span><span class="comment"> *</span></div>
<div class="line"><a id="l00013" name="l00013"></a><span class="lineno"> 13</span><span class="comment"> * 1. The origin of this software must not be misrepresented; you must not</span></div>
<div class="line"><a id="l00014" name="l00014"></a><span class="lineno"> 14</span><span class="comment"> * claim that you wrote the original software. If you use this software</span></div>
<div class="line"><a id="l00015" name="l00015"></a><span class="lineno"> 15</span><span class="comment"> * in a product, an acknowledgment in the product documentation would be</span></div>
<div class="line"><a id="l00016" name="l00016"></a><span class="lineno"> 16</span><span class="comment"> * appreciated but is not required.</span></div>
<div class="line"><a id="l00017" name="l00017"></a><span class="lineno"> 17</span><span class="comment"> * 2. Altered source versions must be plainly marked as such, and must not be</span></div>
<div class="line"><a id="l00018" name="l00018"></a><span class="lineno"> 18</span><span class="comment"> * misrepresented as being the original software.</span></div>
<div class="line"><a id="l00019" name="l00019"></a><span class="lineno"> 19</span><span class="comment"> * 3. This notice may not be removed or altered from any source distribution.</span></div>
<div class="line"><a id="l00020" name="l00020"></a><span class="lineno"> 20</span><span class="comment"> */</span></div>
<div class="line"><a id="l00021" name="l00021"></a><span class="lineno"> 21</span><span class="preprocessor">#ifndef GF_NINE_PATCH_H</span></div>
<div class="line"><a id="l00022" name="l00022"></a><span class="lineno"> 22</span><span class="preprocessor">#define GF_NINE_PATCH_H</span></div>
<div class="line"><a id="l00023" name="l00023"></a><span class="lineno"> 23</span> </div>
<div class="line"><a id="l00024" name="l00024"></a><span class="lineno"> 24</span><span class="preprocessor">#include "GraphicsApi.h"</span></div>
<div class="line"><a id="l00025" name="l00025"></a><span class="lineno"> 25</span><span class="preprocessor">#include "Transformable.h"</span></div>
<div class="line"><a id="l00026" name="l00026"></a><span class="lineno"> 26</span><span class="preprocessor">#include "Vertex.h"</span></div>
<div class="line"><a id="l00027" name="l00027"></a><span class="lineno"> 27</span><span class="preprocessor">#include "VertexBuffer.h"</span></div>
<div class="line"><a id="l00028" name="l00028"></a><span class="lineno"> 28</span> </div>
<div class="line"><a id="l00029" name="l00029"></a><span class="lineno"> 29</span><span class="keyword">namespace </span><a class="code hl_namespace" href="namespacegf.html">gf</a> {</div>
<div class="line"><a id="l00030" name="l00030"></a><span class="lineno"> 30</span><span class="preprocessor">#ifndef DOXYGEN_SHOULD_SKIP_THIS</span></div>
<div class="line"><a id="l00031" name="l00031"></a><span class="lineno"> 31</span><span class="keyword">inline</span> <span class="keyword">namespace </span>v1 {</div>
<div class="line"><a id="l00032" name="l00032"></a><span class="lineno"> 32</span><span class="preprocessor">#endif</span></div>
<div class="line"><a id="l00033" name="l00033"></a><span class="lineno"> 33</span> </div>
<div class="line"><a id="l00034" name="l00034"></a><span class="lineno"> 34</span> <span class="keyword">class </span><a class="code hl_enumvalue" href="group__graphics__gpu.html#ggaf345882cbbc4e834ec38715ef1cb0c2baa3e8ae43188ae76d38f414b2bdb0077b">Texture</a>;</div>
<div class="line"><a id="l00035" name="l00035"></a><span class="lineno"> 35</span> </div>
<div class="line"><a id="l00046" name="l00046"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html"> 46</a></span> <span class="keyword">class </span>GF_GRAPHICS_API <a class="code hl_class" href="classgf_1_1_nine_patch.html">NinePatch</a> : <span class="keyword">public</span> <a class="code hl_class" href="classgf_1_1_transformable.html">Transformable</a> {</div>
<div class="line"><a id="l00047" name="l00047"></a><span class="lineno"> 47</span> <span class="keyword">public</span>:</div>
<div class="line"><a id="l00053" name="l00053"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html#ae9ddc8a13a404ede9d34238848b006ac"> 53</a></span> <a class="code hl_function" href="classgf_1_1_nine_patch.html#ae9ddc8a13a404ede9d34238848b006ac">NinePatch</a>();</div>
<div class="line"><a id="l00054" name="l00054"></a><span class="lineno"> 54</span> </div>
<div class="line"><a id="l00062" name="l00062"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html#a4cb7631f5bfda2104e64f32e8631fac8"> 62</a></span> <a class="code hl_function" href="classgf_1_1_nine_patch.html#a4cb7631f5bfda2104e64f32e8631fac8">NinePatch</a>(<span class="keyword">const</span> <a class="code hl_class" href="classgf_1_1_texture.html">Texture</a>& texture);</div>
<div class="line"><a id="l00063" name="l00063"></a><span class="lineno"> 63</span> </div>
<div class="line"><a id="l00072" name="l00072"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html#a730ccfae2a8b86f3583d0b9725a9ed16"> 72</a></span> <a class="code hl_function" href="classgf_1_1_nine_patch.html#a730ccfae2a8b86f3583d0b9725a9ed16">NinePatch</a>(<span class="keyword">const</span> <a class="code hl_class" href="classgf_1_1_texture.html">Texture</a>& texture, <span class="keyword">const</span> <a class="code hl_class" href="structgf_1_1_rect.html">RectF</a>& textureRect);</div>
<div class="line"><a id="l00073" name="l00073"></a><span class="lineno"> 73</span> </div>
<div class="line"><a id="l00092" name="l00092"></a><span class="lineno"> 92</span> [[deprecated(<span class="stringliteral">"You should use setTexture(const Texture&, const RectF&) instead"</span>)]]</div>
<div class="line"><a id="l00093" name="l00093"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html#ab42f726833b93a683b14538ec6ed900c"> 93</a></span> <span class="keywordtype">void</span> <a class="code hl_function" href="classgf_1_1_nine_patch.html#ab42f726833b93a683b14538ec6ed900c">setTexture</a>(<span class="keyword">const</span> <a class="code hl_class" href="classgf_1_1_texture.html">Texture</a>& texture, <span class="keywordtype">bool</span> resetRect);</div>
<div class="line"><a id="l00094" name="l00094"></a><span class="lineno"> 94</span> </div>
<div class="line"><a id="l00111" name="l00111"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html#acd7e238add9a53d57d1595072c460cf2"> 111</a></span> <span class="keywordtype">void</span> <a class="code hl_function" href="classgf_1_1_nine_patch.html#acd7e238add9a53d57d1595072c460cf2">setTexture</a>(<span class="keyword">const</span> <a class="code hl_class" href="classgf_1_1_texture.html">Texture</a>& texture, <span class="keyword">const</span> <a class="code hl_class" href="structgf_1_1_rect.html">RectF</a>& textureRect = <a class="code hl_function" href="structgf_1_1_rect.html#a31b49fa6bcdbc3090e4011e5195db8b0">RectF::fromSize</a>({ 1.0f, 1.0f }));</div>
<div class="line"><a id="l00112" name="l00112"></a><span class="lineno"> 112</span> </div>
<div class="line"><a id="l00123" name="l00123"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html#ad0c0f38f55fc413b7509c6373be6837f"> 123</a></span> <span class="keyword">const</span> <a class="code hl_class" href="classgf_1_1_texture.html">Texture</a>& <a class="code hl_function" href="classgf_1_1_nine_patch.html#ad0c0f38f55fc413b7509c6373be6837f">getTexture</a>()<span class="keyword"> const </span>{</div>
<div class="line"><a id="l00124" name="l00124"></a><span class="lineno"> 124</span> <span class="keywordflow">return</span> *m_texture;</div>
<div class="line"><a id="l00125" name="l00125"></a><span class="lineno"> 125</span> }</div>
<div class="line"><a id="l00126" name="l00126"></a><span class="lineno"> 126</span> </div>
<div class="line"><a id="l00134" name="l00134"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html#ad25d21b9c6d60e1054ad0401297a2ecd"> 134</a></span> <span class="keywordtype">bool</span> <a class="code hl_function" href="classgf_1_1_nine_patch.html#ad25d21b9c6d60e1054ad0401297a2ecd">hasTexture</a>()<span class="keyword"> const </span>{</div>
<div class="line"><a id="l00135" name="l00135"></a><span class="lineno"> 135</span> <span class="keywordflow">return</span> m_texture != <span class="keyword">nullptr</span>;</div>
<div class="line"><a id="l00136" name="l00136"></a><span class="lineno"> 136</span> }</div>
<div class="line"><a id="l00137" name="l00137"></a><span class="lineno"> 137</span> </div>
<div class="line"><a id="l00145" name="l00145"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html#a1c46d77f270ee4e35d6a2fa6ff75b04c"> 145</a></span> <span class="keywordtype">void</span> <a class="code hl_function" href="classgf_1_1_nine_patch.html#a1c46d77f270ee4e35d6a2fa6ff75b04c">unsetTexture</a>();</div>
<div class="line"><a id="l00146" name="l00146"></a><span class="lineno"> 146</span> </div>
<div class="line"><a id="l00162" name="l00162"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html#ac070add1a1f13238cbcb19f311be722c"> 162</a></span> <span class="keywordtype">void</span> <a class="code hl_function" href="classgf_1_1_nine_patch.html#ac070add1a1f13238cbcb19f311be722c">setTextureRect</a>(<span class="keyword">const</span> <a class="code hl_class" href="structgf_1_1_rect.html">RectF</a>& rect);</div>
<div class="line"><a id="l00163" name="l00163"></a><span class="lineno"> 163</span> </div>
<div class="line"><a id="l00171" name="l00171"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html#ae6b7ba78e8ba1fb9cad99a194a4f8a1a"> 171</a></span> <span class="keyword">const</span> <a class="code hl_class" href="structgf_1_1_rect.html">RectF</a>& <a class="code hl_function" href="classgf_1_1_nine_patch.html#ae6b7ba78e8ba1fb9cad99a194a4f8a1a">getTextureRect</a>()<span class="keyword"> const </span>{</div>
<div class="line"><a id="l00172" name="l00172"></a><span class="lineno"> 172</span> <span class="keywordflow">return</span> m_textureRect;</div>
<div class="line"><a id="l00173" name="l00173"></a><span class="lineno"> 173</span> }</div>
<div class="line"><a id="l00174" name="l00174"></a><span class="lineno"> 174</span> </div>
<div class="line"><a id="l00188" name="l00188"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html#a4911d58102df53e8bfdb25655fbadc2b"> 188</a></span> <span class="keywordtype">void</span> <a class="code hl_function" href="classgf_1_1_nine_patch.html#a4911d58102df53e8bfdb25655fbadc2b">setColor</a>(<span class="keyword">const</span> <a class="code hl_struct" href="structgf_1_1_vector_3_01_t_00_014_01_4.html">Color4f</a>& color);</div>
<div class="line"><a id="l00189" name="l00189"></a><span class="lineno"> 189</span> </div>
<div class="line"><a id="l00197" name="l00197"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html#abbb008ad8be3d204c8c499dda5871fe2"> 197</a></span> <span class="keyword">const</span> <a class="code hl_struct" href="structgf_1_1_vector_3_01_t_00_014_01_4.html">Color4f</a>& <a class="code hl_function" href="classgf_1_1_nine_patch.html#abbb008ad8be3d204c8c499dda5871fe2">getColor</a>() <span class="keyword">const</span>;</div>
<div class="line"><a id="l00198" name="l00198"></a><span class="lineno"> 198</span> </div>
<div class="line"><a id="l00209" name="l00209"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html#aded0bd5c08ad2aec856d78678c6d2ab7"> 209</a></span> <span class="keywordtype">void</span> <a class="code hl_function" href="classgf_1_1_nine_patch.html#aded0bd5c08ad2aec856d78678c6d2ab7">setLimits</a>(<span class="keywordtype">float</span> top, <span class="keywordtype">float</span> bottom, <span class="keywordtype">float</span> left, <span class="keywordtype">float</span> right);</div>
<div class="line"><a id="l00210" name="l00210"></a><span class="lineno"> 210</span> </div>
<div class="line"><a id="l00219" name="l00219"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html#a4f5e1e7fce67f4ba89e17017793b8152"> 219</a></span> <span class="keywordtype">void</span> <a class="code hl_function" href="classgf_1_1_nine_patch.html#a4f5e1e7fce67f4ba89e17017793b8152">setVerticalLimits</a>(<span class="keywordtype">float</span> top, <span class="keywordtype">float</span> bottom);</div>
<div class="line"><a id="l00220" name="l00220"></a><span class="lineno"> 220</span> </div>
<div class="line"><a id="l00229" name="l00229"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html#adc0f276c177ae2aa3850b20ed0c16f9e"> 229</a></span> <span class="keywordtype">void</span> <a class="code hl_function" href="classgf_1_1_nine_patch.html#adc0f276c177ae2aa3850b20ed0c16f9e">setHorizontalLimits</a>(<span class="keywordtype">float</span> left, <span class="keywordtype">float</span> right);</div>
<div class="line"><a id="l00230" name="l00230"></a><span class="lineno"> 230</span> </div>
<div class="line"><a id="l00236" name="l00236"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html#a5ffd18086f7e0a5b3dfd7b62abd8dbcd"> 236</a></span> <span class="keywordtype">void</span> <a class="code hl_function" href="classgf_1_1_nine_patch.html#a5ffd18086f7e0a5b3dfd7b62abd8dbcd">setSize</a>(<a class="code hl_class" href="structgf_1_1_vector.html">Vector2f</a> size);</div>
<div class="line"><a id="l00237" name="l00237"></a><span class="lineno"> 237</span> </div>
<div class="line"><a id="l00243" name="l00243"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html#ac465fd79edcb8c43c706b3c1a8bcbbfc"> 243</a></span> <a class="code hl_class" href="structgf_1_1_vector.html">Vector2f</a> <a class="code hl_function" href="classgf_1_1_nine_patch.html#ac465fd79edcb8c43c706b3c1a8bcbbfc">getSize</a>()<span class="keyword"> const </span>{</div>
<div class="line"><a id="l00244" name="l00244"></a><span class="lineno"> 244</span> <span class="keywordflow">return</span> m_size;</div>
<div class="line"><a id="l00245" name="l00245"></a><span class="lineno"> 245</span> }</div>
<div class="line"><a id="l00246" name="l00246"></a><span class="lineno"> 246</span> </div>
<div class="line"><a id="l00258" name="l00258"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html#a34bdc57d46326cc3f05ec770424793b0"> 258</a></span> <a class="code hl_class" href="structgf_1_1_rect.html">RectF</a> <a class="code hl_function" href="classgf_1_1_nine_patch.html#a34bdc57d46326cc3f05ec770424793b0">getLocalBounds</a>() <span class="keyword">const</span>;</div>
<div class="line"><a id="l00259" name="l00259"></a><span class="lineno"> 259</span> </div>
<div class="line"><a id="l00270" name="l00270"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html#a8e624585bd76d7e6d6b9178a596bf820"> 270</a></span> <span class="keywordtype">void</span> <a class="code hl_function" href="classgf_1_1_nine_patch.html#a8e624585bd76d7e6d6b9178a596bf820">setAnchor</a>(<a class="code hl_enumeration" href="group__graphics__drawables.html#gadeb9cdf9d7e8eec2eb8cc638c54b5066">Anchor</a> anchor);</div>
<div class="line"><a id="l00271" name="l00271"></a><span class="lineno"> 271</span> </div>
<div class="line"><a id="l00280" name="l00280"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html#a2d5b3688ff0de19f885e4b41bceeb018"> 280</a></span> <a class="code hl_class" href="classgf_1_1_vertex_buffer.html">VertexBuffer</a> <a class="code hl_function" href="classgf_1_1_nine_patch.html#a2d5b3688ff0de19f885e4b41bceeb018">commitGeometry</a>() <span class="keyword">const</span>;</div>
<div class="line"><a id="l00281" name="l00281"></a><span class="lineno"> 281</span> </div>
<div class="line"><a id="l00282" name="l00282"></a><span class="lineno"><a class="line" href="classgf_1_1_nine_patch.html#a45b1317b33b01b7801d0cd55585bb6da"> 282</a></span> <span class="keyword">virtual</span> <span class="keywordtype">void</span> <a class="code hl_function" href="classgf_1_1_nine_patch.html#a45b1317b33b01b7801d0cd55585bb6da">draw</a>(<a class="code hl_class" href="classgf_1_1_render_target.html">RenderTarget</a>& target, <span class="keyword">const</span> <a class="code hl_struct" href="structgf_1_1_render_states.html">RenderStates</a>& states) <span class="keyword">override</span>;</div>
<div class="line"><a id="l00283" name="l00283"></a><span class="lineno"> 283</span> </div>
<div class="line"><a id="l00284" name="l00284"></a><span class="lineno"> 284</span> <span class="keyword">private</span>:</div>
<div class="line"><a id="l00285" name="l00285"></a><span class="lineno"> 285</span> <span class="keywordtype">void</span> updatePositions();</div>
<div class="line"><a id="l00286" name="l00286"></a><span class="lineno"> 286</span> <span class="keywordtype">void</span> updateTexCoords();</div>
<div class="line"><a id="l00287" name="l00287"></a><span class="lineno"> 287</span> </div>
<div class="line"><a id="l00288" name="l00288"></a><span class="lineno"> 288</span> <span class="keyword">private</span>:</div>
<div class="line"><a id="l00289" name="l00289"></a><span class="lineno"> 289</span> <span class="keyword">const</span> <a class="code hl_class" href="classgf_1_1_texture.html">Texture</a> *m_texture;</div>
<div class="line"><a id="l00290" name="l00290"></a><span class="lineno"> 290</span> <a class="code hl_class" href="structgf_1_1_rect.html">RectF</a> m_textureRect;</div>
<div class="line"><a id="l00291" name="l00291"></a><span class="lineno"> 291</span> </div>
<div class="line"><a id="l00292" name="l00292"></a><span class="lineno"> 292</span> <span class="keywordtype">float</span> m_top;</div>
<div class="line"><a id="l00293" name="l00293"></a><span class="lineno"> 293</span> <span class="keywordtype">float</span> m_bottom;</div>
<div class="line"><a id="l00294" name="l00294"></a><span class="lineno"> 294</span> <span class="keywordtype">float</span> m_left;</div>
<div class="line"><a id="l00295" name="l00295"></a><span class="lineno"> 295</span> <span class="keywordtype">float</span> m_right;</div>
<div class="line"><a id="l00296" name="l00296"></a><span class="lineno"> 296</span> </div>
<div class="line"><a id="l00297" name="l00297"></a><span class="lineno"> 297</span> <a class="code hl_class" href="structgf_1_1_vector.html">Vector2f</a> m_size;</div>
<div class="line"><a id="l00298" name="l00298"></a><span class="lineno"> 298</span> </div>
<div class="line"><a id="l00299" name="l00299"></a><span class="lineno"> 299</span> <a class="code hl_struct" href="structgf_1_1_vertex.html">Vertex</a> m_vertices[16];</div>
<div class="line"><a id="l00300" name="l00300"></a><span class="lineno"> 300</span> };</div>
<div class="line"><a id="l00301" name="l00301"></a><span class="lineno"> 301</span> </div>
<div class="line"><a id="l00302" name="l00302"></a><span class="lineno"> 302</span> </div>
<div class="line"><a id="l00303" name="l00303"></a><span class="lineno"> 303</span><span class="preprocessor">#ifndef DOXYGEN_SHOULD_SKIP_THIS</span></div>
<div class="line"><a id="l00304" name="l00304"></a><span class="lineno"> 304</span>}</div>
<div class="line"><a id="l00305" name="l00305"></a><span class="lineno"> 305</span><span class="preprocessor">#endif</span></div>
<div class="line"><a id="l00306" name="l00306"></a><span class="lineno"> 306</span>}</div>
<div class="line"><a id="l00307" name="l00307"></a><span class="lineno"> 307</span> </div>
<div class="line"><a id="l00308" name="l00308"></a><span class="lineno"> 308</span><span class="preprocessor">#endif </span><span class="comment">// GF_NINE_PATCH_H</span></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html"><div class="ttname"><a href="classgf_1_1_nine_patch.html">gf::NinePatch</a></div><div class="ttdoc">A nine-patch.</div><div class="ttdef"><b>Definition:</b> NinePatch.h:46</div></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html_a1c46d77f270ee4e35d6a2fa6ff75b04c"><div class="ttname"><a href="classgf_1_1_nine_patch.html#a1c46d77f270ee4e35d6a2fa6ff75b04c">gf::NinePatch::unsetTexture</a></div><div class="ttdeci">void unsetTexture()</div><div class="ttdoc">Unset the source texture of the nine-patch.</div></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html_a2d5b3688ff0de19f885e4b41bceeb018"><div class="ttname"><a href="classgf_1_1_nine_patch.html#a2d5b3688ff0de19f885e4b41bceeb018">gf::NinePatch::commitGeometry</a></div><div class="ttdeci">VertexBuffer commitGeometry() const</div><div class="ttdoc">Create a buffer with the current geometry.</div></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html_a34bdc57d46326cc3f05ec770424793b0"><div class="ttname"><a href="classgf_1_1_nine_patch.html#a34bdc57d46326cc3f05ec770424793b0">gf::NinePatch::getLocalBounds</a></div><div class="ttdeci">RectF getLocalBounds() const</div><div class="ttdoc">Get the local bounding rectangle of the entity.</div></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html_a45b1317b33b01b7801d0cd55585bb6da"><div class="ttname"><a href="classgf_1_1_nine_patch.html#a45b1317b33b01b7801d0cd55585bb6da">gf::NinePatch::draw</a></div><div class="ttdeci">virtual void draw(RenderTarget &target, const RenderStates &states) override</div><div class="ttdoc">Draw the object to a render target.</div></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html_a4911d58102df53e8bfdb25655fbadc2b"><div class="ttname"><a href="classgf_1_1_nine_patch.html#a4911d58102df53e8bfdb25655fbadc2b">gf::NinePatch::setColor</a></div><div class="ttdeci">void setColor(const Color4f &color)</div><div class="ttdoc">Set the global color of the nine-patch.</div></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html_a4cb7631f5bfda2104e64f32e8631fac8"><div class="ttname"><a href="classgf_1_1_nine_patch.html#a4cb7631f5bfda2104e64f32e8631fac8">gf::NinePatch::NinePatch</a></div><div class="ttdeci">NinePatch(const Texture &texture)</div><div class="ttdoc">Construct the nine-patch from a source texture.</div></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html_a4f5e1e7fce67f4ba89e17017793b8152"><div class="ttname"><a href="classgf_1_1_nine_patch.html#a4f5e1e7fce67f4ba89e17017793b8152">gf::NinePatch::setVerticalLimits</a></div><div class="ttdeci">void setVerticalLimits(float top, float bottom)</div><div class="ttdoc">Set the vertical limits of the stretchable area.</div></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html_a5ffd18086f7e0a5b3dfd7b62abd8dbcd"><div class="ttname"><a href="classgf_1_1_nine_patch.html#a5ffd18086f7e0a5b3dfd7b62abd8dbcd">gf::NinePatch::setSize</a></div><div class="ttdeci">void setSize(Vector2f size)</div><div class="ttdoc">Set the size of the stretched area.</div></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html_a730ccfae2a8b86f3583d0b9725a9ed16"><div class="ttname"><a href="classgf_1_1_nine_patch.html#a730ccfae2a8b86f3583d0b9725a9ed16">gf::NinePatch::NinePatch</a></div><div class="ttdeci">NinePatch(const Texture &texture, const RectF &textureRect)</div><div class="ttdoc">Construct the nine-patch from a sub-rectangle of a source texture.</div></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html_a8e624585bd76d7e6d6b9178a596bf820"><div class="ttname"><a href="classgf_1_1_nine_patch.html#a8e624585bd76d7e6d6b9178a596bf820">gf::NinePatch::setAnchor</a></div><div class="ttdeci">void setAnchor(Anchor anchor)</div><div class="ttdoc">Set the anchor origin of the entity.</div></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html_ab42f726833b93a683b14538ec6ed900c"><div class="ttname"><a href="classgf_1_1_nine_patch.html#ab42f726833b93a683b14538ec6ed900c">gf::NinePatch::setTexture</a></div><div class="ttdeci">void setTexture(const Texture &texture, bool resetRect)</div><div class="ttdoc">Change the source texture of the nine-patch.</div></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html_abbb008ad8be3d204c8c499dda5871fe2"><div class="ttname"><a href="classgf_1_1_nine_patch.html#abbb008ad8be3d204c8c499dda5871fe2">gf::NinePatch::getColor</a></div><div class="ttdeci">const Color4f & getColor() const</div><div class="ttdoc">Get the global color of the nine-patch.</div></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html_ac070add1a1f13238cbcb19f311be722c"><div class="ttname"><a href="classgf_1_1_nine_patch.html#ac070add1a1f13238cbcb19f311be722c">gf::NinePatch::setTextureRect</a></div><div class="ttdeci">void setTextureRect(const RectF &rect)</div><div class="ttdoc">Set the sub-rectangle of the texture that the nine-patch will display.</div></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html_ac465fd79edcb8c43c706b3c1a8bcbbfc"><div class="ttname"><a href="classgf_1_1_nine_patch.html#ac465fd79edcb8c43c706b3c1a8bcbbfc">gf::NinePatch::getSize</a></div><div class="ttdeci">Vector2f getSize() const</div><div class="ttdoc">Get the size of the stretched area.</div><div class="ttdef"><b>Definition:</b> NinePatch.h:243</div></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html_acd7e238add9a53d57d1595072c460cf2"><div class="ttname"><a href="classgf_1_1_nine_patch.html#acd7e238add9a53d57d1595072c460cf2">gf::NinePatch::setTexture</a></div><div class="ttdeci">void setTexture(const Texture &texture, const RectF &textureRect=RectF::fromSize({ 1.0f, 1.0f }))</div><div class="ttdoc">Change the source texture of the nine-patch.</div></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html_ad0c0f38f55fc413b7509c6373be6837f"><div class="ttname"><a href="classgf_1_1_nine_patch.html#ad0c0f38f55fc413b7509c6373be6837f">gf::NinePatch::getTexture</a></div><div class="ttdeci">const Texture & getTexture() const</div><div class="ttdoc">Get the source texture of the nine-patch.</div><div class="ttdef"><b>Definition:</b> NinePatch.h:123</div></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html_ad25d21b9c6d60e1054ad0401297a2ecd"><div class="ttname"><a href="classgf_1_1_nine_patch.html#ad25d21b9c6d60e1054ad0401297a2ecd">gf::NinePatch::hasTexture</a></div><div class="ttdeci">bool hasTexture() const</div><div class="ttdoc">Check if a texture is set.</div><div class="ttdef"><b>Definition:</b> NinePatch.h:134</div></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html_adc0f276c177ae2aa3850b20ed0c16f9e"><div class="ttname"><a href="classgf_1_1_nine_patch.html#adc0f276c177ae2aa3850b20ed0c16f9e">gf::NinePatch::setHorizontalLimits</a></div><div class="ttdeci">void setHorizontalLimits(float left, float right)</div><div class="ttdoc">Set the horizontal limits of the stretchable area.</div></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html_aded0bd5c08ad2aec856d78678c6d2ab7"><div class="ttname"><a href="classgf_1_1_nine_patch.html#aded0bd5c08ad2aec856d78678c6d2ab7">gf::NinePatch::setLimits</a></div><div class="ttdeci">void setLimits(float top, float bottom, float left, float right)</div><div class="ttdoc">Set the limits of the stretchable area.</div></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html_ae6b7ba78e8ba1fb9cad99a194a4f8a1a"><div class="ttname"><a href="classgf_1_1_nine_patch.html#ae6b7ba78e8ba1fb9cad99a194a4f8a1a">gf::NinePatch::getTextureRect</a></div><div class="ttdeci">const RectF & getTextureRect() const</div><div class="ttdoc">Get the sub-rectangle of the texture displayed by the nine-patch.</div><div class="ttdef"><b>Definition:</b> NinePatch.h:171</div></div>
<div class="ttc" id="aclassgf_1_1_nine_patch_html_ae9ddc8a13a404ede9d34238848b006ac"><div class="ttname"><a href="classgf_1_1_nine_patch.html#ae9ddc8a13a404ede9d34238848b006ac">gf::NinePatch::NinePatch</a></div><div class="ttdeci">NinePatch()</div><div class="ttdoc">Default constructor.</div></div>
<div class="ttc" id="aclassgf_1_1_render_target_html"><div class="ttname"><a href="classgf_1_1_render_target.html">gf::RenderTarget</a></div><div class="ttdoc">Base class for all render targets (window, texture, ...)</div><div class="ttdef"><b>Definition:</b> RenderTarget.h:102</div></div>
<div class="ttc" id="aclassgf_1_1_texture_html"><div class="ttname"><a href="classgf_1_1_texture.html">gf::Texture</a></div><div class="ttdoc">A texture for colored images.</div><div class="ttdef"><b>Definition:</b> Texture.h:313</div></div>
<div class="ttc" id="aclassgf_1_1_transformable_html"><div class="ttname"><a href="classgf_1_1_transformable.html">gf::Transformable</a></div><div class="ttdoc">Decomposed transform defined by a position, a rotation and a scale.</div><div class="ttdef"><b>Definition:</b> Transformable.h:95</div></div>
<div class="ttc" id="aclassgf_1_1_vertex_buffer_html"><div class="ttname"><a href="classgf_1_1_vertex_buffer.html">gf::VertexBuffer</a></div><div class="ttdoc">Data in the graphics memory.</div><div class="ttdef"><b>Definition:</b> VertexBuffer.h:81</div></div>
<div class="ttc" id="agroup__graphics__drawables_html_gadeb9cdf9d7e8eec2eb8cc638c54b5066"><div class="ttname"><a href="group__graphics__drawables.html#gadeb9cdf9d7e8eec2eb8cc638c54b5066">gf::Anchor</a></div><div class="ttdeci">Anchor</div><div class="ttdoc">An anchor of a box.</div><div class="ttdef"><b>Definition:</b> Anchor.h:38</div></div>
<div class="ttc" id="agroup__graphics__gpu_html_ggaf345882cbbc4e834ec38715ef1cb0c2baa3e8ae43188ae76d38f414b2bdb0077b"><div class="ttname"><a href="group__graphics__gpu.html#ggaf345882cbbc4e834ec38715ef1cb0c2baa3e8ae43188ae76d38f414b2bdb0077b">gf::GraphicsTag::Texture</a></div><div class="ttdeci">@ Texture</div><div class="ttdoc">A GPU texture.</div></div>
<div class="ttc" id="anamespacegf_html"><div class="ttname"><a href="namespacegf.html">gf</a></div><div class="ttdoc">The namespace for gf classes.</div></div>
<div class="ttc" id="astructgf_1_1_rect_html"><div class="ttname"><a href="structgf_1_1_rect.html">gf::Rect< float ></a></div></div>
<div class="ttc" id="astructgf_1_1_rect_html_a31b49fa6bcdbc3090e4011e5195db8b0"><div class="ttname"><a href="structgf_1_1_rect.html#a31b49fa6bcdbc3090e4011e5195db8b0">gf::Rect< float >::fromSize</a></div><div class="ttdeci">static constexpr Rect< float > fromSize(Vector< float, 2 > size) noexcept</div><div class="ttdoc">Create a rectangle from a size.</div><div class="ttdef"><b>Definition:</b> Rect.h:129</div></div>
<div class="ttc" id="astructgf_1_1_render_states_html"><div class="ttname"><a href="structgf_1_1_render_states.html">gf::RenderStates</a></div><div class="ttdoc">Define the states used for drawing to a RenderTarget.</div><div class="ttdef"><b>Definition:</b> RenderStates.h:82</div></div>
<div class="ttc" id="astructgf_1_1_vector_3_01_t_00_014_01_4_html"><div class="ttname"><a href="structgf_1_1_vector_3_01_t_00_014_01_4.html">gf::Vector< T, 4 ></a></div><div class="ttdoc">A 4D vector.</div><div class="ttdef"><b>Definition:</b> Vector.h:852</div></div>
<div class="ttc" id="astructgf_1_1_vector_html"><div class="ttname"><a href="structgf_1_1_vector.html">gf::Vector< float, 2 ></a></div></div>
<div class="ttc" id="astructgf_1_1_vertex_html"><div class="ttname"><a href="structgf_1_1_vertex.html">gf::Vertex</a></div><div class="ttdoc">A point associated with a color and a texture coordinate.</div><div class="ttdef"><b>Definition:</b> Vertex.h:75</div></div>
</div><!-- fragment --></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
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.3
</small></address>
</body>
</html>