mirror of
https://github.com/thestk/stk
synced 2026-01-14 21:41:53 +00:00
72 lines
5.1 KiB
HTML
72 lines
5.1 KiB
HTML
<HTML>
|
|
<HEAD>
|
|
<TITLE>The Synthesis ToolKit in C++ (STK)</TITLE>
|
|
<LINK HREF="doxygen.css" REL="stylesheet" TYPE="text/css">
|
|
</HEAD>
|
|
<BODY BGCOLOR="#FFFFFF">
|
|
<CENTER>
|
|
<img src="princeton.gif"> <img src="ccrma.gif"> <img src="mcgill.gif"><P>
|
|
<a class="qindex" href="index.html">Home</a> <a class="qindex" href="information.html">Information</a> <a class="qindex" href="classes.html">Classes</a> <a class="qindex" href="download.html">Download</a> <a class="qindex" href="usage.html">Usage</a> <a class="qindex" href="maillist.html">Mail List</a> <a class="qindex" href="system.html">Requirements</a> <a class="qindex" href="links.html">Links</a> <a class="qindex" href="faq.html">FAQ</a> <a class="qindex" href="tutorial.html">Tutorial</a></CENTER>
|
|
<HR>
|
|
<!-- Generated by Doxygen 1.4.4 -->
|
|
<div class="nav">
|
|
<a class="el" href="dir_000000.html">include</a></div>
|
|
<h1>Sphere.h</h1><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/***************************************************/</span>
|
|
<a name="l00010"></a>00010 <span class="comment">/***************************************************/</span>
|
|
<a name="l00011"></a>00011
|
|
<a name="l00012"></a>00012 <span class="preprocessor">#ifndef STK_SPHERE_H</span>
|
|
<a name="l00013"></a>00013 <span class="preprocessor"></span><span class="preprocessor">#define STK_SPHERE_H</span>
|
|
<a name="l00014"></a>00014 <span class="preprocessor"></span>
|
|
<a name="l00015"></a>00015 <span class="preprocessor">#include "Stk.h"</span>
|
|
<a name="l00016"></a>00016 <span class="preprocessor">#include "Vector3D.h"</span>
|
|
<a name="l00017"></a>00017
|
|
<a name="l00018"></a><a class="code" href="classSphere.html">00018</a> <span class="keyword">class </span><a class="code" href="classSphere.html">Sphere</a> : <span class="keyword">public</span> <a class="code" href="classStk.html">Stk</a>
|
|
<a name="l00019"></a>00019 {
|
|
<a name="l00020"></a>00020 <span class="keyword">public</span>:
|
|
<a name="l00022"></a>00022 <a class="code" href="classSphere.html#a0">Sphere</a>(StkFloat radius = 1.0 );
|
|
<a name="l00023"></a>00023
|
|
<a name="l00025"></a>00025 <a class="code" href="classSphere.html#a1">~Sphere</a>();
|
|
<a name="l00026"></a>00026
|
|
<a name="l00028"></a>00028 <span class="keywordtype">void</span> <a class="code" href="classSphere.html#a2">setPosition</a>(StkFloat x, StkFloat y, StkFloat z);
|
|
<a name="l00029"></a>00029
|
|
<a name="l00031"></a>00031 <span class="keywordtype">void</span> <a class="code" href="classSphere.html#a3">setVelocity</a>(StkFloat x, StkFloat y, StkFloat z);
|
|
<a name="l00032"></a>00032
|
|
<a name="l00034"></a>00034 <span class="keywordtype">void</span> <a class="code" href="classSphere.html#a4">setRadius</a>(StkFloat radius);
|
|
<a name="l00035"></a>00035
|
|
<a name="l00037"></a>00037 <span class="keywordtype">void</span> <a class="code" href="classSphere.html#a5">setMass</a>(StkFloat mass);
|
|
<a name="l00038"></a>00038
|
|
<a name="l00040"></a>00040 <a class="code" href="classVector3D.html">Vector3D</a>* <a class="code" href="classSphere.html#a6">getPosition</a>();
|
|
<a name="l00041"></a>00041
|
|
<a name="l00043"></a>00043 <a class="code" href="classVector3D.html">Vector3D</a>* <a class="code" href="classSphere.html#a7">getRelativePosition</a>(<a class="code" href="classVector3D.html">Vector3D</a> *position);
|
|
<a name="l00044"></a>00044
|
|
<a name="l00046"></a>00046 StkFloat <a class="code" href="classSphere.html#a8">getVelocity</a>(<a class="code" href="classVector3D.html">Vector3D</a>* velocity);
|
|
<a name="l00047"></a>00047
|
|
<a name="l00049"></a>00049 StkFloat <a class="code" href="classSphere.html#a9">isInside</a>(<a class="code" href="classVector3D.html">Vector3D</a> *position);
|
|
<a name="l00050"></a>00050
|
|
<a name="l00052"></a>00052 StkFloat <a class="code" href="classSphere.html#a10">getRadius</a>();
|
|
<a name="l00053"></a>00053
|
|
<a name="l00055"></a>00055 StkFloat <a class="code" href="classSphere.html#a11">getMass</a>();
|
|
<a name="l00056"></a>00056
|
|
<a name="l00058"></a>00058 <span class="keywordtype">void</span> <a class="code" href="classSphere.html#a12">addVelocity</a>(StkFloat x, StkFloat y, StkFloat z);
|
|
<a name="l00059"></a>00059
|
|
<a name="l00061"></a>00061 <span class="keywordtype">void</span> <a class="code" href="classSphere.html#a13">tick</a>(StkFloat timeIncrement);
|
|
<a name="l00062"></a>00062
|
|
<a name="l00063"></a>00063 <span class="keyword">private</span>:
|
|
<a name="l00064"></a>00064 <a class="code" href="classVector3D.html">Vector3D</a> position_;
|
|
<a name="l00065"></a>00065 <a class="code" href="classVector3D.html">Vector3D</a> velocity_;
|
|
<a name="l00066"></a>00066 <a class="code" href="classVector3D.html">Vector3D</a> workingVector_;
|
|
<a name="l00067"></a>00067 StkFloat radius_;
|
|
<a name="l00068"></a>00068 StkFloat mass_;
|
|
<a name="l00069"></a>00069 };
|
|
<a name="l00070"></a>00070
|
|
<a name="l00071"></a>00071 <span class="preprocessor">#endif</span>
|
|
</pre></div><HR>
|
|
|
|
<table>
|
|
<tr><td><A HREF="http://ccrma.stanford.edu/software/stk/"><I>The Synthesis ToolKit in C++ (STK)</I></A></td></tr>
|
|
<tr><td>©1995-2007 Perry R. Cook and Gary P. Scavone. All Rights Reserved.</td></tr>
|
|
</table>
|
|
|
|
</BODY>
|
|
</HTML>
|