source: OGRE/trunk/ogrenew/Docs/api/html/classOgre_1_1HardwareOcclusionQuery.html @ 692

Revision 692, 18.3 KB checked in by mattausch, 19 years ago (diff)

adding ogre 1.2 and dependencies

Line 
1<html>
2<head>
3<title>Ogre::HardwareOcclusionQuery class Reference - OGRE Documentation</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
4<link type="text/css" rel="stylesheet" href="style.css">
5</head>
6
7<body>
8<!-- Generated by Doxygen 1.3.6 -->
9<div class="qindex"><a class="qindex" href="index.html">Main&nbsp;Page</a> | <a class="qindex" href="namespaces.html">Namespace List</a> | <a class="qindex" href="hierarchy.html">Class&nbsp;Hierarchy</a> | <a class="qindex" href="classes.html">Alphabetical&nbsp;List</a> | <a class="qindex" href="annotated.html">Class&nbsp;List</a> | <a class="qindex" href="files.html">File&nbsp;List</a> | <a class="qindex" href="namespacemembers.html">Namespace&nbsp;Members</a> | <a class="qindex" href="functions.html">Class&nbsp;Members</a> | <a class="qindex" href="globals.html">File&nbsp;Members</a> | <a class="qindex" href="pages.html">Related&nbsp;Pages</a></div>
10<h1>Ogre::HardwareOcclusionQuery Class Reference</h1>This is a abstract class that that provides the interface for the query class for hardware occlusion. 
11<a href="#_details">More...</a>
12<p>
13<code>#include &lt;<a class="el" href="OgreHardwareOcclusionQuery_8h-source.html">OgreHardwareOcclusionQuery.h</a>&gt;</code>
14<p>
15<p>Inheritance diagram for Ogre::HardwareOcclusionQuery:
16<p><center><img src="classOgre_1_1HardwareOcclusionQuery.png" usemap="#Ogre::HardwareOcclusionQuery_map" border="0" alt=""></center>
17<map name="Ogre::HardwareOcclusionQuery_map">
18<area href="classOgre_1_1D3D9HardwareOcclusionQuery.html" alt="Ogre::D3D9HardwareOcclusionQuery" shape="rect" coords="0,56,228,80">
19<area href="classOgre_1_1GLHardwareOcclusionQuery.html" alt="Ogre::GLHardwareOcclusionQuery" shape="rect" coords="238,56,466,80">
20</map>
21<a href="classOgre_1_1HardwareOcclusionQuery-members.html">List of all members.</a><table border=0 cellpadding=0 cellspacing=0>
22<tr><td></td></tr>
23<tr><td colspan=2><br><h2>Public Member Functions</h2></td></tr>
24<tr><td class="memItemLeft" nowrap align=right valign=top>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classOgre_1_1HardwareOcclusionQuery.html#Ogre_1_1HardwareOcclusionQuerya0">HardwareOcclusionQuery</a> ()</td></tr>
25
26<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Default object constructor.  <a href="#Ogre_1_1HardwareOcclusionQuerya0"></a><br><br></td></tr>
27<tr><td class="memItemLeft" nowrap align=right valign=top>virtual&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classOgre_1_1HardwareOcclusionQuery.html#Ogre_1_1HardwareOcclusionQuerya1">~HardwareOcclusionQuery</a> ()</td></tr>
28
29<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Object destructor.  <a href="#Ogre_1_1HardwareOcclusionQuerya1"></a><br><br></td></tr>
30<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classOgre_1_1HardwareOcclusionQuery.html#Ogre_1_1HardwareOcclusionQuerya2">beginOcclusionQuery</a> ()=0</td></tr>
31
32<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Starts the hardware occlusion query  Simple usage: Create one or more OcclusionQuery object one per outstanding query or one per tested object OcclusionQuery* m_pOcclusionQuery; createOcclusionQuery( &amp;m_pOcclusionQuery ); In the rendering loop: Draw all occluders m_pOcclusionQuery-&gt;startOcclusionQuery(); Draw the polygons to be tested m_pOcclusionQuery-&gt;<a class="el" href="classOgre_1_1HardwareOcclusionQuery.html#Ogre_1_1HardwareOcclusionQuerya3">endOcclusionQuery()</a>;.  <a href="#Ogre_1_1HardwareOcclusionQuerya2"></a><br><br></td></tr>
33<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classOgre_1_1HardwareOcclusionQuery.html#Ogre_1_1HardwareOcclusionQuerya3">endOcclusionQuery</a> ()=0</td></tr>
34
35<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Ends the hardware occlusion test.  <a href="#Ogre_1_1HardwareOcclusionQuerya3"></a><br><br></td></tr>
36<tr><td class="memItemLeft" nowrap align=right valign=top>virtual bool&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classOgre_1_1HardwareOcclusionQuery.html#Ogre_1_1HardwareOcclusionQuerya4">pullOcclusionQuery</a> (unsigned int *NumOfFragments)=0</td></tr>
37
38<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Pulls the hardware occlusion query too see if there is a result.  <a href="#Ogre_1_1HardwareOcclusionQuerya4"></a><br><br></td></tr>
39<tr><td class="memItemLeft" nowrap align=right valign=top>unsigned int&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classOgre_1_1HardwareOcclusionQuery.html#Ogre_1_1HardwareOcclusionQuerya5">getLastQuerysPixelcount</a> () const </td></tr>
40
41<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Let's you get the last pixel count with out doing the hardware occlusion test.  <a href="#Ogre_1_1HardwareOcclusionQuerya5"></a><br><br></td></tr>
42<tr><td class="memItemLeft" nowrap align=right valign=top>virtual bool&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classOgre_1_1HardwareOcclusionQuery.html#Ogre_1_1HardwareOcclusionQuerya6">HardwareOcclusionQuery::isStillOutstanding</a> (void)=0</td></tr>
43
44<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Lets you know when query is done, or still be processed by the Hardware.  <a href="#Ogre_1_1HardwareOcclusionQuerya6"></a><br><br></td></tr>
45<tr><td colspan=2><br><h2>Protected Attributes</h2></td></tr>
46<tr><td class="memItemLeft" nowrap align=right valign=top>unsigned int&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classOgre_1_1HardwareOcclusionQuery.html#Ogre_1_1HardwareOcclusionQueryp0">mPixelCount</a></td></tr>
47
48<tr><td class="memItemLeft" nowrap align=right valign=top>bool&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classOgre_1_1HardwareOcclusionQuery.html#Ogre_1_1HardwareOcclusionQueryp1">mIsQueryResultStillOutstanding</a></td></tr>
49
50</table>
51<hr><a name="_details"></a><h2>Detailed Description</h2>
52This is a abstract class that that provides the interface for the query class for hardware occlusion.
53<p>
54<dl compact><dt><b>Author:</b></dt><dd>Lee Sandberg Updated on 13/8/2005 by Tuan Kuranes email: <a href="mailto:tuan.kuranes@free.fr">tuan.kuranes@free.fr</a> </dd></dl>
55
56<p>
57
58<p>
59Definition at line <a class="el" href="OgreHardwareOcclusionQuery_8h-source.html#l00042">42</a> of file <a class="el" href="OgreHardwareOcclusionQuery_8h-source.html">OgreHardwareOcclusionQuery.h</a>.<hr><h2>Constructor &amp; Destructor Documentation</h2>
60<a class="anchor" name="Ogre_1_1HardwareOcclusionQuerya0" doxytag="Ogre::HardwareOcclusionQuery::HardwareOcclusionQuery" ></a><p>
61<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
62  <tr>
63    <td class="mdRow">
64      <table cellpadding="0" cellspacing="0" border="0">
65        <tr>
66          <td class="md" nowrap valign="top"> Ogre::HardwareOcclusionQuery::HardwareOcclusionQuery </td>
67          <td class="md" valign="top">(&nbsp;</td>
68          <td class="mdname1" valign="top" nowrap>          </td>
69          <td class="md" valign="top">&nbsp;)&nbsp;</td>
70          <td class="md" nowrap></td>
71        </tr>
72
73      </table>
74    </td>
75  </tr>
76</table>
77<table cellspacing=5 cellpadding=0 border=0>
78  <tr>
79    <td>
80      &nbsp;
81    </td>
82    <td>
83
84<p>
85Default object constructor.
86<p>
87    </td>
88  </tr>
89</table>
90<a class="anchor" name="Ogre_1_1HardwareOcclusionQuerya1" doxytag="Ogre::HardwareOcclusionQuery::~HardwareOcclusionQuery" ></a><p>
91<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
92  <tr>
93    <td class="mdRow">
94      <table cellpadding="0" cellspacing="0" border="0">
95        <tr>
96          <td class="md" nowrap valign="top"> virtual Ogre::HardwareOcclusionQuery::~<a class="el" href="classOgre_1_1HardwareOcclusionQuery.html">HardwareOcclusionQuery</a> </td>
97          <td class="md" valign="top">(&nbsp;</td>
98          <td class="mdname1" valign="top" nowrap>          </td>
99          <td class="md" valign="top">&nbsp;)&nbsp;</td>
100          <td class="md" nowrap><code> [virtual]</code></td>
101        </tr>
102
103      </table>
104    </td>
105  </tr>
106</table>
107<table cellspacing=5 cellpadding=0 border=0>
108  <tr>
109    <td>
110      &nbsp;
111    </td>
112    <td>
113
114<p>
115Object destructor.
116<p>
117    </td>
118  </tr>
119</table>
120<hr><h2>Member Function Documentation</h2>
121<a class="anchor" name="Ogre_1_1HardwareOcclusionQuerya2" doxytag="Ogre::HardwareOcclusionQuery::beginOcclusionQuery" ></a><p>
122<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
123  <tr>
124    <td class="mdRow">
125      <table cellpadding="0" cellspacing="0" border="0">
126        <tr>
127          <td class="md" nowrap valign="top"> virtual void Ogre::HardwareOcclusionQuery::beginOcclusionQuery </td>
128          <td class="md" valign="top">(&nbsp;</td>
129          <td class="mdname1" valign="top" nowrap>          </td>
130          <td class="md" valign="top">&nbsp;)&nbsp;</td>
131          <td class="md" nowrap><code> [pure virtual]</code></td>
132        </tr>
133
134      </table>
135    </td>
136  </tr>
137</table>
138<table cellspacing=5 cellpadding=0 border=0>
139  <tr>
140    <td>
141      &nbsp;
142    </td>
143    <td>
144
145<p>
146Starts the hardware occlusion query  Simple usage: Create one or more OcclusionQuery object one per outstanding query or one per tested object OcclusionQuery* m_pOcclusionQuery; createOcclusionQuery( &amp;m_pOcclusionQuery ); In the rendering loop: Draw all occluders m_pOcclusionQuery-&gt;startOcclusionQuery(); Draw the polygons to be tested m_pOcclusionQuery-&gt;<a class="el" href="classOgre_1_1HardwareOcclusionQuery.html#Ogre_1_1HardwareOcclusionQuerya3">endOcclusionQuery()</a>;.
147<p>
148Results must be pulled using: UINT m_uintNumberOfPixelsVisable; pullOcclusionQuery( &amp;m_dwNumberOfPixelsVisable );
149<p>
150Implemented in <a class="el" href="classOgre_1_1D3D9HardwareOcclusionQuery.html#Ogre_1_1D3D9HardwareOcclusionQuerya2">Ogre::D3D9HardwareOcclusionQuery</a>, and <a class="el" href="classOgre_1_1GLHardwareOcclusionQuery.html#Ogre_1_1GLHardwareOcclusionQuerya2">Ogre::GLHardwareOcclusionQuery</a>.    </td>
151  </tr>
152</table>
153<a class="anchor" name="Ogre_1_1HardwareOcclusionQuerya3" doxytag="Ogre::HardwareOcclusionQuery::endOcclusionQuery" ></a><p>
154<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
155  <tr>
156    <td class="mdRow">
157      <table cellpadding="0" cellspacing="0" border="0">
158        <tr>
159          <td class="md" nowrap valign="top"> virtual void Ogre::HardwareOcclusionQuery::endOcclusionQuery </td>
160          <td class="md" valign="top">(&nbsp;</td>
161          <td class="mdname1" valign="top" nowrap>          </td>
162          <td class="md" valign="top">&nbsp;)&nbsp;</td>
163          <td class="md" nowrap><code> [pure virtual]</code></td>
164        </tr>
165
166      </table>
167    </td>
168  </tr>
169</table>
170<table cellspacing=5 cellpadding=0 border=0>
171  <tr>
172    <td>
173      &nbsp;
174    </td>
175    <td>
176
177<p>
178Ends the hardware occlusion test.
179<p>
180
181<p>
182Implemented in <a class="el" href="classOgre_1_1D3D9HardwareOcclusionQuery.html#Ogre_1_1D3D9HardwareOcclusionQuerya3">Ogre::D3D9HardwareOcclusionQuery</a>, and <a class="el" href="classOgre_1_1GLHardwareOcclusionQuery.html#Ogre_1_1GLHardwareOcclusionQuerya3">Ogre::GLHardwareOcclusionQuery</a>.    </td>
183  </tr>
184</table>
185<a class="anchor" name="Ogre_1_1HardwareOcclusionQuerya5" doxytag="Ogre::HardwareOcclusionQuery::getLastQuerysPixelcount" ></a><p>
186<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
187  <tr>
188    <td class="mdRow">
189      <table cellpadding="0" cellspacing="0" border="0">
190        <tr>
191          <td class="md" nowrap valign="top"> unsigned int Ogre::HardwareOcclusionQuery::getLastQuerysPixelcount </td>
192          <td class="md" valign="top">(&nbsp;</td>
193          <td class="mdname1" valign="top" nowrap>          </td>
194          <td class="md" valign="top">&nbsp;)&nbsp;</td>
195          <td class="md" nowrap> const</td>
196        </tr>
197
198      </table>
199    </td>
200  </tr>
201</table>
202<table cellspacing=5 cellpadding=0 border=0>
203  <tr>
204    <td>
205      &nbsp;
206    </td>
207    <td>
208
209<p>
210Let's you get the last pixel count with out doing the hardware occlusion test.
211<p>
212<dl compact><dt><b>Returns:</b></dt><dd>The last fragment count from the last test. Remarks This function won't give you new values, just the old value.</dd></dl>
213
214<p>
215Definition at line <a class="el" href="OgreHardwareOcclusionQuery_8h-source.html#l00098">98</a> of file <a class="el" href="OgreHardwareOcclusionQuery_8h-source.html">OgreHardwareOcclusionQuery.h</a>.    </td>
216  </tr>
217</table>
218<a class="anchor" name="Ogre_1_1HardwareOcclusionQuerya6" doxytag="Ogre::HardwareOcclusionQuery::HardwareOcclusionQuery::isStillOutstanding" ></a><p>
219<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
220  <tr>
221    <td class="mdRow">
222      <table cellpadding="0" cellspacing="0" border="0">
223        <tr>
224          <td class="md" nowrap valign="top"> virtual bool Ogre::HardwareOcclusionQuery::HardwareOcclusionQuery::isStillOutstanding </td>
225          <td class="md" valign="top">(&nbsp;</td>
226          <td class="md" nowrap valign="top">void&nbsp;</td>
227          <td class="mdname1" valign="top" nowrap>          </td>
228          <td class="md" valign="top">&nbsp;)&nbsp;</td>
229          <td class="md" nowrap><code> [pure virtual]</code></td>
230        </tr>
231
232      </table>
233    </td>
234  </tr>
235</table>
236<table cellspacing=5 cellpadding=0 border=0>
237  <tr>
238    <td>
239      &nbsp;
240    </td>
241    <td>
242
243<p>
244Lets you know when query is done, or still be processed by the Hardware.
245<p>
246<dl compact><dt><b>Returns:</b></dt><dd>true if query isn't finished.</dd></dl>
247    </td>
248  </tr>
249</table>
250<a class="anchor" name="Ogre_1_1HardwareOcclusionQuerya4" doxytag="Ogre::HardwareOcclusionQuery::pullOcclusionQuery" ></a><p>
251<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
252  <tr>
253    <td class="mdRow">
254      <table cellpadding="0" cellspacing="0" border="0">
255        <tr>
256          <td class="md" nowrap valign="top"> virtual bool Ogre::HardwareOcclusionQuery::pullOcclusionQuery </td>
257          <td class="md" valign="top">(&nbsp;</td>
258          <td class="md" nowrap valign="top">unsigned int *&nbsp;</td>
259          <td class="mdname1" valign="top" nowrap> <em>NumOfFragments</em>          </td>
260          <td class="md" valign="top">&nbsp;)&nbsp;</td>
261          <td class="md" nowrap><code> [pure virtual]</code></td>
262        </tr>
263
264      </table>
265    </td>
266  </tr>
267</table>
268<table cellspacing=5 cellpadding=0 border=0>
269  <tr>
270    <td>
271      &nbsp;
272    </td>
273    <td>
274
275<p>
276Pulls the hardware occlusion query too see if there is a result.
277<p>
278<dl compact><dt><b>Return values:</b></dt><dd>
279  <table border="0" cellspacing="2" cellpadding="0">
280    <tr><td valign=top><em>NumOfFragments</em>&nbsp;</td><td>will get the resulting number of fragments. </td></tr>
281  </table>
282</dl>
283<dl compact><dt><b>Returns:</b></dt><dd>True if success or false if not. </dd></dl>
284
285<p>
286Implemented in <a class="el" href="classOgre_1_1D3D9HardwareOcclusionQuery.html#Ogre_1_1D3D9HardwareOcclusionQuerya4">Ogre::D3D9HardwareOcclusionQuery</a>, and <a class="el" href="classOgre_1_1GLHardwareOcclusionQuery.html#Ogre_1_1GLHardwareOcclusionQuerya4">Ogre::GLHardwareOcclusionQuery</a>.    </td>
287  </tr>
288</table>
289<hr><h2>Member Data Documentation</h2>
290<a class="anchor" name="Ogre_1_1HardwareOcclusionQueryp1" doxytag="Ogre::HardwareOcclusionQuery::mIsQueryResultStillOutstanding" ></a><p>
291<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
292  <tr>
293    <td class="mdRow">
294      <table cellpadding="0" cellspacing="0" border="0">
295        <tr>
296          <td class="md" nowrap valign="top"> bool <a class="el" href="classOgre_1_1HardwareOcclusionQuery.html#Ogre_1_1HardwareOcclusionQueryp1">Ogre::HardwareOcclusionQuery::mIsQueryResultStillOutstanding</a><code> [protected]</code>
297      </table>
298    </td>
299  </tr>
300</table>
301<table cellspacing=5 cellpadding=0 border=0>
302  <tr>
303    <td>
304      &nbsp;
305    </td>
306    <td>
307
308<p>
309
310<p>
311Definition at line <a class="el" href="OgreHardwareOcclusionQuery_8h-source.html#l00114">114</a> of file <a class="el" href="OgreHardwareOcclusionQuery_8h-source.html">OgreHardwareOcclusionQuery.h</a>.    </td>
312  </tr>
313</table>
314<a class="anchor" name="Ogre_1_1HardwareOcclusionQueryp0" doxytag="Ogre::HardwareOcclusionQuery::mPixelCount" ></a><p>
315<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
316  <tr>
317    <td class="mdRow">
318      <table cellpadding="0" cellspacing="0" border="0">
319        <tr>
320          <td class="md" nowrap valign="top"> unsigned int <a class="el" href="classOgre_1_1HardwareOcclusionQuery.html#Ogre_1_1HardwareOcclusionQueryp0">Ogre::HardwareOcclusionQuery::mPixelCount</a><code> [protected]</code>
321      </table>
322    </td>
323  </tr>
324</table>
325<table cellspacing=5 cellpadding=0 border=0>
326  <tr>
327    <td>
328      &nbsp;
329    </td>
330    <td>
331
332<p>
333
334<p>
335Definition at line <a class="el" href="OgreHardwareOcclusionQuery_8h-source.html#l00112">112</a> of file <a class="el" href="OgreHardwareOcclusionQuery_8h-source.html">OgreHardwareOcclusionQuery.h</a>.    </td>
336  </tr>
337</table>
338<hr>The documentation for this class was generated from the following file:<ul>
339<li><a class="el" href="OgreHardwareOcclusionQuery_8h-source.html">OgreHardwareOcclusionQuery.h</a></ul>
340<hr>
341<p>
342Copyright &copy; 2000-2005 by The OGRE Team<br />
343<!--Creative Commons License--><a rel="license" href="http://creativecommons.org/licenses/by-sa/2.5/"><img alt="Creative Commons License" border="0" src="http://creativecommons.org/images/public/somerights20.png"/></a><br/>
344This work is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by-sa/2.5/">Creative Commons Attribution-ShareAlike 2.5 License</a>.<br/>
345                <!--/Creative Commons License--><!-- <rdf:RDF xmlns="http://web.resource.org/cc/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
346                <Work rdf:about="">
347                        <license rdf:resource="http://creativecommons.org/licenses/by-sa/2.5/" />
348        <dc:type rdf:resource="http://purl.org/dc/dcmitype/Text" />
349                </Work>
350                <License rdf:about="http://creativecommons.org/licenses/by-sa/2.5/"><permits rdf:resource="http://web.resource.org/cc/Reproduction"/><permits rdf:resource="http://web.resource.org/cc/Distribution"/><requires rdf:resource="http://web.resource.org/cc/Notice"/><requires rdf:resource="http://web.resource.org/cc/Attribution"/><permits rdf:resource="http://web.resource.org/cc/DerivativeWorks"/><requires rdf:resource="http://web.resource.org/cc/ShareAlike"/></License></rdf:RDF> -->
351
352Last modified Sun Mar 12 14:39:12 2006
353</p>
354</body>
355</html>
Note: See TracBrowser for help on using the repository browser.