1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
2<html>
3
4<head>
5<META http-equiv="Content-Type" content="text/html; charset=windows-1252">
6<META name="GENERATOR" content="IBM WebSphere Studio Homepage Builder Version 6.5.0.0 for Windows">
7<META http-equiv="Content-Style-Type" content="text/css">
8<LINK rel="stylesheet" type="text/css" href="../../CSS/revolution.css">
9<title>GXReadClksPerVtx</title>
10</head>
11
12<body>
13
14<h1 align="left">GXReadClksPerVtx</h1>
15
16<h2>Syntax</h2>
17<dl><dd><pre class="construction">
18#include &lt;revolution/gx.h&gt;
19
20u32 GXReadClksPerVtx( void );
21</pre></dd></dl>
22
23<h2>Arguments</h2>
24<p>None.</p>
25
26<h2>Return Values</h2>
27<p>The clock number for each vertex needed for conversion and writing processes.</p>
28
29<H2>Description</H2>
30<P>The graphics processor (GP) can count many internal events that give detailed information on performance.&nbsp;This function returns the minimum number of clocks the Transform and Lighting Engine (also called the XF) will take to process a vertex. This number is returned from the GP based on the current texture coordinate generation, lighting, and vertex state. Make sure that all such states have been flushed from the GP before calling <a href="GXReadClksPerVtx.html"><code>GXReadClksPerVtx</code></a>. Also, the value returned <em>does not</em> take into account the time required for input or output.&nbsp;In certain configurations, this time may limit the peak geometry rate.&nbsp;The <A href="VertexPerformance.html">Vertex Performance spreadsheet</A> provided <em>does</em> take input and output data into account and thus generates more accurate results. The <CODE>GXReadClksPerVtx</CODE> function calls the <A href="../Management/GXFlush.html"><CODE>GXFlush</CODE></A> function. Thus, there is no need to explicitly call <A href="../Management/GXFlush.html"><CODE>GXFlush</CODE></A> after you have executed <CODE>GXReadClksPerVtx</CODE>.</P>
31
32<H3>Example</H3>
33<DL><DD><CODE>u32 cpv;<BR> <BR> // Set Render State</CODE></DD></DL>
34<DL><DD><CODE>// wait until objects are rendered<BR> GXSetDrawSync(0xbeef);<BR> while (0xbeef != GXReadDrawSync())<BR> &nbsp;&nbsp;&nbsp; ;<BR> <BR> cpv = GXReadClksPerVtx();&nbsp;&nbsp; // returns request counter<BR> <BR> OSReport(&quot;Number of clocks per vtx:&nbsp; %d\n&quot;, cpv);</CODE></DD></DL>
35
36<P>This function reads CPU accessible registers in the GP and so should not be called in a display list.</P>
37
38<h2>See Also</h2>
39<P class="reference">
40<a href="GXReadMemMetric.html">GXReadMemMetric</a>,
41<a href="GXReadVCacheMetric.html">GXReadVCacheMetric</a>,
42<a href="GXReadPixMetric.html">GXReadPixMetric</a>,
43<a href="GXReadGPMetric.html">GXReadGPMetric</a>,
44<a href="GXReadGP0Metric.html">GXReadGP0Metric</a>,
45<a href="GXReadGP1Metric.html">GXReadGP1Metric</a>
46</p>
47
48<H2>Revision History</H2>
49<P>
502008/05/12 Mentioned that <CODE>GXFlush</CODE> is included.<br>2006/03/01 Initial version.<br>
51</P>
52
53<hr><p>CONFIDENTIAL</p></body>
54</html>