OpenSimMirror/libraries/ode-0.9/docs/group__drawstuff.html

669 lines
31 KiB
HTML
Raw Normal View History

2007-10-19 05:24:38 +00:00
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>Open Dynamics Engine: DrawStuff</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
<link href="tabs.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.5.3 -->
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="modules.html"><span>Modules</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<h1>DrawStuff</h1><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Data Structures</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">struct &nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="structds_functions.html">dsFunctions</a></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set of functions to be used as callbacks by the simulation loop. <a href="structds_functions.html#_details">More...</a><br></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">DS_API void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__drawstuff.html#g28560ea1b64c1d83095bcdfce9caf9dc">dsSimulationLoop</a> (int argc, char **argv, int window_width, int window_height, struct <a class="el" href="structds_functions.html">dsFunctions</a> *fn)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Does the complete simulation. <a href="#g28560ea1b64c1d83095bcdfce9caf9dc"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">DS_API void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__drawstuff.html#g7a2a69ac611d5dc6ffc8e43b0a743472">dsError</a> (char *msg,...)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">exit with error message. <a href="#g7a2a69ac611d5dc6ffc8e43b0a743472"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">DS_API void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__drawstuff.html#ga84175b14c3c31daae08a9c88acc2b02">dsDebug</a> (char *msg,...)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">exit with error message and core dump. <a href="#ga84175b14c3c31daae08a9c88acc2b02"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">DS_API void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__drawstuff.html#gbca5fa4076aa9e45caa049f33e8cf168">dsPrint</a> (char *msg,...)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">print log message <a href="#gbca5fa4076aa9e45caa049f33e8cf168"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">DS_API void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__drawstuff.html#g8e4ea933c31d207ec57949fbb3a75815">dsSetViewpoint</a> (float xyz[3], float hpr[3])</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Sets the viewpoint. <a href="#g8e4ea933c31d207ec57949fbb3a75815"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">DS_API void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__drawstuff.html#gaa22f45ad00e0010a1440985ac51b18b">dsGetViewpoint</a> (float xyz[3], float hpr[3])</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Gets the viewpoint. <a href="#gaa22f45ad00e0010a1440985ac51b18b"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">DS_API void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__drawstuff.html#g6c13a5a310b9e00c45150058e669ebad">dsStop</a> ()</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Stop the simulation loop. <a href="#g6c13a5a310b9e00c45150058e669ebad"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">DS_API double&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__drawstuff.html#g02f3f096703d49f5a9e497aec0b85f75">dsElapsedTime</a> ()</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Get the elapsed time (on wall-clock). <a href="#g02f3f096703d49f5a9e497aec0b85f75"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">DS_API void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__drawstuff.html#g8a3d6f8fecc8c7d5a206bed35f17ba7a">dsSetTexture</a> (int texture_number)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Toggle the rendering of textures. <a href="#g8a3d6f8fecc8c7d5a206bed35f17ba7a"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">DS_API void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__drawstuff.html#g3221a0d1360621eaad7c54597671c092">dsSetColor</a> (float red, float green, float blue)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set the color with which geometry is drawn. <a href="#g3221a0d1360621eaad7c54597671c092"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">DS_API void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__drawstuff.html#g440940cfaef61775e37c33b055b832af">dsSetColorAlpha</a> (float red, float green, float blue, float alpha)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set the color and transparency with which geometry is drawn. <a href="#g440940cfaef61775e37c33b055b832af"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">DS_API void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__drawstuff.html#gfba4fde6b0b74f6cd422036dedd08836">dsDrawBox</a> (const float pos[3], const float R[12], const float sides[3])</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Draw a box. <a href="#gfba4fde6b0b74f6cd422036dedd08836"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">DS_API void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__drawstuff.html#g0802e7641f8028182b69fabc729a6704">dsDrawSphere</a> (const float pos[3], const float R[12], float radius)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Draw a sphere. <a href="#g0802e7641f8028182b69fabc729a6704"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">DS_API void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__drawstuff.html#gcfcbae15cee67eceb45cd96bf01484d4">dsDrawTriangle</a> (const float pos[3], const float R[12], const float *v0, const float *v1, const float *v2, int solid)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Draw a triangle. <a href="#gcfcbae15cee67eceb45cd96bf01484d4"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="g0b09b41f1f6500b293678aa1691f1537"></a><!-- doxytag: member="drawstuff::dsDrawCylinder" ref="g0b09b41f1f6500b293678aa1691f1537" args="(const float pos[3], const float R[12], float length, float radius)" -->
DS_API void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__drawstuff.html#g0b09b41f1f6500b293678aa1691f1537">dsDrawCylinder</a> (const float pos[3], const float R[12], float length, float radius)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Draw a z-aligned cylinder. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="gce8f6c8a9f2871dac2f5e7f159b96feb"></a><!-- doxytag: member="drawstuff::dsDrawCapsule" ref="gce8f6c8a9f2871dac2f5e7f159b96feb" args="(const float pos[3], const float R[12], float length, float radius)" -->
DS_API void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__drawstuff.html#gce8f6c8a9f2871dac2f5e7f159b96feb">dsDrawCapsule</a> (const float pos[3], const float R[12], float length, float radius)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Draw a z-aligned capsule. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="g61b166a9b7c04063a27be982051f4af5"></a><!-- doxytag: member="drawstuff::dsDrawLine" ref="g61b166a9b7c04063a27be982051f4af5" args="(const float pos1[3], const float pos2[3])" -->
DS_API void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__drawstuff.html#g61b166a9b7c04063a27be982051f4af5">dsDrawLine</a> (const float pos1[3], const float pos2[3])</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Draw a line. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="g4b8754994a4cca9d51fce16445f0d612"></a><!-- doxytag: member="drawstuff::dsDrawConvex" ref="g4b8754994a4cca9d51fce16445f0d612" args="(const float pos[3], const float R[12], float *_planes, unsigned int _planecount, float *_points, unsigned int _pointcount, unsigned int *_polygons)" -->
DS_API void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__drawstuff.html#g4b8754994a4cca9d51fce16445f0d612">dsDrawConvex</a> (const float pos[3], const float R[12], float *_planes, unsigned int _planecount, float *_points, unsigned int _pointcount, unsigned int *_polygons)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Draw a convex shape. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">DS_API void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="group__drawstuff.html#g211aa83d5c5d102cdda303cc7aeb2fd5">dsSetSphereQuality</a> (int n)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set the quality with which curved objects are rendered. <a href="#g211aa83d5c5d102cdda303cc7aeb2fd5"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
DrawStuff is a library for rendering simple 3D objects in a virtual environment, for the purposes of demonstrating the features of ODE. It is provided for demonstration purposes and is not intended for production use.<h2><a class="anchor" name="Notes">
Notes</a></h2>
In the virtual world, the z axis is "up" and z=0 is the floor.<p>
The user is able to click+drag in the main window to move the camera: left button - pan and tilt. right button - forward and sideways. left + right button (or middle button) - sideways and up. <hr><h2>Function Documentation</h2>
<a class="anchor" name="ga84175b14c3c31daae08a9c88acc2b02"></a><!-- doxytag: member="drawstuff.h::dsDebug" ref="ga84175b14c3c31daae08a9c88acc2b02" args="(char *msg,...)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">DS_API void dsDebug </td>
<td>(</td>
<td class="paramtype">char *&nbsp;</td>
<td class="paramname"> <em>msg</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">&nbsp;</td>
<td class="paramname"> <em>...</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
exit with error message and core dump.
<p>
this functions tries to dump core or start the debugger. <dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>msg</em>&nbsp;</td><td>format strin, like printf, without the newline character. </td></tr>
</table>
</dl>
</div>
</div><p>
<a class="anchor" name="gfba4fde6b0b74f6cd422036dedd08836"></a><!-- doxytag: member="drawstuff.h::dsDrawBox" ref="gfba4fde6b0b74f6cd422036dedd08836" args="(const float pos[3], const float R[12], const float sides[3])" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">DS_API void dsDrawBox </td>
<td>(</td>
<td class="paramtype">const float&nbsp;</td>
<td class="paramname"> <em>pos</em>[3], </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const float&nbsp;</td>
<td class="paramname"> <em>R</em>[12], </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const float&nbsp;</td>
<td class="paramname"> <em>sides</em>[3]</td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Draw a box.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>pos</em>&nbsp;</td><td>is the x,y,z of the center of the object. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>R</em>&nbsp;</td><td>is a 3x3 rotation matrix for the object, stored by row like this: [ R11 R12 R13 0 ] [ R21 R22 R23 0 ] [ R31 R32 R33 0 ] </td></tr>
<tr><td valign="top"></td><td valign="top"><em>sides[]</em>&nbsp;</td><td>is an array of x,y,z side lengths. </td></tr>
</table>
</dl>
</div>
</div><p>
<a class="anchor" name="g0802e7641f8028182b69fabc729a6704"></a><!-- doxytag: member="drawstuff.h::dsDrawSphere" ref="g0802e7641f8028182b69fabc729a6704" args="(const float pos[3], const float R[12], float radius)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">DS_API void dsDrawSphere </td>
<td>(</td>
<td class="paramtype">const float&nbsp;</td>
<td class="paramname"> <em>pos</em>[3], </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const float&nbsp;</td>
<td class="paramname"> <em>R</em>[12], </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">float&nbsp;</td>
<td class="paramname"> <em>radius</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Draw a sphere.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>pos</em>&nbsp;</td><td>Position of center. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>R</em>&nbsp;</td><td>orientation. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>radius</em>&nbsp;</td><td></td></tr>
</table>
</dl>
</div>
</div><p>
<a class="anchor" name="gcfcbae15cee67eceb45cd96bf01484d4"></a><!-- doxytag: member="drawstuff.h::dsDrawTriangle" ref="gcfcbae15cee67eceb45cd96bf01484d4" args="(const float pos[3], const float R[12], const float *v0, const float *v1, const float *v2, int solid)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">DS_API void dsDrawTriangle </td>
<td>(</td>
<td class="paramtype">const float&nbsp;</td>
<td class="paramname"> <em>pos</em>[3], </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const float&nbsp;</td>
<td class="paramname"> <em>R</em>[12], </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const float *&nbsp;</td>
<td class="paramname"> <em>v0</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const float *&nbsp;</td>
<td class="paramname"> <em>v1</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const float *&nbsp;</td>
<td class="paramname"> <em>v2</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>solid</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Draw a triangle.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>pos</em>&nbsp;</td><td>Position of center </td></tr>
<tr><td valign="top"></td><td valign="top"><em>R</em>&nbsp;</td><td>orientation </td></tr>
<tr><td valign="top"></td><td valign="top"><em>v0</em>&nbsp;</td><td>first vertex </td></tr>
<tr><td valign="top"></td><td valign="top"><em>v1</em>&nbsp;</td><td>second </td></tr>
<tr><td valign="top"></td><td valign="top"><em>v2</em>&nbsp;</td><td>third vertex </td></tr>
<tr><td valign="top"></td><td valign="top"><em>solid</em>&nbsp;</td><td>set to 0 for wireframe </td></tr>
</table>
</dl>
</div>
</div><p>
<a class="anchor" name="g02f3f096703d49f5a9e497aec0b85f75"></a><!-- doxytag: member="drawstuff.h::dsElapsedTime" ref="g02f3f096703d49f5a9e497aec0b85f75" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">DS_API double dsElapsedTime </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Get the elapsed time (on wall-clock).
<p>
It returns the nr of seconds since the last call to this function.
</div>
</div><p>
<a class="anchor" name="g7a2a69ac611d5dc6ffc8e43b0a743472"></a><!-- doxytag: member="drawstuff.h::dsError" ref="g7a2a69ac611d5dc6ffc8e43b0a743472" args="(char *msg,...)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">DS_API void dsError </td>
<td>(</td>
<td class="paramtype">char *&nbsp;</td>
<td class="paramname"> <em>msg</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">&nbsp;</td>
<td class="paramname"> <em>...</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
exit with error message.
<p>
This function displays an error message then exit. <dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>msg</em>&nbsp;</td><td>format strin, like printf, without the newline character. </td></tr>
</table>
</dl>
</div>
</div><p>
<a class="anchor" name="gaa22f45ad00e0010a1440985ac51b18b"></a><!-- doxytag: member="drawstuff.h::dsGetViewpoint" ref="gaa22f45ad00e0010a1440985ac51b18b" args="(float xyz[3], float hpr[3])" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">DS_API void dsGetViewpoint </td>
<td>(</td>
<td class="paramtype">float&nbsp;</td>
<td class="paramname"> <em>xyz</em>[3], </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">float&nbsp;</td>
<td class="paramname"> <em>hpr</em>[3]</td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Gets the viewpoint.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>xyz</em>&nbsp;</td><td>position </td></tr>
<tr><td valign="top"></td><td valign="top"><em>hpr</em>&nbsp;</td><td>heading,pitch,roll. </td></tr>
</table>
</dl>
</div>
</div><p>
<a class="anchor" name="gbca5fa4076aa9e45caa049f33e8cf168"></a><!-- doxytag: member="drawstuff.h::dsPrint" ref="gbca5fa4076aa9e45caa049f33e8cf168" args="(char *msg,...)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">DS_API void dsPrint </td>
<td>(</td>
<td class="paramtype">char *&nbsp;</td>
<td class="paramname"> <em>msg</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">&nbsp;</td>
<td class="paramname"> <em>...</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
print log message
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>msg</em>&nbsp;</td><td>format string, like printf, without the <br>
. </td></tr>
</table>
</dl>
</div>
</div><p>
<a class="anchor" name="g3221a0d1360621eaad7c54597671c092"></a><!-- doxytag: member="drawstuff.h::dsSetColor" ref="g3221a0d1360621eaad7c54597671c092" args="(float red, float green, float blue)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">DS_API void dsSetColor </td>
<td>(</td>
<td class="paramtype">float&nbsp;</td>
<td class="paramname"> <em>red</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">float&nbsp;</td>
<td class="paramname"> <em>green</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">float&nbsp;</td>
<td class="paramname"> <em>blue</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Set the color with which geometry is drawn.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>red</em>&nbsp;</td><td>Red component from 0 to 1 </td></tr>
<tr><td valign="top"></td><td valign="top"><em>green</em>&nbsp;</td><td>Green component from 0 to 1 </td></tr>
<tr><td valign="top"></td><td valign="top"><em>blue</em>&nbsp;</td><td>Blue component from 0 to 1 </td></tr>
</table>
</dl>
</div>
</div><p>
<a class="anchor" name="g440940cfaef61775e37c33b055b832af"></a><!-- doxytag: member="drawstuff.h::dsSetColorAlpha" ref="g440940cfaef61775e37c33b055b832af" args="(float red, float green, float blue, float alpha)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">DS_API void dsSetColorAlpha </td>
<td>(</td>
<td class="paramtype">float&nbsp;</td>
<td class="paramname"> <em>red</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">float&nbsp;</td>
<td class="paramname"> <em>green</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">float&nbsp;</td>
<td class="paramname"> <em>blue</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">float&nbsp;</td>
<td class="paramname"> <em>alpha</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Set the color and transparency with which geometry is drawn.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>alpha</em>&nbsp;</td><td>Note that alpha transparency is a misnomer: it is alpha opacity. 1.0 means fully opaque, and 0.0 means fully transparent. </td></tr>
</table>
</dl>
</div>
</div><p>
<a class="anchor" name="g211aa83d5c5d102cdda303cc7aeb2fd5"></a><!-- doxytag: member="drawstuff.h::dsSetSphereQuality" ref="g211aa83d5c5d102cdda303cc7aeb2fd5" args="(int n)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">DS_API void dsSetSphereQuality </td>
<td>(</td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>n</em> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Set the quality with which curved objects are rendered.
<p>
Higher numbers are higher quality, but slower to draw. This must be set before the first objects are drawn to be effective. Default sphere quality is 1, default capsule quality is 3.
</div>
</div><p>
<a class="anchor" name="g8a3d6f8fecc8c7d5a206bed35f17ba7a"></a><!-- doxytag: member="drawstuff.h::dsSetTexture" ref="g8a3d6f8fecc8c7d5a206bed35f17ba7a" args="(int texture_number)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">DS_API void dsSetTexture </td>
<td>(</td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>texture_number</em> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Toggle the rendering of textures.
<p>
It changes the way objects are drawn. these changes will apply to all further dsDrawXXX() functions. <dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>the</em>&nbsp;</td><td>texture number must be a DS_xxx texture constant. The current texture is colored according to the current color. At the start of each frame, the texture is reset to none and the color is reset to white. </td></tr>
</table>
</dl>
</div>
</div><p>
<a class="anchor" name="g8e4ea933c31d207ec57949fbb3a75815"></a><!-- doxytag: member="drawstuff.h::dsSetViewpoint" ref="g8e4ea933c31d207ec57949fbb3a75815" args="(float xyz[3], float hpr[3])" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">DS_API void dsSetViewpoint </td>
<td>(</td>
<td class="paramtype">float&nbsp;</td>
<td class="paramname"> <em>xyz</em>[3], </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">float&nbsp;</td>
<td class="paramname"> <em>hpr</em>[3]</td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Sets the viewpoint.
<p>
<dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>xyz</em>&nbsp;</td><td>camera position. </td></tr>
<tr><td valign="top"></td><td valign="top"><em>hpr</em>&nbsp;</td><td>contains heading, pitch and roll numbers in degrees. heading=0 points along the x axis, pitch=0 is looking towards the horizon, and roll 0 is "unrotated". </td></tr>
</table>
</dl>
</div>
</div><p>
<a class="anchor" name="g28560ea1b64c1d83095bcdfce9caf9dc"></a><!-- doxytag: member="drawstuff.h::dsSimulationLoop" ref="g28560ea1b64c1d83095bcdfce9caf9dc" args="(int argc, char **argv, int window_width, int window_height, struct dsFunctions *fn)" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">DS_API void dsSimulationLoop </td>
<td>(</td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>argc</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">char **&nbsp;</td>
<td class="paramname"> <em>argv</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>window_width</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">int&nbsp;</td>
<td class="paramname"> <em>window_height</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">struct <a class="el" href="structds_functions.html">dsFunctions</a> *&nbsp;</td>
<td class="paramname"> <em>fn</em></td><td>&nbsp;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td><td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Does the complete simulation.
<p>
This function starts running the simulation, and only exits when the simulation is done. Function pointers should be provided for the callbacks. <dl compact><dt><b>Parameters:</b></dt><dd>
<table border="0" cellspacing="2" cellpadding="0">
<tr><td valign="top"></td><td valign="top"><em>argv</em>&nbsp;</td><td>supports flags like '-notex' '-noshadow' '-pause' </td></tr>
<tr><td valign="top"></td><td valign="top"><em>fn</em>&nbsp;</td><td>Callback functions. </td></tr>
</table>
</dl>
</div>
</div><p>
<a class="anchor" name="g6c13a5a310b9e00c45150058e669ebad"></a><!-- doxytag: member="drawstuff.h::dsStop" ref="g6c13a5a310b9e00c45150058e669ebad" args="()" -->
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">DS_API void dsStop </td>
<td>(</td>
<td class="paramname"> </td>
<td>&nbsp;)&nbsp;</td>
<td width="100%"></td>
</tr>
</table>
</div>
<div class="memdoc">
<p>
Stop the simulation loop.
<p>
Calling this from within <a class="el" href="group__drawstuff.html#g28560ea1b64c1d83095bcdfce9caf9dc" title="Does the complete simulation.">dsSimulationLoop()</a> will cause it to exit and return to the caller. it is the same as if the user used the exit command. using this outside the loop will have no effect.
</div>
</div><p>
<hr size="1"><address style="text-align: right;"><small>Generated on Fri Oct 12 08:36:52 2007 for Open Dynamics Engine by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.3 </small></address>
</body>
</html>