aboutsummaryrefslogtreecommitdiff
path: root/docs/doxygen/nel/a02767.html
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--docs/doxygen/nel/a02767.html1158
1 files changed, 1158 insertions, 0 deletions
diff --git a/docs/doxygen/nel/a02767.html b/docs/doxygen/nel/a02767.html
new file mode 100644
index 00000000..673419bf
--- /dev/null
+++ b/docs/doxygen/nel/a02767.html
@@ -0,0 +1,1158 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
+<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
+<title>NeL: NLSOUND::CListenerDSound class Reference</title>
+<link href="doxygen.css" rel="stylesheet" type="text/css">
+</head><body>
+<!-- Generated by Doxygen 1.3.6 -->
+<div class="qindex"> <form class="search" action="search.php" method="get">
+<a class="qindex" href="main.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">Data&nbsp;Structures</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">Data&nbsp;Fields</a> | <a class="qindex" href="globals.html">Globals</a> | <a class="qindex" href="pages.html">Related&nbsp;Pages</a> | <span class="search"><u>S</u>earch&nbsp;for&nbsp;<input class="search" type="text" name="query" value="" size="20" accesskey="s"/></span></form></div>
+<h1>NLSOUND::CListenerDSound Class Reference</h1><code>#include &lt;<a class="el" href="a05920.html">listener_dsound.h</a>&gt;</code>
+<p>
+<p>Inheritance diagram for NLSOUND::CListenerDSound:
+<p><center><img src="a02767.png" usemap="#NLSOUND::CListenerDSound_map" border="0" alt=""></center>
+<map name="NLSOUND::CListenerDSound_map">
+<area href="a03861.html" alt="NLSOUND::IListener" shape="rect" coords="0,0,177,24">
+</map>
+<hr><a name="_details"></a><h2>Detailed Description</h2>
+DirectSound listener.<p>
+For arguments as 3D vectors, use the NeL vector coordinate system (not OpenAL/OpenGL's one).<p>
+<dl compact><dt><b>Author:</b></dt><dd>Peter Hanappe, Olivier Cado <p>
+Nevrax France </dd></dl>
+<dl compact><dt><b>Date:</b></dt><dd>2002 </dd></dl>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05920.html#l00056">56</a> of file <a class="el" href="a05920.html">listener_dsound.h</a>.<table border=0 cellpadding=0 cellspacing=0>
+<tr><td></td></tr>
+<tr><td colspan=2><br><h2>Public Member Functions</h2></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSounda0">CListenerDSound</a> (LPDIRECTSOUND3DLISTENER8 dsoundListener)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Constructor. <a href="#NLSOUND_1_1CListenerDSounda0"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSounda1">commit3DChanges</a> ()</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Commit any changes to the 3D environment. <a href="#NLSOUND_1_1CListenerDSounda1"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>virtual&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSounda2">~CListenerDSound</a> ()</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Deconstructor. <a href="#NLSOUND_1_1CListenerDSounda2"></a><br><br></td></tr>
+<tr><td colspan="2"><div class="groupHeader">Listener properties</div></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>virtual float&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundz1306_0">getGain</a> () const </td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the gain. <a href="#NLSOUND_1_1CListenerDSoundz1306_0"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundz1306_1">getOrientation</a> (<a class="el" href="a03128.html">NLMISC::CVector</a> &amp;front, <a class="el" href="a03128.html">NLMISC::CVector</a> &amp;up) const </td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the orientation vectors. <a href="#NLSOUND_1_1CListenerDSoundz1306_1"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>virtual const <a class="el" href="a03128.html">NLMISC::CVector</a> &amp;&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundz1306_2">getPos</a> () const </td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundz1306_3">getVelocity</a> (<a class="el" href="a03128.html">NLMISC::CVector</a> &amp;vel) const </td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the velocity vector. <a href="#NLSOUND_1_1CListenerDSoundz1306_3"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundz1306_4">setGain</a> (float gain)</td></tr>
+
+<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundz1306_5">setOrientation</a> (const <a class="el" href="a03128.html">NLMISC::CVector</a> &amp;front, const <a class="el" href="a03128.html">NLMISC::CVector</a> &amp;up)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set the orientation vectors (3D mode only) (default: (0,1,0), (0,0,1)). <a href="#NLSOUND_1_1CListenerDSoundz1306_5"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundz1306_6">setPos</a> (const <a class="el" href="a03128.html">NLMISC::CVector</a> &amp;pos)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set the position vector (default: (0,0,0)) (3D mode only). <a href="#NLSOUND_1_1CListenerDSoundz1306_6"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundz1306_7">setVelocity</a> (const <a class="el" href="a03128.html">NLMISC::CVector</a> &amp;vel)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set the velocity vector (3D mode only) (default: (0,0,0)). <a href="#NLSOUND_1_1CListenerDSoundz1306_7"></a><br><br></td></tr>
+<tr><td colspan="2"><div class="groupHeader">Global properties</div></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>virtual float&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundz1308_0">getRolloffFactor</a> ()</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the rolloff factor. <a href="#NLSOUND_1_1CListenerDSoundz1308_0"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundz1308_1">setDopplerFactor</a> (float f)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set the doppler factor (default: 1) to exaggerate or not the doppler effect. <a href="#NLSOUND_1_1CListenerDSoundz1308_1"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundz1308_2">setEAXProperty</a> (<a class="el" href="a04558.html#a15">uint</a> prop, void *<a class="el" href="a04223.html#a658">value</a>, <a class="el" href="a04558.html#a15">uint</a> valuesize)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set any EAX listener property if EAX available. <a href="#NLSOUND_1_1CListenerDSoundz1308_2"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundz1308_3">setEnvironment</a> (<a class="el" href="a04558.html#a15">uint</a> env, float <a class="el" href="a04223.html#a587">size</a>=7.5f)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set DSPROPERTY_EAXLISTENER_ENVIRONMENT and DSPROPERTY_EAXLISTENER_ENVIRONMENTSIZE if EAX available (see EAX listener properties). <a href="#NLSOUND_1_1CListenerDSoundz1308_3"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>virtual void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundz1308_4">setRolloffFactor</a> (float f)</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set the rolloff factor (default: 1) to scale the distance attenuation effect. <a href="#NLSOUND_1_1CListenerDSoundz1308_4"></a><br><br></td></tr>
+<tr><td colspan=2><br><h2>Static Public Member Functions</h2></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a02767.html">CListenerDSound</a> *&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSounde0">instance</a> ()</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return the instance of the singleton. <a href="#NLSOUND_1_1CListenerDSounde0"></a><br><br></td></tr>
+<tr><td colspan=2><br><h2>Private Member Functions</h2></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundd0">release</a> ()</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Release all DirectSound resources. <a href="#NLSOUND_1_1CListenerDSoundd0"></a><br><br></td></tr>
+<tr><td colspan=2><br><h2>Private Attributes</h2></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>LPDIRECTSOUND3DLISTENER8&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a></td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">The DirectSound listener interface. <a href="#NLSOUND_1_1CListenerDSoundr0"></a><br><br></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a03128.html">NLMISC::CVector</a>&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundr1">_Pos</a></td></tr>
+
+<tr><td colspan=2><br><h2>Static Private Attributes</h2></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="a02767.html">CListenerDSound</a> *&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundv0">_Instance</a> = NULL</td></tr>
+
+<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">The instance of the singleton. <a href="#NLSOUND_1_1CListenerDSoundv0"></a><br><br></td></tr>
+<tr><td colspan=2><br><h2>Friends</h2></td></tr>
+<tr><td class="memItemLeft" nowrap align=right valign=top>class&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundn0">CSoundDriverDSound</a></td></tr>
+
+</table>
+<hr><h2>Constructor &amp; Destructor Documentation</h2>
+<a class="anchor" name="NLSOUND_1_1CListenerDSounda0" doxytag="NLSOUND::CListenerDSound::CListenerDSound" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> NLSOUND::CListenerDSound::CListenerDSound </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top">LPDIRECTSOUND3DLISTENER8&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>dsoundListener</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Constructor.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05919.html#l00050">50</a> of file <a class="el" href="a05919.html">listener_dsound.cpp</a>.
+<p>
+References <a class="el" href="a05919.html#l00286">setRolloffFactor()</a>.
+<p>
+<div class="fragment"><pre>00050 : <a class="code" href="a03861.html#NLSOUND_1_1IListenerb0">IListener</a>()
+00051 : <a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr1">_Pos</a>(CVector::Null)
+00052 {
+00053 <span class="preprocessor">#if EAX_AVAILABLE == 1</span>
+00054 <span class="preprocessor"></span> _EAXListener = 0;
+00055 <span class="preprocessor">#endif</span>
+00056 <span class="preprocessor"></span> <span class="keywordflow">if</span> ( <a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundv0">_Instance</a> == NULL )
+00057 {
+00058 <a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundv0">_Instance</a> = <span class="keyword">this</span>;
+00059 <a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a> = dsoundListener;
+00060 <span class="preprocessor">#if MANUAL_ROLLOFF == 1</span>
+00061 <span class="preprocessor"></span> <a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundz1308_4">setRolloffFactor</a>(DS3D_MINROLLOFFFACTOR);
+00062 <span class="preprocessor">#endif</span>
+00063 <span class="preprocessor"></span> }
+00064 <span class="keywordflow">else</span>
+00065 {
+00066 <span class="comment">//nlerror( "Listener singleton instanciated twice" );</span>
+00067 }
+00068 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLSOUND_1_1CListenerDSounda2" doxytag="NLSOUND::CListenerDSound::~CListenerDSound" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> NLSOUND::CListenerDSound::~<a class="el" href="a02767.html">CListenerDSound</a> </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Deconstructor.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05919.html#l00071">71</a> of file <a class="el" href="a05919.html">listener_dsound.cpp</a>.
+<p>
+References <a class="el" href="a05622.html#l00101">nldebug</a>, and <a class="el" href="a05919.html#l00083">release()</a>.
+<p>
+<div class="fragment"><pre>00072 {
+00073 <a class="code" href="a04199.html#a0">nldebug</a>(<span class="stringliteral">"Destroying DirectSound listener"</span>);
+00074
+00075 <a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundd0">release</a>();
+00076 <a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundv0">_Instance</a> = NULL;
+00077 }
+</pre></div> </td>
+ </tr>
+</table>
+<hr><h2>Member Function Documentation</h2>
+<a class="anchor" name="NLSOUND_1_1CListenerDSounda1" doxytag="NLSOUND::CListenerDSound::commit3DChanges" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLSOUND::CListenerDSound::commit3DChanges </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Commit any changes to the 3D environment.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05919.html#l00322">322</a> of file <a class="el" href="a05919.html">listener_dsound.cpp</a>.
+<p>
+Referenced by <a class="el" href="a06420.html#l00886">NLSOUND::CSoundDriverDSound::commit3DChanges()</a>.
+<p>
+<div class="fragment"><pre>00323 {
+00324 <span class="keywordflow">if</span> (<a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a> != NULL)
+00325 {
+00326 <a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a>-&gt;CommitDeferredSettings();
+00327 }
+00328 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLSOUND_1_1CListenerDSoundz1306_0" doxytag="NLSOUND::CListenerDSound::getGain" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> float NLSOUND::CListenerDSound::getGain </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap> const<code> [virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Get the gain.
+<p>
+
+<p>
+Implements <a class="el" href="a03861.html#NLSOUND_1_1IListenerz1316_0">NLSOUND::IListener</a>.
+<p>
+Definition at line <a class="el" href="a05919.html#l00253">253</a> of file <a class="el" href="a05919.html">listener_dsound.cpp</a>.
+<p>
+<div class="fragment"><pre>00254 {
+00255 <span class="keywordflow">return</span> CSoundDriverDSound::instance()-&gt;getGain();
+00256 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLSOUND_1_1CListenerDSoundz1306_1" doxytag="NLSOUND::CListenerDSound::getOrientation" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLSOUND::CListenerDSound::getOrientation </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a03128.html">NLMISC::CVector</a> &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>front</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a03128.html">NLMISC::CVector</a> &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>up</em></td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"> const<code> [virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Get the orientation vectors.
+<p>
+
+<p>
+Implements <a class="el" href="a03861.html#NLSOUND_1_1IListenerz1316_1">NLSOUND::IListener</a>.
+<p>
+Definition at line <a class="el" href="a05919.html#l00213">213</a> of file <a class="el" href="a05919.html">listener_dsound.cpp</a>.
+<p>
+References <a class="el" href="a05622.html#l00135">nlwarning</a>, and <a class="el" href="a06682.html#l00136">NLMISC::CVector::set()</a>.
+<p>
+<div class="fragment"><pre>00214 {
+00215 <span class="keywordflow">if</span> (<a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a> != NULL)
+00216 {
+00217 D3DVECTOR vfront, vtop;
+00218 <span class="keywordflow">if</span> (FAILED(<a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a>-&gt;GetOrientation(&amp;vfront, &amp;vtop)))
+00219 {
+00220 <a class="code" href="a04199.html#a2">nlwarning</a>(<span class="stringliteral">"GetOrientation failed"</span>);
+00221 front.<a class="code" href="a03128.html#NLMISC_1_1CVectorz2051_8">set</a>(0.0f, 0.0f, 1.0f);
+00222 up.<a class="code" href="a03128.html#NLMISC_1_1CVectorz2051_8">set</a>(0.0f, 1.0f, 0.0f);
+00223 }
+00224 <span class="keywordflow">else</span>
+00225 {
+00226 front.<a class="code" href="a03128.html#NLMISC_1_1CVectorz2051_8">set</a>(vfront.x, vfront.z, vfront.y);
+00227 up.<a class="code" href="a03128.html#NLMISC_1_1CVectorz2051_8">set</a>(vtop.x, vtop.z, vtop.y);
+00228 }
+00229 }
+00230 <span class="keywordflow">else</span>
+00231 {
+00232 front.<a class="code" href="a03128.html#NLMISC_1_1CVectorz2051_8">set</a>(0, 0, 1);
+00233 up.<a class="code" href="a03128.html#NLMISC_1_1CVectorz2051_8">set</a>(0, 1, 0);
+00234 }
+00235 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLSOUND_1_1CListenerDSoundz1306_2" doxytag="NLSOUND::CListenerDSound::getPos" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> const <a class="el" href="a03128.html">NLMISC::CVector</a> &amp; NLSOUND::CListenerDSound::getPos </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap> const<code> [virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Get the position vector. See <a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundz1306_6">setPos()</a> for details.
+<p>
+Implements <a class="el" href="a03861.html#NLSOUND_1_1IListenerz1316_2">NLSOUND::IListener</a>.
+<p>
+Definition at line <a class="el" href="a05919.html#l00125">125</a> of file <a class="el" href="a05919.html">listener_dsound.cpp</a>.
+<p>
+Referenced by <a class="el" href="a06420.html#l00886">NLSOUND::CSoundDriverDSound::commit3DChanges()</a>, and <a class="el" href="a06429.html#l00688">NLSOUND::CSourceDSound::play()</a>.
+<p>
+<div class="fragment"><pre>00126 {
+00127 <span class="keywordflow">return</span> <a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr1">_Pos</a>;
+00128 <span class="comment">/* return;</span>
+00129 <span class="comment"> // Coordinate system: conversion from NeL to OpenAL/GL:</span>
+00130 <span class="comment"> if (_Listener != NULL)</span>
+00131 <span class="comment"> {</span>
+00132 <span class="comment"> D3DVECTOR v;</span>
+00133 <span class="comment"> if (FAILED(_Listener-&gt;GetPosition(&amp;v)))</span>
+00134 <span class="comment"> {</span>
+00135 <span class="comment"> nlwarning("GetPosition failed");</span>
+00136 <span class="comment"> pos.set(0.0f, 0.0f, 0.0f);</span>
+00137 <span class="comment"> }</span>
+00138 <span class="comment"> else</span>
+00139 <span class="comment"> {</span>
+00140 <span class="comment"> pos.set(v.x, v.z, v.y);</span>
+00141 <span class="comment"> }</span>
+00142 <span class="comment"> }</span>
+00143 <span class="comment"> else</span>
+00144 <span class="comment"> {</span>
+00145 <span class="comment"> pos.set(0, 0, 0);</span>
+00146 <span class="comment"> }</span>
+00147 <span class="comment">*/</span>
+00148 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLSOUND_1_1CListenerDSoundz1308_0" doxytag="NLSOUND::CListenerDSound::getRolloffFactor" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> float NLSOUND::CListenerDSound::getRolloffFactor </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Return the rolloff factor.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05919.html#l00307">307</a> of file <a class="el" href="a05919.html">listener_dsound.cpp</a>.
+<p>
+<div class="fragment"><pre>00308 {
+00309 <span class="keywordflow">if</span> (<a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a> != NULL)
+00310 {
+00311 <span class="keywordtype">float</span> f;
+00312 <a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a>-&gt;GetRolloffFactor(&amp;f);
+00313 <span class="keywordflow">return</span> f;
+00314 }
+00315 <span class="keywordflow">else</span>
+00316 {
+00317 <span class="keywordflow">return</span> 1.0;
+00318 }
+00319 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLSOUND_1_1CListenerDSoundz1306_3" doxytag="NLSOUND::CListenerDSound::getVelocity" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLSOUND::CListenerDSound::getVelocity </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a03128.html">NLMISC::CVector</a> &amp;&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>vel</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap> const<code> [virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Get the velocity vector.
+<p>
+
+<p>
+Implements <a class="el" href="a03861.html#NLSOUND_1_1IListenerz1316_3">NLSOUND::IListener</a>.
+<p>
+Definition at line <a class="el" href="a05919.html#l00169">169</a> of file <a class="el" href="a05919.html">listener_dsound.cpp</a>.
+<p>
+References <a class="el" href="a05622.html#l00135">nlwarning</a>, <a class="el" href="a06682.html#l00136">NLMISC::CVector::set()</a>, and <a class="el" href="a05646.html#l00237">v</a>.
+<p>
+<div class="fragment"><pre>00170 {
+00171 <span class="keywordflow">if</span> (<a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a> != NULL)
+00172 {
+00173 D3DVECTOR <a class="code" href="a04223.html#a576">v</a>;
+00174 <span class="keywordflow">if</span> (FAILED(<a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a>-&gt;GetVelocity(&amp;v)))
+00175 {
+00176 <a class="code" href="a04199.html#a2">nlwarning</a>(<span class="stringliteral">"GetVelocity failed"</span>);
+00177 vel.<a class="code" href="a03128.html#NLMISC_1_1CVectorz2051_8">set</a>(0.0f, 0.0f, 0.0f);
+00178 }
+00179 <span class="keywordflow">else</span>
+00180 {
+00181 vel.<a class="code" href="a03128.html#NLMISC_1_1CVectorz2051_8">set</a>(<a class="code" href="a04223.html#a576">v</a>.x, <a class="code" href="a04223.html#a576">v</a>.z, <a class="code" href="a04223.html#a576">v</a>.y);
+00182 }
+00183 }
+00184 <span class="keywordflow">else</span>
+00185 {
+00186 vel.<a class="code" href="a03128.html#NLMISC_1_1CVectorz2051_8">set</a>(0, 0, 0);
+00187 }
+00188 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLSOUND_1_1CListenerDSounde0" doxytag="NLSOUND::CListenerDSound::instance" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a02767.html">CListenerDSound</a>* NLSOUND::CListenerDSound::instance </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [inline, static]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Return the instance of the singleton.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05920.html#l00069">69</a> of file <a class="el" href="a05920.html">listener_dsound.h</a>.
+<p>
+<div class="fragment"><pre>00069 { <span class="keywordflow">return</span> <a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundv0">_Instance</a>; }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLSOUND_1_1CListenerDSoundd0" doxytag="NLSOUND::CListenerDSound::release" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLSOUND::CListenerDSound::release </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [private]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Release all DirectSound resources.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05919.html#l00083">83</a> of file <a class="el" href="a05919.html">listener_dsound.cpp</a>.
+<p>
+Referenced by <a class="el" href="a05919.html#l00071">~CListenerDSound()</a>.
+<p>
+<div class="fragment"><pre>00084 {
+00085 <span class="keywordflow">if</span> (<a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a> != NULL)
+00086 {
+00087 <a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a>-&gt;Release();
+00088 <a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a> = NULL;
+00089 }
+00090 <span class="preprocessor">#if EAX_AVAILABLE == 1</span>
+00091 <span class="preprocessor"></span> <span class="keywordflow">if</span> (_EAXListener != NULL)
+00092 {
+00093 _EAXListener-&gt;Release();
+00094 _EAXListener = NULL;
+00095 }
+00096 <span class="preprocessor">#endif</span>
+00097 <span class="preprocessor"></span>}
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLSOUND_1_1CListenerDSoundz1308_1" doxytag="NLSOUND::CListenerDSound::setDopplerFactor" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLSOUND::CListenerDSound::setDopplerFactor </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top">float&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>f</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Set the doppler factor (default: 1) to exaggerate or not the doppler effect.
+<p>
+
+<p>
+Implements <a class="el" href="a03861.html#NLSOUND_1_1IListenerz1318_0">NLSOUND::IListener</a>.
+<p>
+Definition at line <a class="el" href="a05919.html#l00262">262</a> of file <a class="el" href="a05919.html">listener_dsound.cpp</a>.
+<p>
+References <a class="el" href="a05622.html#l00135">nlwarning</a>.
+<p>
+<div class="fragment"><pre>00263 {
+00264 <span class="keywordflow">if</span> (<a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a> != NULL)
+00265 {
+00266 <span class="keywordflow">if</span> (f &gt; DS3D_MAXDOPPLERFACTOR)
+00267 {
+00268 f = DS3D_MAXDOPPLERFACTOR;
+00269 }
+00270 <span class="keywordflow">else</span> <span class="keywordflow">if</span> (f &lt; DS3D_MINDOPPLERFACTOR)
+00271 {
+00272 f = DS3D_MINDOPPLERFACTOR;
+00273 }
+00274
+00275 <span class="keywordflow">if</span> (FAILED(<a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a>-&gt;SetDopplerFactor(f, DS3D_DEFERRED)))
+00276 {
+00277 <a class="code" href="a04199.html#a2">nlwarning</a>(<span class="stringliteral">"SetDopplerFactor failed"</span>);
+00278 }
+00279 }
+00280 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLSOUND_1_1CListenerDSoundz1308_2" doxytag="NLSOUND::CListenerDSound::setEAXProperty" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLSOUND::CListenerDSound::setEAXProperty </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a04558.html#a15">uint</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>prop</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap>void *&nbsp;</td>
+ <td class="mdname" nowrap> <em>value</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap><a class="el" href="a04558.html#a15">uint</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>valuesize</em></td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"><code> [virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Set any EAX listener property if EAX available.
+<p>
+
+<p>
+Implements <a class="el" href="a03861.html#NLSOUND_1_1IListenerz1318_1">NLSOUND::IListener</a>.
+<p>
+Definition at line <a class="el" href="a05919.html#l00357">357</a> of file <a class="el" href="a05919.html">listener_dsound.cpp</a>.
+<p>
+References <a class="el" href="a05622.html#l00135">nlwarning</a>, <a class="el" href="a05646.html#l01119">res</a>, <a class="el" href="a05981.html#l00105">uint</a>, and <a class="el" href="a05646.html#l01132">value</a>.
+<p>
+<div class="fragment"><pre>00358 {
+00359 <span class="preprocessor">#ifdef EAX_AVAILABLE</span>
+00360 <span class="preprocessor"></span> <span class="keywordflow">if</span> (_EAXListener == NULL)
+00361 {
+00362 _EAXListener = CSoundDriverDSound::instance()-&gt;createPropertySet(NULL);
+00363 }
+00364 <span class="keywordflow">if</span> ( _EAXListener != NULL )
+00365 {
+00366 HRESULT <a class="code" href="a04223.html#a643">res</a> = _EAXListener-&gt;Set(DSPROPSETID_EAX_ListenerProperties, prop, NULL, 0, value, valuesize );
+00367 <span class="keywordflow">if</span> (<a class="code" href="a04223.html#a643">res</a> != S_OK)
+00368 <a class="code" href="a04199.html#a2">nlwarning</a>(<span class="stringliteral">"Setting EAX listener prop #%d fail : %x"</span>, prop, res);
+00369 }
+00370 <span class="preprocessor">#endif</span>
+00371 <span class="preprocessor"></span>}
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLSOUND_1_1CListenerDSoundz1308_3" doxytag="NLSOUND::CListenerDSound::setEnvironment" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLSOUND::CListenerDSound::setEnvironment </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top"><a class="el" href="a04558.html#a15">uint</a>&nbsp;</td>
+ <td class="mdname" nowrap> <em>env</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap>float&nbsp;</td>
+ <td class="mdname" nowrap> <em>size</em> = 7.5f</td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"><code> [virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Set DSPROPERTY_EAXLISTENER_ENVIRONMENT and DSPROPERTY_EAXLISTENER_ENVIRONMENTSIZE if EAX available (see EAX listener properties).
+<p>
+
+<p>
+Implements <a class="el" href="a03861.html#NLSOUND_1_1IListenerz1318_2">NLSOUND::IListener</a>.
+<p>
+Definition at line <a class="el" href="a05919.html#l00334">334</a> of file <a class="el" href="a05919.html">listener_dsound.cpp</a>.
+<p>
+References <a class="el" href="a05622.html#l00135">nlwarning</a>, <a class="el" href="a05646.html#l01119">res</a>, <a class="el" href="a05646.html#l00645">size</a>, and <a class="el" href="a05981.html#l00105">uint</a>.
+<p>
+<div class="fragment"><pre>00335 {
+00336 <span class="preprocessor">#if EAX_AVAILABLE == 1</span>
+00337 <span class="preprocessor"></span> <span class="keywordflow">if</span> (_EAXListener == NULL)
+00338 {
+00339 _EAXListener = CSoundDriverDSound::instance()-&gt;createPropertySet(NULL);
+00340 }
+00341 <span class="keywordflow">if</span> ( _EAXListener != NULL )
+00342 {
+00343 HRESULT <a class="code" href="a04223.html#a643">res</a> = _EAXListener-&gt;Set( DSPROPSETID_EAX_ListenerProperties, DSPROPERTY_EAXLISTENER_ENVIRONMENT, NULL, 0, &amp;env, <span class="keyword">sizeof</span>(<span class="keywordtype">unsigned</span> <span class="keywordtype">long</span>) );
+00344 <span class="keywordflow">if</span> (<a class="code" href="a04223.html#a643">res</a> != S_OK)
+00345 <a class="code" href="a04199.html#a2">nlwarning</a>(<span class="stringliteral">"Setting EAX environment #%u fail : %x"</span>, env, res);
+00346 <a class="code" href="a04223.html#a643">res</a> = _EAXListener-&gt;Set( DSPROPSETID_EAX_ListenerProperties, DSPROPERTY_EAXLISTENER_ENVIRONMENTSIZE, NULL, 0, &amp;size, <span class="keyword">sizeof</span>(<span class="keywordtype">float</span>) );
+00347 <span class="keywordflow">if</span> (<a class="code" href="a04223.html#a643">res</a> != S_OK)
+00348 <a class="code" href="a04199.html#a2">nlwarning</a>(<span class="stringliteral">"Setting EAX environment size %f fail : %x"</span>, size, res);
+00349 }
+00350 <span class="preprocessor">#endif</span>
+00351 <span class="preprocessor"></span>}
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLSOUND_1_1CListenerDSoundz1306_4" doxytag="NLSOUND::CListenerDSound::setGain" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLSOUND::CListenerDSound::setGain </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top">float&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>gain</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Set the gain (volume value inside [0 , 1]). (default: 1) 0.0 -&gt; silence 0.5 -&gt; -6dB 1.0 -&gt; no attenuation values &gt; 1 (amplification) not supported by most drivers
+<p>
+Implements <a class="el" href="a03861.html#NLSOUND_1_1IListenerz1316_4">NLSOUND::IListener</a>.
+<p>
+Definition at line <a class="el" href="a05919.html#l00244">244</a> of file <a class="el" href="a05919.html">listener_dsound.cpp</a>.
+<p>
+<div class="fragment"><pre>00245 {
+00246 CSoundDriverDSound::instance()-&gt;setGain(gain);
+00247 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLSOUND_1_1CListenerDSoundz1306_5" doxytag="NLSOUND::CListenerDSound::setOrientation" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLSOUND::CListenerDSound::setOrientation </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top">const <a class="el" href="a03128.html">NLMISC::CVector</a> &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>front</em>, </td>
+ </tr>
+ <tr>
+ <td class="md" nowrap align="right"></td>
+ <td></td>
+ <td class="md" nowrap>const <a class="el" href="a03128.html">NLMISC::CVector</a> &amp;&nbsp;</td>
+ <td class="mdname" nowrap> <em>up</em></td>
+ </tr>
+ <tr>
+ <td></td>
+ <td class="md">)&nbsp;</td>
+ <td class="md" colspan="2"><code> [virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Set the orientation vectors (3D mode only) (default: (0,1,0), (0,0,1)).
+<p>
+
+<p>
+Implements <a class="el" href="a03861.html#NLSOUND_1_1IListenerz1316_5">NLSOUND::IListener</a>.
+<p>
+Definition at line <a class="el" href="a05919.html#l00194">194</a> of file <a class="el" href="a05919.html">listener_dsound.cpp</a>.
+<p>
+References <a class="el" href="a05622.html#l00135">nlwarning</a>, <a class="el" href="a06673.html#l00051">NLMISC::CVector::x</a>, <a class="el" href="a06673.html#l00051">NLMISC::CVector::y</a>, and <a class="el" href="a06673.html#l00051">NLMISC::CVector::z</a>.
+<p>
+<div class="fragment"><pre>00195 {
+00196 <span class="keywordflow">if</span> (<a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a> != NULL)
+00197 {
+00198 <span class="keywordflow">if</span> (FAILED(<a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a>-&gt;SetOrientation(front.<a class="code" href="a03128.html#NLMISC_1_1CVectoro0">x</a>, front.<a class="code" href="a03128.html#NLMISC_1_1CVectoro2">z</a>, front.<a class="code" href="a03128.html#NLMISC_1_1CVectoro1">y</a>, up.<a class="code" href="a03128.html#NLMISC_1_1CVectoro0">x</a>, up.<a class="code" href="a03128.html#NLMISC_1_1CVectoro2">z</a>, up.<a class="code" href="a03128.html#NLMISC_1_1CVectoro1">y</a>, DS3D_DEFERRED)))
+00199 {
+00200 <a class="code" href="a04199.html#a2">nlwarning</a>(<span class="stringliteral">"SetOrientation failed"</span>);
+00201 }
+00202 <span class="keywordflow">else</span>
+00203 {
+00204 <span class="comment">//nlwarning ("NLSOUND: set listener orientation NEL(f:%.2f/%.2f/%.2f up:%.2f/%.2f/%.2f) DS(f:%.2f/%.2f/%.2f up:%.2f/%.2f/%.2f)", front.x, front.y, front.z, up.x, up.y, up.z, front.x, front.z, front.y, up.x, up.z, up.y);</span>
+00205 }
+00206 }
+00207 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLSOUND_1_1CListenerDSoundz1306_6" doxytag="NLSOUND::CListenerDSound::setPos" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLSOUND::CListenerDSound::setPos </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top">const <a class="el" href="a03128.html">NLMISC::CVector</a> &amp;&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>pos</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Set the position vector (default: (0,0,0)) (3D mode only).
+<p>
+
+<p>
+Implements <a class="el" href="a03861.html#NLSOUND_1_1IListenerz1316_6">NLSOUND::IListener</a>.
+<p>
+Definition at line <a class="el" href="a05919.html#l00103">103</a> of file <a class="el" href="a05919.html">listener_dsound.cpp</a>.
+<p>
+References <a class="el" href="a05622.html#l00135">nlwarning</a>.
+<p>
+<div class="fragment"><pre>00104 {
+00105
+00106 <a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr1">_Pos</a> = pos;
+00107 <span class="comment">// Coordinate system: conversion from NeL to OpenAL/GL:</span>
+00108 <span class="keywordflow">if</span> (<a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a> != NULL)
+00109 {
+00110 <span class="keywordflow">if</span> (FAILED(<a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a>-&gt;SetPosition(pos.x, pos.z, pos.y, DS3D_DEFERRED)))
+00111 {
+00112 <a class="code" href="a04199.html#a2">nlwarning</a>(<span class="stringliteral">"SetPosition failed"</span>);
+00113 }
+00114 <span class="keywordflow">else</span>
+00115 {
+00116 <span class="comment">//nlwarning ("set listener NEL(p:%.2f/%.2f/%.2f) DS(p:%.2f/%.2f/%.2f)", pos.x, pos.y, pos.z, pos.x, pos.z, pos.y);</span>
+00117 }
+00118 }
+00119 }
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLSOUND_1_1CListenerDSoundz1308_4" doxytag="NLSOUND::CListenerDSound::setRolloffFactor" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLSOUND::CListenerDSound::setRolloffFactor </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top">float&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>f</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Set the rolloff factor (default: 1) to scale the distance attenuation effect.
+<p>
+
+<p>
+Implements <a class="el" href="a03861.html#NLSOUND_1_1IListenerz1318_3">NLSOUND::IListener</a>.
+<p>
+Definition at line <a class="el" href="a05919.html#l00286">286</a> of file <a class="el" href="a05919.html">listener_dsound.cpp</a>.
+<p>
+References <a class="el" href="a05622.html#l00135">nlwarning</a>.
+<p>
+Referenced by <a class="el" href="a05919.html#l00050">CListenerDSound()</a>.
+<p>
+<div class="fragment"><pre>00287 {
+00288 <span class="preprocessor">#if MANUAL_ROLLOFF == 1</span>
+00289 <span class="preprocessor"></span> <span class="keywordflow">if</span> (<a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a> != NULL)
+00290 {
+00291 <span class="comment">//clamp(f, DS3D_MINROLLOFFFACTOR, DS3D_MAXROLLOFFFACTOR);</span>
+00292
+00293 <span class="comment">// VOLUMETEST: Don't use the rolloff factor. We manage the</span>
+00294 <span class="comment">// volumes ourselves</span>
+00295 f = DS3D_MINROLLOFFFACTOR;
+00296
+00297
+00298 <span class="keywordflow">if</span> (FAILED(<a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a>-&gt;SetRolloffFactor(f, DS3D_DEFERRED)))
+00299 {
+00300 <a class="code" href="a04199.html#a2">nlwarning</a>(<span class="stringliteral">"SetRolloffFactor failed"</span>);
+00301 }
+00302 }
+00303 <span class="preprocessor">#endif</span>
+00304 <span class="preprocessor"></span>}
+</pre></div> </td>
+ </tr>
+</table>
+<a class="anchor" name="NLSOUND_1_1CListenerDSoundz1306_7" doxytag="NLSOUND::CListenerDSound::setVelocity" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> void NLSOUND::CListenerDSound::setVelocity </td>
+ <td class="md" valign="top">(&nbsp;</td>
+ <td class="md" nowrap valign="top">const <a class="el" href="a03128.html">NLMISC::CVector</a> &amp;&nbsp;</td>
+ <td class="mdname1" valign="top" nowrap> <em>vel</em> </td>
+ <td class="md" valign="top">&nbsp;)&nbsp;</td>
+ <td class="md" nowrap><code> [virtual]</code></td>
+ </tr>
+
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+Set the velocity vector (3D mode only) (default: (0,0,0)).
+<p>
+
+<p>
+Implements <a class="el" href="a03861.html#NLSOUND_1_1IListenerz1316_7">NLSOUND::IListener</a>.
+<p>
+Definition at line <a class="el" href="a05919.html#l00154">154</a> of file <a class="el" href="a05919.html">listener_dsound.cpp</a>.
+<p>
+References <a class="el" href="a05622.html#l00135">nlwarning</a>, <a class="el" href="a06673.html#l00051">NLMISC::CVector::x</a>, <a class="el" href="a06673.html#l00051">NLMISC::CVector::y</a>, and <a class="el" href="a06673.html#l00051">NLMISC::CVector::z</a>.
+<p>
+<div class="fragment"><pre>00155 {
+00156 <span class="keywordflow">if</span> (<a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a> != NULL)
+00157 {
+00158 <span class="keywordflow">if</span> (FAILED(<a class="code" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">_Listener</a>-&gt;SetVelocity(vel.<a class="code" href="a03128.html#NLMISC_1_1CVectoro0">x</a>, vel.<a class="code" href="a03128.html#NLMISC_1_1CVectoro2">z</a>, vel.<a class="code" href="a03128.html#NLMISC_1_1CVectoro1">y</a>, DS3D_DEFERRED)))
+00159 {
+00160 <a class="code" href="a04199.html#a2">nlwarning</a>(<span class="stringliteral">"SetVelocity failed"</span>);
+00161 }
+00162 }
+00163 }
+</pre></div> </td>
+ </tr>
+</table>
+<hr><h2>Friends And Related Function Documentation</h2>
+<a class="anchor" name="NLSOUND_1_1CListenerDSoundn0" doxytag="NLSOUND::CListenerDSound::CSoundDriverDSound" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> friend class <a class="el" href="a03420.html">CSoundDriverDSound</a><code> [friend]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05920.html#l00058">58</a> of file <a class="el" href="a05920.html">listener_dsound.h</a>. </td>
+ </tr>
+</table>
+<hr><h2>Field Documentation</h2>
+<a class="anchor" name="NLSOUND_1_1CListenerDSoundv0" doxytag="NLSOUND::CListenerDSound::_Instance" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a02767.html">CListenerDSound</a> * <a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundv0">NLSOUND::CListenerDSound::_Instance</a> = NULL<code> [static, private]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+The instance of the singleton.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05919.html#l00044">44</a> of file <a class="el" href="a05919.html">listener_dsound.cpp</a>. </td>
+ </tr>
+</table>
+<a class="anchor" name="NLSOUND_1_1CListenerDSoundr0" doxytag="NLSOUND::CListenerDSound::_Listener" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> LPDIRECTSOUND3DLISTENER8 <a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundr0">NLSOUND::CListenerDSound::_Listener</a><code> [private]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+The DirectSound listener interface.
+<p>
+
+<p>
+Definition at line <a class="el" href="a05920.html#l00138">138</a> of file <a class="el" href="a05920.html">listener_dsound.h</a>. </td>
+ </tr>
+</table>
+<a class="anchor" name="NLSOUND_1_1CListenerDSoundr1" doxytag="NLSOUND::CListenerDSound::_Pos" ></a><p>
+<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
+ <tr>
+ <td class="mdRow">
+ <table cellpadding="0" cellspacing="0" border="0">
+ <tr>
+ <td class="md" nowrap valign="top"> <a class="el" href="a03128.html">NLMISC::CVector</a> <a class="el" href="a02767.html#NLSOUND_1_1CListenerDSoundr1">NLSOUND::CListenerDSound::_Pos</a><code> [private]</code>
+ </table>
+ </td>
+ </tr>
+</table>
+<table cellspacing=5 cellpadding=0 border=0>
+ <tr>
+ <td>
+ &nbsp;
+ </td>
+ <td>
+
+<p>
+
+<p>
+Definition at line <a class="el" href="a05920.html#l00141">141</a> of file <a class="el" href="a05920.html">listener_dsound.h</a>. </td>
+ </tr>
+</table>
+<hr>The documentation for this class was generated from the following files:<ul>
+<li><a class="el" href="a05920.html">listener_dsound.h</a><li><a class="el" href="a05919.html">listener_dsound.cpp</a></ul>
+<hr size="1"><address style="align: right;"><small>Generated on Tue Mar 16 14:39:22 2004 for NeL by
+<a href="http://www.doxygen.org/index.html">
+<img src="doxygen.png" alt="doxygen" align="middle" border=0 >
+</a>1.3.6 </small></address>
+</body>
+</html>