1<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 2<html xml:lang="en-US" lang="en-US" xmlns="http://www.w3.org/1999/xhtml"> 3 <head> 4 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> 5 <meta http-equiv="Content-Style-Type" content="text/css" /> 6 <link rel="stylesheet" href="../../../../css/manpage.css" type="text/css" /> 7<title>CalculateMatrices</title> 8 </head> 9 <body> 10<h1><CODE><a href="../../../../nn/Overview.html">nn</a>::<a href="../../../../nn/ulcd/Overview.html">ulcd</a>::<a href="../../../../nn/ulcd/CTR/Overview.html">CTR</a>::<a href="../../../../nn/ulcd/CTR/StereoCamera/Overview.html">StereoCamera</a>::CalculateMatrices</CODE> Member Function</h1> 11<h2>Syntax</h2> 12 <div class="section"> 13 <pre class="definition">#include <nn/ulcd.h> 14 15void CalculateMatrices( 16 <a href="../../../../nn/math/Matrix44.html">nn::math::Matrix44</a> * projL, 17 <a href="../../../../nn/math/Matrix34.html">nn::math::Matrix34</a> * viewL, 18 <a href="../../../../nn/math/Matrix44.html">nn::math::Matrix44</a> * projR, 19 <a href="../../../../nn/math/Matrix34.html">nn::math::Matrix34</a> * viewR, 20 const <a href="../../../../nn_types/f32.html">f32</a> depthLevel, 21 const <a href="../../../../nn_types/f32.html">f32</a> factor, 22 const <a href="../../../../nn/math/PivotDirection.html">nn::math::PivotDirection</a> pivot = nn::math::PIVOT_UPSIDE_TO_TOP 23); 24</pre> 25 </div> 26<h2>Parameters</h2> 27 <div class="section"> 28 <table class="arguments"> 29 <thead> 30 <tr> 31 <td width="15" /> 32<th>Name</th> 33<td>Description</td> 34 </tr> 35 </thead> 36 <tr> 37<td>out</td> 38<th>projL</th> 39<td>Location where the calculated results for the left projection matrix are stored.</td> 40 </tr> 41 <tr> 42<td>out</td> 43<th>viewL</th> 44<td>Location where the calculated results for the left view matrix are stored.</td> 45 </tr> 46 <tr> 47<td>out</td> 48<th>projR</th> 49<td>Location where the calculated results for the right projection matrix are stored.</td> 50 </tr> 51 <tr> 52<td>out</td> 53<th>viewR</th> 54<td>Location where the calculated results for the right view matrix are stored.</td> 55 </tr> 56 <tr> 57<td>in</td> 58<th>depthLevel</th> 59<td>Distance from the camera to the desired location on the LCD (the base plane).</td> 60 </tr> 61 <tr> 62<td>in</td> 63<th>factor</th> 64<td>Depth adjustment factor. (A value of <CODE>0</CODE> indicates no parallax. A value of <CODE>1</CODE> indicates standard parallax.)</td> 65 </tr> 66 <tr> 67<td>in</td> 68<th>pivot</th> 69<td>Upward direction of the camera within the frame of the upper screen (used for rotation).</td> 70 </tr> </table> 71 </div> 72<h2>Return Values</h2> 73 <div class="section"> 74None. 75 </div> 76<h2>Description</h2> 77 <div class="section"> 78<p>Calculates the view matrices and projection matrices for the left and right cameras, using the application priority method.</p><!-- write here --><P>It performs matrix calculation based on the base camera specified by the application. The calculations performed by this function preserve the original view angle, so use of this function is recommended if you want to preserve the effect given by cameras that you have adjusted a certain way. 79</P><P>Once the projection matrix has been calculated and output, the upward direction of the camera will be the direction specified for the <SPAN class="argument">pivot</SPAN> argument. If <SPAN class="argument">pivot</SPAN> is set to <CODE>nn::math::PIVOT_NONE</CODE>, no rotation is applied. If an invalid value is specified for the <SPAN class="argument">pivot</SPAN> argument, the function halts on an assertion. The value <CODE>nn::math::PIVOT_UPSIDE_TO_TOP</CODE> is specified by default. 80</P><P>This function stops at an assertion if it is called before the <CODE>Initialize</CODE> function has been called on an instance of the <CODE>StereoCamera</CODE> class. 81 </P></div> 82<h2>Revision History</h2> 83 <div class="section"> 84 <dl class="history"> 85 <dt>2010/09/13</dt> 86<dd>Noted that execution stops at an assertion prior to initialization. 87 </dd> 88 <dt>2010/04/02</dt> 89<dd>Initial version.<br /> 90 </dd> 91 </dl> 92 </div> 93 <hr><p>CONFIDENTIAL</p></body> 94</html>