diff options
author | neodarz <neodarz@neodarz.net> | 2018-08-11 20:21:34 +0200 |
---|---|---|
committer | neodarz <neodarz@neodarz.net> | 2018-08-11 20:21:34 +0200 |
commit | 0ea5fc66924303d1bf73ba283a383e2aadee02f2 (patch) | |
tree | 2568e71a7ccc44ec23b8bb3f0ff97fb6bf2ed709 /docs/doxygen/nel/texture_8h-source.html | |
download | nevrax-website-self-hostable-0ea5fc66924303d1bf73ba283a383e2aadee02f2.tar.xz nevrax-website-self-hostable-0ea5fc66924303d1bf73ba283a383e2aadee02f2.zip |
Initial commit
Diffstat (limited to 'docs/doxygen/nel/texture_8h-source.html')
-rw-r--r-- | docs/doxygen/nel/texture_8h-source.html | 373 |
1 files changed, 373 insertions, 0 deletions
diff --git a/docs/doxygen/nel/texture_8h-source.html b/docs/doxygen/nel/texture_8h-source.html new file mode 100644 index 00000000..ef960de6 --- /dev/null +++ b/docs/doxygen/nel/texture_8h-source.html @@ -0,0 +1,373 @@ +<!doctype html public "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd"> +<HTML> +<HEAD> + <TITLE>nevrax.org : docs</TITLE> + <LINK REL=stylesheet TYPE="text/css" HREF="http://www.nevrax.org/inc/css/nevrax.css"> + <link href="doxygen.css" rel="stylesheet" type="text/css"> +</HEAD> +<BODY MARGINHEIGHT="0" MARGINWIDTH="0"> + +<!-- uplinks --> +<TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0> + <TR> + <TD WIDTH=16><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="16" HEIGHT="16" BORDER=0 ALT=""></TD> + <TD WIDTH=140 BGCOLOR=#dddddd><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="140" HEIGHT="16" BORDER=0 ALT=""></TD> + <TD WIDTH=16><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="16" HEIGHT="16" BORDER=0 ALT=""></TD> + <TD><IMG width=6 height=14 SRC="http://www.nevrax.org/inc/img/reddots.gif" ALT="#" VSPACE=2 HSPACE=2 BORDER=0 ></TD><TD VALIGN=middle> <A CLASS=uplinks HREF=http://www.nevrax.org><b>Home</B></FONT></A> </TD> + <TD><IMG width=6 height=14 SRC="http://www.nevrax.org/inc/img/reddots.gif" ALT="#" VSPACE=2 HSPACE=2 BORDER=0 ></TD><TD VALIGN=middle> <A CLASS=uplinks HREF=http://www.nevrax.com><b>nevrax.com</B></FONT></A> </TD> + </TR> +</TABLE> + +<!-- banner Nevrax --> +<TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 WIDTH=100%> + <TR><TD BGCOLOR="#000000" BACKGROUND="http://www.nevrax.org/inc/img/black_banner.jpg"><A HREF="http://www.nevrax.org"><IMG SRC="http://www.nevrax.org/inc/img/nevrax.gif" WIDTH="170" HEIGHT="45" BORDER=0 ALT="Nevrax" ></A></TD></TR> +</TABLE> + +<!-- main table --> +<TABLE CELLSPACING=0 CELLPADDING=0 BORDER=0 height=100%> + <TR> + <TD WIDTH=16><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="16" HEIGHT="10" BORDER=0 ALT=""></TD> + <TD WIDTH=140 BGCOLOR=#dddddd VALIGN=TOP ALIGN=middle><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="140" HEIGHT="10" BORDER=0 ALT=""> + + <!------ Begin Box ------> + <TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 BGCOLOR=black><TR><TD><TABLE border=0 cellspacing=2 cellpadding=0 width=120><tr><TD ALIGN=middle bgcolor=black> + <FONT COLOR=white FACE="sans-serif"><B>Nevrax.org</B></FONT></TD></TR><tr><td colspan=2 bgcolor=#FFFFFF> + <TABLE cellspacing=0 cellpadding=1 border=0> + <tr><td ALIGN=middle><a class='linkbox' href="http://www.nevrax.org/news/" TITLE="Rubrique news"><img width=13 height=15 hspace=5 border=0 src=http://www.nevrax.org/inc/img/picto-news.gif ALT=#></A></td><td><a class='linkbox' href="http://www.nevrax.org/news/" TITLE="News">News</a></td></tr> + <tr><td ALIGN=middle><a class='linkbox' href="http://www.nevrax.org/mail/" TITLE="Rubrique mail"><img width=15 height=11 hspace=5 border=0 src=http://www.nevrax.org/inc/img/picto-mail.gif ALT=#></A></td><td><a class='linkbox' href="http://www.nevrax.org/mail/" TITLE="Mailing list archive">Mailing-list</a></td></tr> + <tr><td ALIGN=middle><a class='linkbox' href="http://www.nevrax.org/docs/" TITLE="Rubrique docs"><img width=14 height=16 hspace=5 border=0 src=http://www.nevrax.org/inc/img/picto-docs.gif ALT=#></A></td><td><a class='linkbox' href="http://www.nevrax.org/docs/" TITLE="Documentation">Documentation</a></td></tr> + <tr><td ALIGN=middle><a class='linkbox' href="http://www.nevrax.org/cvs/" TITLE="Rubrique cvs"><img width=13 height=17 hspace=5 border=0 src=http://www.nevrax.org/inc/img/picto-cvs.gif ALT=#></A></td><td><a class='linkbox' href="http://www.nevrax.org/cvs/" TITLE="CVS Web">CVS</a></td></tr> + <tr><td ALIGN=middle><a class='linkbox' href="http://www.nevrax.org/bugs/" TITLE="Rubrique bugs"><img width=20 height=16 hspace=5 border=0 src=http://www.nevrax.org/inc/img/picto-bugs.gif ALT=#></A></td><td><a class='linkbox' href="http://www.nevrax.org/bugs/" TITLE="Bugtracking">Bugs</a></td></tr> + <tr><td ALIGN=middle><a class='linkbox' href="http://www.nevrax.org/GPL.php3" TITLE="Rubrique license"><img width=18 height=12 hspace=5 border=0 src=http://www.nevrax.org/inc/img/picto-gpl.gif ALT=#></A></td><td><a class='linkbox' href="http://www.nevrax.org/GPL.php3" TITLE="License">License</a></td></tr> + </TABLE> + </TD></TR></TABLE></TD></TR></TABLE> + <!------ End Box ------> + + </TD> + <TD WIDTH=15><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="16" HEIGHT="16" BORDER=0 ALT=""></TD> + <TD ALIGN=left valign=top><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="140" HEIGHT="10" BORDER=0 ALT=""> + +<!-- title --> +<TABLE background="http://www.nevrax.org/inc/img/redline.gif" CELLSPACING=0 CELLPADDING=0 BORDER=0 width=100%><tr><td> +<A HREF="http://www.nevrax.org/docs/"><img src="http://www.nevrax.org/inc/img/t_docs.gif" ALT="Docs" HEIGHT=20 BORDER=0></A> +</td><td><IMG SRC="http://www.nevrax.org/inc/img/pixel.gif" WIDTH="1" HEIGHT="1" BORDER=0 ALT=""> +</td></tr></table> + + +<!-- block --> +<TABLE bgcolor="#dddddd" CELLSPACING=0 CELLPADDING=0 BORDER=0 width=100%><tr><td width=1% valign=middle><img width=6 height=14 hspace=2 vspace=2 src="http://www.nevrax.org/inc/img/reddots.gif"></TD> + <TD><B>Documentation</B></TD> + <TD ALIGN=RIGHT> </td> +</tr></table> +<!-- Generated by Doxygen 1.2.14 --> +<center> +<a class="qindex" href="index.html">Main Page</a> <a class="qindex" href="namespaces.html">Namespace List</a> <a class="qindex" href="hierarchy.html">Class Hierarchy</a> <a class="qindex" href="classes.html">Alphabetical List</a> <a class="qindex" href="annotated.html">Compound List</a> <a class="qindex" href="files.html">File List</a> <a class="qindex" href="namespacemembers.html">Namespace Members</a> <a class="qindex" href="functions.html">Compound Members</a> <a class="qindex" href="globals.html">File Members</a> <a class="qindex" href="pages.html">Related Pages</a> <a class="qindexRef" doxygen="_cgi:http://www.nevrax.org/cgi-bin/nel-search.cgi" href="http://www.nevrax.org/cgi-bin/nel-search.cgi">Search</a> </center> +<hr><h1>texture.h</h1><a href="texture_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre>00001 +00007 <font class="comment">/* Copyright, 2000 Nevrax Ltd.</font> +00008 <font class="comment"> *</font> +00009 <font class="comment"> * This file is part of NEVRAX NEL.</font> +00010 <font class="comment"> * NEVRAX NEL is free software; you can redistribute it and/or modify</font> +00011 <font class="comment"> * it under the terms of the GNU General Public License as published by</font> +00012 <font class="comment"> * the Free Software Foundation; either version 2, or (at your option)</font> +00013 <font class="comment"> * any later version.</font> +00014 <font class="comment"></font> +00015 <font class="comment"> * NEVRAX NEL is distributed in the hope that it will be useful, but</font> +00016 <font class="comment"> * WITHOUT ANY WARRANTY; without even the implied warranty of</font> +00017 <font class="comment"> * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU</font> +00018 <font class="comment"> * General Public License for more details.</font> +00019 <font class="comment"></font> +00020 <font class="comment"> * You should have received a copy of the GNU General Public License</font> +00021 <font class="comment"> * along with NEVRAX NEL; see the file COPYING. If not, write to the</font> +00022 <font class="comment"> * Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,</font> +00023 <font class="comment"> * MA 02111-1307, USA.</font> +00024 <font class="comment"> */</font> +00025 +00026 <font class="preprocessor">#ifndef NL_TEXTURE_H</font> +00027 <font class="preprocessor"></font><font class="preprocessor">#define NL_TEXTURE_H</font> +00028 <font class="preprocessor"></font> +00029 <font class="preprocessor">#include "<a class="code" href="types__nl_8h.html">nel/misc/types_nl.h</a>"</font> +00030 <font class="preprocessor">#include "<a class="code" href="smart__ptr_8h.html">nel/misc/smart_ptr.h</a>"</font> +00031 <font class="preprocessor">#include "<a class="code" href="stream_8h.html">nel/misc/stream.h</a>"</font> +00032 <font class="preprocessor">#include "<a class="code" href="rect_8h.html">nel/misc/rect.h</a>"</font> +00033 <font class="preprocessor">#include "<a class="code" href="bitmap_8h.html">nel/misc/bitmap.h</a>"</font> +00034 <font class="preprocessor">#include <string></font> +00035 <font class="preprocessor">#include <list></font> +00036 <font class="preprocessor">#include <map></font> +00037 +00038 +00039 <font class="keyword">namespace </font>NL3D +00040 { +00041 +00042 +00043 <font class="keyword">using</font> <a class="code" href="classNLMISC_1_1CBitmap.html">NLMISC::CBitmap</a>; +00044 +00045 +00046 <font class="keyword">class </font>IDriver; +00047 +00048 +00049 <font class="comment">//****************************************************************************</font> +00050 +00051 <font class="comment">// List typedef.</font> +00052 <font class="keyword">class </font>ITextureDrvInfos; +00053 <font class="keyword">class </font>CTextureDrvShare; +<a name="l00054"></a><a class="code" href="classNL3D_1_1TTexDrvInfoPtrMap.html">00054</a> <font class="keyword">class </font>TTexDrvInfoPtrMap : <font class="keyword">public</font> std::map< std::string, ITextureDrvInfos*> {}; +00055 <font class="keyword">typedef</font> <a class="code" href="classstd_1_1list.html">std::list<CTextureDrvShare*></a> <a class="code" href="namespaceNL3D.html#a245">TTexDrvSharePtrList</a>; +00056 <font class="keyword">typedef</font> TTexDrvInfoPtrMap::iterator <a class="code" href="namespaceNL3D.html#a246">ItTexDrvInfoPtrMap</a>; +00057 <font class="keyword">typedef</font> TTexDrvSharePtrList::iterator <a class="code" href="namespaceNL3D.html#a247">ItTexDrvSharePtrList</a>; +00058 +00059 +00060 <font class="comment">// Class for interaction of textures with Driver.</font> +00061 <font class="comment">// ITextureDrvInfos represent the real data of the texture, stored into the driver (eg: just a GLint for opengl).</font> +<a name="l00062"></a><a class="code" href="classNL3D_1_1ITextureDrvInfos.html">00062</a> <font class="keyword">class </font>ITextureDrvInfos : <font class="keyword">public</font> NLMISC::CRefCount +00063 { +00064 <font class="keyword">private</font>: +<a name="l00065"></a><a class="code" href="classNL3D_1_1ITextureDrvInfos.html#o0">00065</a> IDriver *<a class="code" href="classNL3D_1_1ITextureDrvInfos.html#o0">_Driver</a>; +<a name="l00066"></a><a class="code" href="classNL3D_1_1ITextureDrvInfos.html#o1">00066</a> <a class="code" href="namespaceNL3D.html#a246">ItTexDrvInfoPtrMap</a> <a class="code" href="classNL3D_1_1ITextureDrvInfos.html#o1">_DriverIterator</a>; +00067 +00068 <font class="keyword">public</font>: +<a name="l00069"></a><a class="code" href="classNL3D_1_1ITextureDrvInfos.html#a0">00069</a> <a class="code" href="classNL3D_1_1ITextureDrvInfos.html#a0">ITextureDrvInfos</a>(IDriver *drv, <a class="code" href="namespaceNL3D.html#a246">ItTexDrvInfoPtrMap</a> it) {<a class="code" href="classNL3D_1_1ITextureDrvInfos.html#o0">_Driver</a>= drv; <a class="code" href="classNL3D_1_1ITextureDrvInfos.html#o1">_DriverIterator</a>= it;} +00070 <a class="code" href="classNL3D_1_1ITextureDrvInfos.html#a0">ITextureDrvInfos</a>(<font class="keyword">class</font> IDriver& driver); +00071 <font class="keyword">virtual</font> <a class="code" href="classNL3D_1_1ITextureDrvInfos.html#a2">~ITextureDrvInfos</a>(<font class="keywordtype">void</font>); +00072 }; +00073 +00074 <font class="comment">// Many ITexture may point to the same ITextureDrvInfos, through CTextureDrvShare.</font> +<a name="l00075"></a><a class="code" href="classNL3D_1_1CTextureDrvShare.html">00075</a> <font class="keyword">class </font>CTextureDrvShare : <font class="keyword">public</font> NLMISC::CRefCount +00076 { +00077 <font class="keyword">private</font>: +<a name="l00078"></a><a class="code" href="classNL3D_1_1CTextureDrvShare.html#o0">00078</a> IDriver *<a class="code" href="classNL3D_1_1CTextureDrvShare.html#o0">_Driver</a>; +<a name="l00079"></a><a class="code" href="classNL3D_1_1CTextureDrvShare.html#o1">00079</a> <a class="code" href="namespaceNL3D.html#a247">ItTexDrvSharePtrList</a> <a class="code" href="classNL3D_1_1CTextureDrvShare.html#o1">_DriverIterator</a>; +00080 +00081 <font class="keyword">public</font>: +<a name="l00082"></a><a class="code" href="classNL3D_1_1CTextureDrvShare.html#m0">00082</a> <a class="code" href="classNLMISC_1_1CSmartPtr.html">NLMISC::CSmartPtr<ITextureDrvInfos></a> <a class="code" href="classNL3D_1_1CTextureDrvShare.html#m0">DrvTexture</a>; +00083 +00084 <font class="keyword">public</font>: +<a name="l00085"></a><a class="code" href="classNL3D_1_1CTextureDrvShare.html#a0">00085</a> <a class="code" href="classNL3D_1_1CTextureDrvShare.html#a0">CTextureDrvShare</a>(IDriver *drv, <a class="code" href="namespaceNL3D.html#a247">ItTexDrvSharePtrList</a> it) {<a class="code" href="classNL3D_1_1CTextureDrvShare.html#o0">_Driver</a>= drv; <a class="code" href="classNL3D_1_1CTextureDrvShare.html#o1">_DriverIterator</a>= it;} +00086 <a class="code" href="classNL3D_1_1CTextureDrvShare.html#a1">~CTextureDrvShare</a>(); +00087 }; +00088 +00089 +00090 <font class="comment">//****************************************************************************</font> +00100 <font class="comment"></font><font class="comment">/* *** IMPORTANT ********************</font> +00101 <font class="comment"> * *** IF YOU MODIFY THE STRUCTURE OF THIS CLASS, PLEASE INCREMENT IDriver::InterfaceVersion TO INVALIDATE OLD DRIVER DLL</font> +00102 <font class="comment"> * **********************************</font> +00103 <font class="comment"> */</font> +<a name="l00104"></a><a class="code" href="classNL3D_1_1ITexture.html">00104</a> <font class="keyword">class </font>ITexture : <font class="keyword">public</font> CBitmap, <font class="keyword">public</font> NLMISC::CRefCount, <font class="keyword">public</font> NLMISC::IStreamable +00105 { +00106 <font class="keyword">public</font>: +00107 <font class="comment">// Those enums MUST be the same than in UTexture!!</font> +00108 +<a name="l00109"></a><a class="code" href="classNL3D_1_1ITexture.html#s28">00109</a> <font class="keyword">enum</font> <a class="code" href="classNL3D_1_1ITexture.html#s28">TWrapMode</a> +00110 { +00111 <a class="code" href="classNL3D_1_1ITexture.html#s28s0">Repeat</a>= 0, +00112 <a class="code" href="classNL3D_1_1ITexture.html#s28s1">Clamp</a>, +00113 +00114 <a class="code" href="classNL3D_1_1ITexture.html#s28s2">WrapModeCount</a> +00115 }; +00116 +<a name="l00117"></a><a class="code" href="classNL3D_1_1ITexture.html#s29">00117</a> <font class="keyword">enum</font> <a class="code" href="classNL3D_1_1ITexture.html#s29">TUploadFormat</a> +00118 { +00119 <a class="code" href="classNL3D_1_1ITexture.html#s29s3">Auto</a>= 0, +00120 <a class="code" href="classNL3D_1_1ITexture.html#s29s4">RGBA8888</a>, +00121 <a class="code" href="classNL3D_1_1ITexture.html#s29s5">RGBA4444</a>, +00122 <a class="code" href="classNL3D_1_1ITexture.html#s29s6">RGBA5551</a>, +00123 <a class="code" href="classNL3D_1_1ITexture.html#s29s7">RGB888</a>, +00124 <a class="code" href="classNL3D_1_1ITexture.html#s29s8">RGB565</a>, +00125 <a class="code" href="classNL3D_1_1ITexture.html#s29s9">DXTC1</a>, +00126 <a class="code" href="classNL3D_1_1ITexture.html#s29s10">DXTC1Alpha</a>, +00127 <a class="code" href="classNL3D_1_1ITexture.html#s29s11">DXTC3</a>, +00128 <a class="code" href="classNL3D_1_1ITexture.html#s29s12">DXTC5</a>, +00129 <a class="code" href="classNL3D_1_1ITexture.html#s29s13">Luminance</a>, +00130 <a class="code" href="classNL3D_1_1ITexture.html#s29s14">Alpha</a>, +00131 <a class="code" href="classNL3D_1_1ITexture.html#s29s15">AlphaLuminance</a>, +00132 <a class="code" href="classNL3D_1_1ITexture.html#s29s16">DsDt</a>, +00133 <a class="code" href="classNL3D_1_1ITexture.html#s29s17">UploadFormatCount</a> +00134 }; +00135 +00136 +<a name="l00140"></a><a class="code" href="classNL3D_1_1ITexture.html#s30">00140</a> <font class="keyword">enum</font> <a class="code" href="classNL3D_1_1ITexture.html#s30">TMagFilter</a> +00141 { +00142 <a class="code" href="classNL3D_1_1ITexture.html#s30s18">Nearest</a>=0, +00143 <a class="code" href="classNL3D_1_1ITexture.html#s30s19">Linear</a>, +00144 +00145 <a class="code" href="classNL3D_1_1ITexture.html#s30s20">MagFilterCount</a> +00146 }; +00147 +<a name="l00151"></a><a class="code" href="classNL3D_1_1ITexture.html#s31">00151</a> <font class="keyword">enum</font> <a class="code" href="classNL3D_1_1ITexture.html#s31">TMinFilter</a> +00152 { +00153 <a class="code" href="classNL3D_1_1ITexture.html#s31s21">NearestMipMapOff</a>=0, +00154 <a class="code" href="classNL3D_1_1ITexture.html#s31s22">NearestMipMapNearest</a>, +00155 <a class="code" href="classNL3D_1_1ITexture.html#s31s23">NearestMipMapLinear</a>, +00156 <a class="code" href="classNL3D_1_1ITexture.html#s31s24">LinearMipMapOff</a>, +00157 <a class="code" href="classNL3D_1_1ITexture.html#s31s25">LinearMipMapNearest</a>, +00158 <a class="code" href="classNL3D_1_1ITexture.html#s31s26">LinearMipMapLinear</a>, +00159 +00160 <a class="code" href="classNL3D_1_1ITexture.html#s31s27">MinFilterCount</a> +00161 }; +00162 +00163 +00164 <font class="keyword">public</font>: +00165 +00167 <font class="comment">// @{</font> +00169 <font class="comment"> ITexture();</font> +<a name="l00171"></a><a class="code" href="classNL3D_1_1ITexture.html#z825_1">00171</a> <font class="comment"> ITexture(const ITexture &tex) {operator=(tex);}</font> +00173 <font class="comment"> virtual ~ITexture();</font> +00175 <font class="comment"> ITexture &operator=(const ITexture &tex);</font> +00176 <font class="comment">// @}</font> +00177 +00178 +00180 +00193 <font class="comment">// @{</font> +<a name="l00194"></a><a class="code" href="classNL3D_1_1ITexture.html#z826_0">00194</a> <font class="keywordtype">void</font> <a class="code" href="classNL3D_1_1ITexture.html#z826_0">setWrapS</a>(<a class="code" href="classNL3D_1_1ITexture.html#s28">TWrapMode</a> mode) {<a class="code" href="classNL3D_1_1ITexture.html#o3">_WrapS</a>= mode;} +<a name="l00195"></a><a class="code" href="classNL3D_1_1ITexture.html#z826_1">00195</a> <font class="keywordtype">void</font> <a class="code" href="classNL3D_1_1ITexture.html#z826_1">setWrapT</a>(<a class="code" href="classNL3D_1_1ITexture.html#s28">TWrapMode</a> mode) {<a class="code" href="classNL3D_1_1ITexture.html#o4">_WrapT</a>= mode;} +<a name="l00196"></a><a class="code" href="classNL3D_1_1ITexture.html#z826_2">00196</a> <a class="code" href="classNL3D_1_1ITexture.html#s28">TWrapMode</a> <a class="code" href="classNL3D_1_1ITexture.html#z826_2">getWrapS</a>()<font class="keyword"> const </font>{<font class="keywordflow">return</font> <a class="code" href="classNL3D_1_1ITexture.html#o3">_WrapS</a>;} +<a name="l00197"></a><a class="code" href="classNL3D_1_1ITexture.html#z826_3">00197</a> <a class="code" href="classNL3D_1_1ITexture.html#s28">TWrapMode</a> <a class="code" href="classNL3D_1_1ITexture.html#z826_3">getWrapT</a>()<font class="keyword"> const </font>{<font class="keywordflow">return</font> <a class="code" href="classNL3D_1_1ITexture.html#o4">_WrapT</a>;} +00203 <font class="keywordtype">void</font> <a class="code" href="classNL3D_1_1ITexture.html#z826_4">setUploadFormat</a>(<a class="code" href="classNL3D_1_1ITexture.html#s29">TUploadFormat</a> pf); +<a name="l00204"></a><a class="code" href="classNL3D_1_1ITexture.html#z826_5">00204</a> <a class="code" href="classNL3D_1_1ITexture.html#s29">TUploadFormat</a> <a class="code" href="classNL3D_1_1ITexture.html#z826_5">getUploadFormat</a>()<font class="keyword"> const </font>{<font class="keywordflow">return</font> <a class="code" href="classNL3D_1_1ITexture.html#o2">_UploadFormat</a>;} +00205 <font class="keyword">virtual</font> <font class="keywordtype">void</font> <a class="code" href="classNL3D_1_1ITexture.html#z826_6">setFilterMode</a>(<a class="code" href="classNL3D_1_1ITexture.html#s30">TMagFilter</a> magf, <a class="code" href="classNL3D_1_1ITexture.html#s31">TMinFilter</a> minf); +<a name="l00206"></a><a class="code" href="classNL3D_1_1ITexture.html#z826_7">00206</a> <a class="code" href="classNL3D_1_1ITexture.html#s30">TMagFilter</a> <a class="code" href="classNL3D_1_1ITexture.html#z826_7">getMagFilter</a>()<font class="keyword"> const </font>{<font class="keywordflow">return</font> <a class="code" href="classNL3D_1_1ITexture.html#o6">_MagFilter</a>;} +<a name="l00207"></a><a class="code" href="classNL3D_1_1ITexture.html#z826_8">00207</a> <a class="code" href="classNL3D_1_1ITexture.html#s31">TMinFilter</a> <a class="code" href="classNL3D_1_1ITexture.html#z826_8">getMinFilter</a>()<font class="keyword"> const </font>{<font class="keywordflow">return</font> <a class="code" href="classNL3D_1_1ITexture.html#o5">_MinFilter</a>;} +<a name="l00208"></a><a class="code" href="classNL3D_1_1ITexture.html#z826_9">00208</a> <font class="keywordtype">bool</font> <a class="code" href="classNL3D_1_1ITexture.html#z826_9">mipMapOff</a>()<font class="keyword"> const </font>{<font class="keywordflow">return</font> <a class="code" href="classNL3D_1_1ITexture.html#o5">_MinFilter</a>==<a class="code" href="classNL3D_1_1ITexture.html#s31s21">NearestMipMapOff</a> || <a class="code" href="classNL3D_1_1ITexture.html#o5">_MinFilter</a>==<a class="code" href="classNL3D_1_1ITexture.html#s31s24">LinearMipMapOff</a>;} +<a name="l00209"></a><a class="code" href="classNL3D_1_1ITexture.html#z826_10">00209</a> <font class="keywordtype">bool</font> <a class="code" href="classNL3D_1_1ITexture.html#z826_10">mipMapOn</a>()<font class="keyword"> const </font>{<font class="keywordflow">return</font> !<a class="code" href="classNL3D_1_1ITexture.html#z826_9">mipMapOff</a>();} +00210 <font class="comment">// @}</font> +00211 +00212 +<a name="l00219"></a><a class="code" href="classNL3D_1_1ITexture.html#a0">00219</a> <font class="keywordtype">void</font> <a class="code" href="classNL3D_1_1ITexture.html#a0">touch</a>() +00220 { +00221 <a class="code" href="classNL3D_1_1ITexture.html#m1">_ListInvalidRect</a>.clear (); +00222 <a class="code" href="classNL3D_1_1ITexture.html#n0">_Touched</a>=<font class="keyword">true</font>; +00223 <a class="code" href="classNL3D_1_1ITexture.html#o0">_GoodGenerate</a>= <font class="keyword">false</font>; +00224 } +00225 +<a name="l00234"></a><a class="code" href="classNL3D_1_1ITexture.html#a1">00234</a> <font class="keywordtype">void</font> <a class="code" href="classNL3D_1_1ITexture.html#a1">touchRect</a>(<font class="keyword">const</font> <a class="code" href="classNLMISC_1_1CRect.html">NLMISC::CRect</a>& rect) +00235 { +00236 <font class="comment">// The texture must not support sharing....</font> +00237 <a class="code" href="debug_8h.html#a6">nlassert</a>(!<a class="code" href="classNL3D_1_1ITexture.html#a7">supportSharing</a>()); +00238 <font class="comment">// Don't invalidate the rectangle if the full texture is already invalidated.</font> +00239 <font class="keywordflow">if</font> (!<a class="code" href="classNL3D_1_1ITexture.html#a16">isAllInvalidated</a> ()) +00240 { +00241 <font class="comment">// Add the region to invalidate list</font> +00242 <a class="code" href="classNL3D_1_1ITexture.html#m1">_ListInvalidRect</a>.push_back (rect); +00243 <font class="comment">// Touch flag</font> +00244 <a class="code" href="classNL3D_1_1ITexture.html#n0">_Touched</a>=<font class="keyword">true</font>; +00245 } +00246 +00247 <a class="code" href="classNL3D_1_1ITexture.html#o0">_GoodGenerate</a>= <font class="keyword">false</font>; +00248 } +00249 +00250 +<a name="l00259"></a><a class="code" href="classNL3D_1_1ITexture.html#a2">00259</a> <font class="keywordtype">bool</font> <a class="code" href="classNL3D_1_1ITexture.html#a2">getReleasable</a>()<font class="keyword"> const </font>{ <font class="keywordflow">return</font> <a class="code" href="classNL3D_1_1ITexture.html#o1">_Releasable</a>; } +00260 +00261 +<a name="l00270"></a><a class="code" href="classNL3D_1_1ITexture.html#a3">00270</a> <font class="keywordtype">void</font> <a class="code" href="classNL3D_1_1ITexture.html#a3">setReleasable</a>(<font class="keywordtype">bool</font> <a class="code" href="driver__opengl__extension__def_8h.html#a385">r</a>) { <a class="code" href="classNL3D_1_1ITexture.html#o1">_Releasable</a> = <a class="code" href="driver__opengl__extension__def_8h.html#a385">r</a>; } +00271 +<a name="l00295"></a><a class="code" href="classNL3D_1_1ITexture.html#a4">00295</a> <font class="keywordtype">void</font> <a class="code" href="classNL3D_1_1ITexture.html#a4">generate</a>() +00296 { +00297 <font class="keywordflow">if</font>(!<a class="code" href="classNL3D_1_1ITexture.html#o0">_GoodGenerate</a>) +00298 { +00299 <a class="code" href="classNL3D_1_1ITexture.html#b0">doGenerate</a>(); +00300 <a class="code" href="classNL3D_1_1ITexture.html#o0">_GoodGenerate</a>=<font class="keyword">true</font>; +00301 } +00302 } +00303 +<a name="l00308"></a><a class="code" href="classNL3D_1_1ITexture.html#a5">00308</a> <font class="keywordtype">void</font> <a class="code" href="classNL3D_1_1ITexture.html#a5">validateGenerateFlag</a>() {<a class="code" href="classNL3D_1_1ITexture.html#o0">_GoodGenerate</a>=<font class="keyword">true</font>;} +00309 +<a name="l00313"></a><a class="code" href="classNL3D_1_1ITexture.html#a6">00313</a> <font class="keyword">virtual</font> <font class="keywordtype">void</font> <a class="code" href="classNL3D_1_1ITexture.html#a6">release</a>() { <a class="code" href="classNLMISC_1_1CBitmap.html#a13">reset</a>(); <a class="code" href="classNL3D_1_1ITexture.html#o0">_GoodGenerate</a>= <font class="keyword">false</font>; } +00314 +<a name="l00318"></a><a class="code" href="classNL3D_1_1ITexture.html#a7">00318</a> <font class="keyword">virtual</font> <font class="keywordtype">bool</font> <a class="code" href="classNL3D_1_1ITexture.html#a7">supportSharing</a>()<font class="keyword"> const </font>{<font class="keywordflow">return</font> <font class="keyword">false</font>;} +00319 +<a name="l00324"></a><a class="code" href="classNL3D_1_1ITexture.html#a8">00324</a> <font class="keyword">virtual</font> std::string <a class="code" href="classNL3D_1_1ITexture.html#a8">getShareName</a>()<font class="keyword"> const </font>{<font class="keywordflow">return</font> std::string();} +00325 +<a name="l00329"></a><a class="code" href="classNL3D_1_1ITexture.html#a9">00329</a> <font class="keywordtype">bool</font> <a class="code" href="classNL3D_1_1ITexture.html#a9">setupedIntoDriver</a>()<font class="keyword"> const </font> +00330 <font class="keyword"> </font>{ +00331 <font class="keywordflow">return</font> <a class="code" href="classNL3D_1_1ITexture.html#m0">TextureDrvShare</a>!=NULL; +00332 } +00333 +00335 <font class="keywordtype">void</font> <a class="code" href="classNL3D_1_1ITexture.html#a10">releaseDriverSetup</a>(); +00336 +<a name="l00338"></a><a class="code" href="classNL3D_1_1ITexture.html#a11">00338</a> <font class="keyword">virtual</font> <font class="keywordtype">bool</font> <a class="code" href="classNL3D_1_1ITexture.html#a11">allowDegradation</a>()<font class="keyword"> const </font>{ <font class="keywordflow">return</font> <font class="keyword">false</font>; } +00339 +00341 <font class="keyword">virtual</font> <font class="keywordtype">void</font> <a class="code" href="classNL3D_1_1ITexture.html#a12">serial</a>(<a class="code" href="classNLMISC_1_1IStream.html">NLMISC::IStream</a> &f) <font class="keywordflow">throw</font>(NLMISC::EStream); +00342 +<a name="l00346"></a><a class="code" href="classNL3D_1_1ITexture.html#a13">00346</a> <font class="keyword">virtual</font> <font class="keywordtype">void</font> <a class="code" href="classNL3D_1_1ITexture.html#a13">selectTexture</a>(uint <a class="code" href="driver__opengl__extension__def_8h.html#a358">index</a>) {} +00347 +<a name="l00349"></a><a class="code" href="classNL3D_1_1ITexture.html#a14">00349</a> <font class="keyword">virtual</font> <font class="keywordtype">bool</font> <a class="code" href="classNL3D_1_1ITexture.html#a14">isSelectable</a>()<font class="keyword"> const </font>{ <font class="keywordflow">return</font> <font class="keyword">false</font>; } +00350 +<a name="l00354"></a><a class="code" href="classNL3D_1_1ITexture.html#a15">00354</a> <font class="keyword">virtual</font> <a class="code" href="classNL3D_1_1ITexture.html#z825_0">ITexture</a> *<a class="code" href="classNL3D_1_1ITexture.html#a15">buildNonSelectableVersion</a>(uint <a class="code" href="driver__opengl__extension__def_8h.html#a358">index</a>) { <font class="keywordflow">return</font> <font class="keyword">this</font>; } +00355 +00356 +00357 +00358 +00360 <font class="comment">// @{</font> +<a name="l00362"></a><a class="code" href="classNL3D_1_1ITexture.html#z827_0">00362</a> <font class="comment"> virtual bool isTextureCube() const { return false; } </font> +00363 <font class="comment">// @}</font> +00364 +00365 <font class="comment">//****************************</font> +00366 <font class="comment">// Private part.</font> +00367 <font class="keyword">protected</font>: +00368 <font class="comment">// Derived texture should set it to true when they are updated.</font> +<a name="l00369"></a><a class="code" href="classNL3D_1_1ITexture.html#n0">00369</a> <font class="keywordtype">bool</font> <a class="code" href="classNL3D_1_1ITexture.html#n0">_Touched</a>; +00370 +00371 +00382 <font class="keyword">virtual</font> <font class="keywordtype">void</font> <a class="code" href="classNL3D_1_1ITexture.html#b0">doGenerate</a>() = 0; +00383 +00384 +00385 <font class="keyword">private</font>: +<a name="l00386"></a><a class="code" href="classNL3D_1_1ITexture.html#o0">00386</a> <font class="keywordtype">bool</font> <a class="code" href="classNL3D_1_1ITexture.html#o0">_GoodGenerate</a>; +<a name="l00387"></a><a class="code" href="classNL3D_1_1ITexture.html#o1">00387</a> <font class="keywordtype">bool</font> <a class="code" href="classNL3D_1_1ITexture.html#o1">_Releasable</a>; +<a name="l00388"></a><a class="code" href="classNL3D_1_1ITexture.html#o2">00388</a> <a class="code" href="classNL3D_1_1ITexture.html#s29">TUploadFormat</a> <a class="code" href="classNL3D_1_1ITexture.html#o2">_UploadFormat</a>; +<a name="l00389"></a><a class="code" href="classNL3D_1_1ITexture.html#o3">00389</a> <a class="code" href="classNL3D_1_1ITexture.html#s28">TWrapMode</a> <a class="code" href="classNL3D_1_1ITexture.html#o3">_WrapS</a>; +<a name="l00390"></a><a class="code" href="classNL3D_1_1ITexture.html#o4">00390</a> <a class="code" href="classNL3D_1_1ITexture.html#s28">TWrapMode</a> <a class="code" href="classNL3D_1_1ITexture.html#o4">_WrapT</a>; +<a name="l00391"></a><a class="code" href="classNL3D_1_1ITexture.html#o5">00391</a> <a class="code" href="classNL3D_1_1ITexture.html#s31">TMinFilter</a> <a class="code" href="classNL3D_1_1ITexture.html#o5">_MinFilter</a>; +<a name="l00392"></a><a class="code" href="classNL3D_1_1ITexture.html#o6">00392</a> <a class="code" href="classNL3D_1_1ITexture.html#s30">TMagFilter</a> <a class="code" href="classNL3D_1_1ITexture.html#o6">_MagFilter</a>; +00393 +00394 <font class="keyword">public</font>: +00395 <font class="comment">// Private Part!!!. For Driver Only.</font> +00396 <font class="comment">//==================================</font> +00397 +<a name="l00398"></a><a class="code" href="classNL3D_1_1ITexture.html#m0">00398</a> <a class="code" href="classNLMISC_1_1CRefPtr.html">NLMISC::CRefPtr<CTextureDrvShare></a> <a class="code" href="classNL3D_1_1ITexture.html#m0">TextureDrvShare</a>; +<a name="l00404"></a><a class="code" href="classNL3D_1_1ITexture.html#m1">00404</a> <a class="code" href="classstd_1_1list.html">std::list<NLMISC::CRect></a> <a class="code" href="classNL3D_1_1ITexture.html#m1">_ListInvalidRect</a>; +00405 +00406 +<a name="l00410"></a><a class="code" href="classNL3D_1_1ITexture.html#a16">00410</a> <font class="keywordtype">bool</font> <a class="code" href="classNL3D_1_1ITexture.html#a16">isAllInvalidated</a> ()<font class="keyword"> const</font> +00411 <font class="keyword"> </font>{ +00412 <font class="keywordflow">return</font> <a class="code" href="classNL3D_1_1ITexture.html#n0">_Touched</a>&&(_ListInvalidRect.begin()==_ListInvalidRect.end()); +00413 } +00414 +<a name="l00420"></a><a class="code" href="classNL3D_1_1ITexture.html#a17">00420</a> <font class="keywordtype">bool</font> <a class="code" href="classNL3D_1_1ITexture.html#a17">touched</a> (<font class="keywordtype">void</font>) +00421 { +00422 <font class="keywordflow">return</font> <a class="code" href="classNL3D_1_1ITexture.html#n0">_Touched</a>; +00423 } +00424 +00425 <font class="comment">/*</font> +00426 <font class="comment"> * Clear the touched flag and the invalid rectangle list</font> +00427 <font class="comment"> *</font> +00428 <font class="comment"> * \see isAllInvalidated(), generate(), touch(), touched(), touchRect(), _ListInvalidRect</font> +00429 <font class="comment"> */</font> +<a name="l00430"></a><a class="code" href="classNL3D_1_1ITexture.html#a18">00430</a> <font class="keywordtype">void</font> <a class="code" href="classNL3D_1_1ITexture.html#a18">clearTouched</a>(<font class="keywordtype">void</font>) +00431 { +00432 <a class="code" href="classNL3D_1_1ITexture.html#n0">_Touched</a>=<font class="keyword">false</font>; +00433 _ListInvalidRect.clear(); +00434 } +00435 +00436 +00437 +00438 }; +00439 +00440 +00441 +00442 } <font class="comment">// NL3D</font> +00443 +00444 +00445 <font class="preprocessor">#endif // NL_TEXTURE_H</font> +00446 <font class="preprocessor"></font> +00447 <font class="comment">/* End of texture.h */</font> +</pre></div> + +<!-- footer --> +<BR><FONT Size=+5> </FONT> +</TD> +<TD WIDTH=15><IMG SRC=http://www.nevrax.org/inc/img/pixel.gif WIDTH=15 HEIGHT=15 BORDER=0 ALT=""></TD> +</TR> +</TABLE> +</BODY> +</HTML> |