aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/libraries/irrlicht-1.8.1/doc/html/classirr_1_1video_1_1_i_texture.html
blob: 5934dbdb42ab6f9ce293cb9f54f482442eed2af9 (plain)
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
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://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"/>
<title>Irrlicht 3D Engine: irr::video::ITexture Class Reference</title>

<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>

</head>
<body>
<div id="top"><!-- do not remove this div! -->


<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  
  <td id="projectlogo"><img alt="Logo" src="irrlichtlogo.png"/></td>
  
  
  <td style="padding-left: 0.5em;">
   <div id="projectname">Irrlicht 3D Engine
   
   </div>
   
  </td>
  
  
  
   
   <td>        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
</td>
   
  
 </tr>
 </tbody>
</table>
</div>

<!-- Generated by Doxygen 1.7.5.1 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
<script type="text/javascript" src="dynsections.js"></script>
</div>
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
  initNavTree('classirr_1_1video_1_1_i_texture.html','');
</script>
<div id="doc-content">
<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pro-methods">Protected Member Functions</a> &#124;
<a href="#pro-attribs">Protected Attributes</a>  </div>
  <div class="headertitle">
<div class="title">irr::video::ITexture Class Reference</div>  </div>
</div>
<div class="contents">
<!-- doxytag: class="irr::video::ITexture" --><!-- doxytag: inherits="irr::IReferenceCounted" -->
<p>Interface of a Video Driver dependent Texture.  
 <a href="classirr_1_1video_1_1_i_texture.html#details">More...</a></p>

<p><code>#include &lt;<a class="el" href="_i_texture_8h_source.html">ITexture.h</a>&gt;</code></p>
<div id="dynsection-0" onclick="return toggleVisibility(this)" class="dynheader closed" style="cursor:pointer;">
  <img id="dynsection-0-trigger" src="closed.png" alt="+"/> Inheritance diagram for irr::video::ITexture:</div>
<div id="dynsection-0-summary" class="dynsummary" style="display:block;">
</div>
<div id="dynsection-0-content" class="dyncontent" style="display:none;">
 <div class="center">
  <img src="classirr_1_1video_1_1_i_texture.png" usemap="#irr::video::ITexture_map" alt=""/>
  <map id="irr::video::ITexture_map" name="irr::video::ITexture_map">
<area href="classirr_1_1_i_reference_counted.html" title="Base class of most objects of the Irrlicht Engine." alt="irr::IReferenceCounted" shape="rect" coords="0,0,140,24"/>
</map>
 </div></div>

<p><a href="classirr_1_1video_1_1_i_texture-members.html">List of all members.</a></p>
<h2><a name="pub-methods"></a>
Public Member Functions</h2>
<ul>
<li><a class="el" href="classirr_1_1video_1_1_i_texture.html#a32dbd62fef8a65f11e5b440706346c90">ITexture</a> (const <a class="el" href="namespaceirr_1_1io.html#ab1bdc45edb3f94d8319c02bc0f840ee1">io::path</a> &amp;name)
<dl class="el"><dd class="mdescRight">constructor  <a href="#a32dbd62fef8a65f11e5b440706346c90"></a><br/></dl><li>virtual <a class="el" href="namespaceirr_1_1video.html#a1d5e487888c32b1674a8f75116d829ed">ECOLOR_FORMAT</a> <a class="el" href="classirr_1_1video_1_1_i_texture.html#a48bbc0208c046724fc3264406f774132">getColorFormat</a> () const =0
<dl class="el"><dd class="mdescRight">Get the color format of texture.  <a href="#a48bbc0208c046724fc3264406f774132"></a><br/></dl><li>virtual <a class="el" href="namespaceirr_1_1video.html#ae35a6de6d436c76107ad157fe42356d0">E_DRIVER_TYPE</a> <a class="el" href="classirr_1_1video_1_1_i_texture.html#a4c6abdc0c789e6022e4e1b8a06cfab71">getDriverType</a> () const =0
<dl class="el"><dd class="mdescRight">Get driver type of texture.  <a href="#a4c6abdc0c789e6022e4e1b8a06cfab71"></a><br/></dl><li>const <a class="el" href="structirr_1_1io_1_1_s_named_path.html">io::SNamedPath</a> &amp; <a class="el" href="classirr_1_1video_1_1_i_texture.html#acad4f8a4e9b8de5683eebbd7451e2009">getName</a> () const 
<dl class="el"><dd class="mdescRight">Get name of texture (in most cases this is the filename)  <a href="#acad4f8a4e9b8de5683eebbd7451e2009"></a><br/></dl><li>virtual const <br class="typebreak"/>
<a class="el" href="classirr_1_1core_1_1dimension2d.html">core::dimension2d</a>&lt; <a class="el" href="namespaceirr.html#a0416a53257075833e7002efd0a18e804">u32</a> &gt; &amp; <a class="el" href="classirr_1_1video_1_1_i_texture.html#adbb05bcee8ec7fa11bb4ccfdb725cda8">getOriginalSize</a> () const =0
<dl class="el"><dd class="mdescRight">Get original size of the texture.  <a href="#adbb05bcee8ec7fa11bb4ccfdb725cda8"></a><br/></dl><li>virtual <a class="el" href="namespaceirr.html#a0416a53257075833e7002efd0a18e804">u32</a> <a class="el" href="classirr_1_1video_1_1_i_texture.html#a14fd1eba217a0dd86b40c4d792ab14ea">getPitch</a> () const =0
<dl class="el"><dd class="mdescRight">Get pitch of the main texture (in bytes).  <a href="#a14fd1eba217a0dd86b40c4d792ab14ea"></a><br/></dl><li>virtual const <br class="typebreak"/>
<a class="el" href="classirr_1_1core_1_1dimension2d.html">core::dimension2d</a>&lt; <a class="el" href="namespaceirr.html#a0416a53257075833e7002efd0a18e804">u32</a> &gt; &amp; <a class="el" href="classirr_1_1video_1_1_i_texture.html#adfcf9558c0f1ae543782c03f7903c48e">getSize</a> () const =0
<dl class="el"><dd class="mdescRight">Get dimension (=size) of the texture.  <a href="#adfcf9558c0f1ae543782c03f7903c48e"></a><br/></dl><li>virtual bool <a class="el" href="classirr_1_1video_1_1_i_texture.html#a38b90ca5d956bd9772f2aa8032b38cd5">hasAlpha</a> () const 
<dl class="el"><dd class="mdescRight">Returns if the texture has an alpha channel.  <a href="#a38b90ca5d956bd9772f2aa8032b38cd5"></a><br/></dl><li>virtual bool <a class="el" href="classirr_1_1video_1_1_i_texture.html#a37444068f2f292c43c2ffd516a32a764">hasMipMaps</a> () const 
<dl class="el"><dd class="mdescRight">Check whether the texture has MipMaps.  <a href="#a37444068f2f292c43c2ffd516a32a764"></a><br/></dl><li>virtual bool <a class="el" href="classirr_1_1video_1_1_i_texture.html#ab085e1f1a76a55ab4c5fcdfdeedfb45c">isRenderTarget</a> () const 
<dl class="el"><dd class="mdescRight">Check whether the texture is a render target.  <a href="#ab085e1f1a76a55ab4c5fcdfdeedfb45c"></a><br/></dl><li>virtual void * <a class="el" href="classirr_1_1video_1_1_i_texture.html#aa09ee89973a645ebdd2bd61ed859df38">lock</a> (<a class="el" href="namespaceirr_1_1video.html#a3916d259e8fe0d0d02e8ee0adc8af5bc">E_TEXTURE_LOCK_MODE</a> mode=ETLM_READ_WRITE, <a class="el" href="namespaceirr.html#a0416a53257075833e7002efd0a18e804">u32</a> mipmapLevel=0)=0
<dl class="el"><dd class="mdescRight">Lock function.  <a href="#aa09ee89973a645ebdd2bd61ed859df38"></a><br/></dl><li>virtual void <a class="el" href="classirr_1_1video_1_1_i_texture.html#a9517c37f071479d0698cdf597f8fea45">regenerateMipMapLevels</a> (void *mipmapData=0)=0
<dl class="el"><dd class="mdescRight">Regenerates the mip map levels of the texture.  <a href="#a9517c37f071479d0698cdf597f8fea45"></a><br/></dl><li>virtual void <a class="el" href="classirr_1_1video_1_1_i_texture.html#a15b9a25aa18528ade37a492bd7b20a10">unlock</a> ()=0
<dl class="el"><dd class="mdescRight">Unlock function. Must be called after a <a class="el" href="classirr_1_1video_1_1_i_texture.html#aa09ee89973a645ebdd2bd61ed859df38" title="Lock function.">lock()</a> to the texture.  <a href="#a15b9a25aa18528ade37a492bd7b20a10"></a><br/></dl></ul>
<h2><a name="pro-methods"></a>
Protected Member Functions</h2>
<ul>
<li><a class="el" href="namespaceirr_1_1video.html#acaf6f7414534f7d62bff18c5bf11876f">E_TEXTURE_CREATION_FLAG</a> <a class="el" href="classirr_1_1video_1_1_i_texture.html#afff3160f6aa5f749365ae4f776a440f3">getTextureFormatFromFlags</a> (<a class="el" href="namespaceirr.html#a0416a53257075833e7002efd0a18e804">u32</a> flags)
<dl class="el"><dd class="mdescRight">Helper function, helps to get the desired texture creation format from the flags.  <a href="#afff3160f6aa5f749365ae4f776a440f3"></a><br/></dl></ul>
<h2><a name="pro-attribs"></a>
Protected Attributes</h2>
<ul>
<li><a class="el" href="structirr_1_1io_1_1_s_named_path.html">io::SNamedPath</a> <a class="el" href="classirr_1_1video_1_1_i_texture.html#ad1ab74da43861e50f0ec6a2e9a813fb4">NamedPath</a>
</ul>
<hr/><a name="details" id="details"></a><h2>Detailed Description</h2>
<div class="textblock"><p>Interface of a Video Driver dependent Texture. </p>
<p>An <a class="el" href="classirr_1_1video_1_1_i_texture.html" title="Interface of a Video Driver dependent Texture.">ITexture</a> is created by an <a class="el" href="classirr_1_1video_1_1_i_video_driver.html" title="Interface to driver which is able to perform 2d and 3d graphics functions.">IVideoDriver</a> by using <a class="el" href="classirr_1_1video_1_1_i_video_driver.html#a8c02ee280bb738cdf38b77e7a798244e" title="Creates an empty texture of specified size.">IVideoDriver::addTexture</a> or <a class="el" href="classirr_1_1video_1_1_i_video_driver.html#af4055165190e4adf221c6dc6f2434ea0" title="Get access to a named texture.">IVideoDriver::getTexture</a>. After that, the texture may only be used by this VideoDriver. As you can imagine, textures of the DirectX and the OpenGL device will, e.g., not be compatible. An exception is the Software device and the NULL device, their textures are compatible. If you try to use a texture created by one device with an other device, the device will refuse to do that and write a warning or an error message to the output buffer. </p>

<p>Definition at line <a class="el" href="_i_texture_8h_source.html#l00098">98</a> of file <a class="el" href="_i_texture_8h_source.html">ITexture.h</a>.</p>
</div><hr/><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="a32dbd62fef8a65f11e5b440706346c90"></a><!-- doxytag: member="irr::video::ITexture::ITexture" ref="a32dbd62fef8a65f11e5b440706346c90" args="(const io::path &amp;name)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">irr::video::ITexture::ITexture </td>
          <td>(</td>
          <td class="paramtype">const <a class="el" href="namespaceirr_1_1io.html#ab1bdc45edb3f94d8319c02bc0f840ee1">io::path</a> &amp;&#160;</td>
          <td class="paramname"><em>name</em></td><td>)</td>
          <td><code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>constructor </p>

<p>Definition at line <a class="el" href="_i_texture_8h_source.html#l00103">103</a> of file <a class="el" href="_i_texture_8h_source.html">ITexture.h</a>.</p>

</div>
</div>
<hr/><h2>Member Function Documentation</h2>
<a class="anchor" id="a48bbc0208c046724fc3264406f774132"></a><!-- doxytag: member="irr::video::ITexture::getColorFormat" ref="a48bbc0208c046724fc3264406f774132" args="() const =0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="namespaceirr_1_1video.html#a1d5e487888c32b1674a8f75116d829ed">ECOLOR_FORMAT</a> irr::video::ITexture::getColorFormat </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const<code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get the color format of texture. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>The color format of texture. </dd></dl>

<p>Referenced by <a class="el" href="_i_texture_8h_source.html#l00170">hasAlpha()</a>.</p>

</div>
</div>
<a class="anchor" id="a4c6abdc0c789e6022e4e1b8a06cfab71"></a><!-- doxytag: member="irr::video::ITexture::getDriverType" ref="a4c6abdc0c789e6022e4e1b8a06cfab71" args="() const =0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="namespaceirr_1_1video.html#ae35a6de6d436c76107ad157fe42356d0">E_DRIVER_TYPE</a> irr::video::ITexture::getDriverType </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const<code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get driver type of texture. </p>
<p>This is the driver, which created the texture. This method is used internally by the video devices, to check, if they may use a texture because textures may be incompatible between different devices. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>Driver type of texture. </dd></dl>

</div>
</div>
<a class="anchor" id="acad4f8a4e9b8de5683eebbd7451e2009"></a><!-- doxytag: member="irr::video::ITexture::getName" ref="acad4f8a4e9b8de5683eebbd7451e2009" args="() const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">const <a class="el" href="structirr_1_1io_1_1_s_named_path.html">io::SNamedPath</a>&amp; irr::video::ITexture::getName </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const<code> [inline]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get name of texture (in most cases this is the filename) </p>

<p>Definition at line <a class="el" href="_i_texture_8h_source.html#l00191">191</a> of file <a class="el" href="_i_texture_8h_source.html">ITexture.h</a>.</p>

<p>References <a class="el" href="_i_texture_8h_source.html#l00211">NamedPath</a>.</p>

</div>
</div>
<a class="anchor" id="adbb05bcee8ec7fa11bb4ccfdb725cda8"></a><!-- doxytag: member="irr::video::ITexture::getOriginalSize" ref="adbb05bcee8ec7fa11bb4ccfdb725cda8" args="() const =0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual const <a class="el" href="classirr_1_1core_1_1dimension2d.html">core::dimension2d</a>&lt;<a class="el" href="namespaceirr.html#a0416a53257075833e7002efd0a18e804">u32</a>&gt;&amp; irr::video::ITexture::getOriginalSize </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const<code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get original size of the texture. </p>
<p>The texture is usually scaled, if it was created with an unoptimal size. For example if the size was not a power of two. This method returns the size of the texture it had before it was scaled. Can be useful when drawing 2d images on the screen, which should have the exact size of the original texture. Use <a class="el" href="classirr_1_1video_1_1_i_texture.html#adfcf9558c0f1ae543782c03f7903c48e" title="Get dimension (=size) of the texture.">ITexture::getSize()</a> if you want to know the real size it has now stored in the system. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>The original size of the texture. </dd></dl>

</div>
</div>
<a class="anchor" id="a14fd1eba217a0dd86b40c4d792ab14ea"></a><!-- doxytag: member="irr::video::ITexture::getPitch" ref="a14fd1eba217a0dd86b40c4d792ab14ea" args="() const =0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual <a class="el" href="namespaceirr.html#a0416a53257075833e7002efd0a18e804">u32</a> irr::video::ITexture::getPitch </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const<code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get pitch of the main texture (in bytes). </p>
<p>The pitch is the amount of bytes used for a row of pixels in a texture. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>Pitch of texture in bytes. </dd></dl>

</div>
</div>
<a class="anchor" id="adfcf9558c0f1ae543782c03f7903c48e"></a><!-- doxytag: member="irr::video::ITexture::getSize" ref="adfcf9558c0f1ae543782c03f7903c48e" args="() const =0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual const <a class="el" href="classirr_1_1core_1_1dimension2d.html">core::dimension2d</a>&lt;<a class="el" href="namespaceirr.html#a0416a53257075833e7002efd0a18e804">u32</a>&gt;&amp; irr::video::ITexture::getSize </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const<code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Get dimension (=size) of the texture. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>The size of the texture. </dd></dl>

</div>
</div>
<a class="anchor" id="afff3160f6aa5f749365ae4f776a440f3"></a><!-- doxytag: member="irr::video::ITexture::getTextureFormatFromFlags" ref="afff3160f6aa5f749365ae4f776a440f3" args="(u32 flags)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="namespaceirr_1_1video.html#acaf6f7414534f7d62bff18c5bf11876f">E_TEXTURE_CREATION_FLAG</a> irr::video::ITexture::getTextureFormatFromFlags </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="namespaceirr.html#a0416a53257075833e7002efd0a18e804">u32</a>&#160;</td>
          <td class="paramname"><em>flags</em></td><td>)</td>
          <td><code> [inline, protected]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Helper function, helps to get the desired texture creation format from the flags. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>Either ETCF_ALWAYS_32_BIT, ETCF_ALWAYS_16_BIT, ETCF_OPTIMIZED_FOR_QUALITY, or ETCF_OPTIMIZED_FOR_SPEED. </dd></dl>

<p>Definition at line <a class="el" href="_i_texture_8h_source.html#l00198">198</a> of file <a class="el" href="_i_texture_8h_source.html">ITexture.h</a>.</p>

<p>References <a class="el" href="_i_texture_8h_source.html#l00032">irr::video::ETCF_ALWAYS_16_BIT</a>, <a class="el" href="_i_texture_8h_source.html#l00041">irr::video::ETCF_ALWAYS_32_BIT</a>, <a class="el" href="_i_texture_8h_source.html#l00049">irr::video::ETCF_OPTIMIZED_FOR_QUALITY</a>, and <a class="el" href="_i_texture_8h_source.html#l00056">irr::video::ETCF_OPTIMIZED_FOR_SPEED</a>.</p>

</div>
</div>
<a class="anchor" id="a38b90ca5d956bd9772f2aa8032b38cd5"></a><!-- doxytag: member="irr::video::ITexture::hasAlpha" ref="a38b90ca5d956bd9772f2aa8032b38cd5" args="() const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual bool irr::video::ITexture::hasAlpha </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const<code> [inline, virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Returns if the texture has an alpha channel. </p>

<p>Definition at line <a class="el" href="_i_texture_8h_source.html#l00170">170</a> of file <a class="el" href="_i_texture_8h_source.html">ITexture.h</a>.</p>

<p>References <a class="el" href="_s_color_8h_source.html#l00023">irr::video::ECF_A1R5G5B5</a>, <a class="el" href="_s_color_8h_source.html#l00032">irr::video::ECF_A8R8G8B8</a>, and <a class="el" href="classirr_1_1video_1_1_i_texture.html#a48bbc0208c046724fc3264406f774132">getColorFormat()</a>.</p>

</div>
</div>
<a class="anchor" id="a37444068f2f292c43c2ffd516a32a764"></a><!-- doxytag: member="irr::video::ITexture::hasMipMaps" ref="a37444068f2f292c43c2ffd516a32a764" args="() const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual bool irr::video::ITexture::hasMipMaps </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const<code> [inline, virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Check whether the texture has MipMaps. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>True if texture has MipMaps, else false. </dd></dl>

<p>Definition at line <a class="el" href="_i_texture_8h_source.html#l00167">167</a> of file <a class="el" href="_i_texture_8h_source.html">ITexture.h</a>.</p>

</div>
</div>
<a class="anchor" id="ab085e1f1a76a55ab4c5fcdfdeedfb45c"></a><!-- doxytag: member="irr::video::ITexture::isRenderTarget" ref="ab085e1f1a76a55ab4c5fcdfdeedfb45c" args="() const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual bool irr::video::ITexture::isRenderTarget </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const<code> [inline, virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Check whether the texture is a render target. </p>
<p>Render targets can be set as such in the video driver, in order to render a scene into the texture. Once unbound as render target, they can be used just as usual textures again. </p>
<dl class="return"><dt><b>Returns:</b></dt><dd>True if this is a render target, otherwise false. </dd></dl>

<p>Definition at line <a class="el" href="_i_texture_8h_source.html#l00188">188</a> of file <a class="el" href="_i_texture_8h_source.html">ITexture.h</a>.</p>

</div>
</div>
<a class="anchor" id="aa09ee89973a645ebdd2bd61ed859df38"></a><!-- doxytag: member="irr::video::ITexture::lock" ref="aa09ee89973a645ebdd2bd61ed859df38" args="(E_TEXTURE_LOCK_MODE mode=ETLM_READ_WRITE, u32 mipmapLevel=0)=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual void* irr::video::ITexture::lock </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="namespaceirr_1_1video.html#a3916d259e8fe0d0d02e8ee0adc8af5bc">E_TEXTURE_LOCK_MODE</a>&#160;</td>
          <td class="paramname"><em>mode</em> = <code>ETLM_READ_WRITE</code>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="namespaceirr.html#a0416a53257075833e7002efd0a18e804">u32</a>&#160;</td>
          <td class="paramname"><em>mipmapLevel</em> = <code>0</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Lock function. </p>
<p>Locks the Texture and returns a pointer to access the pixels. After <a class="el" href="classirr_1_1video_1_1_i_texture.html#aa09ee89973a645ebdd2bd61ed859df38" title="Lock function.">lock()</a> has been called and all operations on the pixels are done, you must call <a class="el" href="classirr_1_1video_1_1_i_texture.html#a15b9a25aa18528ade37a492bd7b20a10" title="Unlock function. Must be called after a lock() to the texture.">unlock()</a>. Locks are not accumulating, hence one unlock will do for an arbitrary number of previous locks. You should avoid locking different levels without unlocking inbetween, though, because only the last level locked will be unlocked. The size of the i-th mipmap level is defined as max(<a class="el" href="classirr_1_1video_1_1_i_texture.html#adfcf9558c0f1ae543782c03f7903c48e" title="Get dimension (=size) of the texture.">getSize()</a>.Width&gt;&gt;i,1) and max(<a class="el" href="classirr_1_1video_1_1_i_texture.html#adfcf9558c0f1ae543782c03f7903c48e" title="Get dimension (=size) of the texture.">getSize()</a>.Height&gt;&gt;i,1) </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">mode</td><td>Specifies what kind of changes to the locked texture are allowed. Unspecified behavior will arise if texture is written in read only mode or read from in write only mode. Support for this feature depends on the driver, so don't rely on the texture being write-protected when locking with read-only, etc. </td></tr>
    <tr><td class="paramname">mipmapLevel</td><td>Number of the mipmapLevel to lock. 0 is main texture. Non-existing levels will silently fail and return 0. </td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>Returns a pointer to the pixel data. The format of the pixel can be determined by using <a class="el" href="classirr_1_1video_1_1_i_texture.html#a48bbc0208c046724fc3264406f774132" title="Get the color format of texture.">getColorFormat()</a>. 0 is returned, if the texture cannot be locked. </dd></dl>

</div>
</div>
<a class="anchor" id="a9517c37f071479d0698cdf597f8fea45"></a><!-- doxytag: member="irr::video::ITexture::regenerateMipMapLevels" ref="a9517c37f071479d0698cdf597f8fea45" args="(void *mipmapData=0)=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual void irr::video::ITexture::regenerateMipMapLevels </td>
          <td>(</td>
          <td class="paramtype">void *&#160;</td>
          <td class="paramname"><em>mipmapData</em> = <code>0</code></td><td>)</td>
          <td><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Regenerates the mip map levels of the texture. </p>
<p>Required after modifying the texture, usually after calling <a class="el" href="classirr_1_1video_1_1_i_texture.html#a15b9a25aa18528ade37a492bd7b20a10" title="Unlock function. Must be called after a lock() to the texture.">unlock()</a>. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">mipmapData</td><td>Optional parameter to pass in image data which will be used instead of the previously stored or automatically generated mipmap data. The data has to be a continuous pixel data for all mipmaps until 1x1 pixel. Each mipmap has to be half the width and height of the previous level. At least one pixel will be always kept. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a15b9a25aa18528ade37a492bd7b20a10"></a><!-- doxytag: member="irr::video::ITexture::unlock" ref="a15b9a25aa18528ade37a492bd7b20a10" args="()=0" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual void irr::video::ITexture::unlock </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td><code> [pure virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Unlock function. Must be called after a <a class="el" href="classirr_1_1video_1_1_i_texture.html#aa09ee89973a645ebdd2bd61ed859df38" title="Lock function.">lock()</a> to the texture. </p>
<p>One should avoid to call unlock more than once before another lock. The last locked mip level will be unlocked. </p>

</div>
</div>
<hr/><h2>Member Data Documentation</h2>
<a class="anchor" id="ad1ab74da43861e50f0ec6a2e9a813fb4"></a><!-- doxytag: member="irr::video::ITexture::NamedPath" ref="ad1ab74da43861e50f0ec6a2e9a813fb4" args="" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="structirr_1_1io_1_1_s_named_path.html">io::SNamedPath</a> <a class="el" href="classirr_1_1video_1_1_i_texture.html#ad1ab74da43861e50f0ec6a2e9a813fb4">irr::video::ITexture::NamedPath</a><code> [protected]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Definition at line <a class="el" href="_i_texture_8h_source.html#l00211">211</a> of file <a class="el" href="_i_texture_8h_source.html">ITexture.h</a>.</p>

<p>Referenced by <a class="el" href="_i_texture_8h_source.html#l00191">getName()</a>.</p>

</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="_i_texture_8h_source.html">ITexture.h</a></li>
</ul>
</div>
</div>
  <div id="nav-path" class="navpath">
    <ul>
      <li class="navelem"><a class="el" href="namespaceirr.html">irr</a>      </li>
      <li class="navelem"><a class="el" href="namespaceirr_1_1video.html">video</a>      </li>
      <li class="navelem"><a class="el" href="classirr_1_1video_1_1_i_texture.html">ITexture</a>      </li>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Namespaces</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark">&#160;</span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark">&#160;</span>Enumerator</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(9)"><span class="SelectionMark">&#160;</span>Friends</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(10)"><span class="SelectionMark">&#160;</span>Defines</a></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>


    <li class="footer">
<a href="http://irrlicht.sourceforge.net" target="_blank">Irrlicht 
Engine</a> Documentation &copy; 2003-2012 by Nikolaus Gebhardt. Generated on Sun Nov 17 2013 20:18:48 for Irrlicht 3D Engine by
<a href="http://www.doxygen.org/index.html" target="_blank">Doxygen</a> 1.7.5.1 </li>
   </ul>
 </div>


</body>
</html>