Sophie

Sophie

distrib > Mandriva > 10.0-com > i586 > by-pkgid > 9347541fe87a5ea3f3b8dbc50f660e8e > files > 115

libQGLViewer-devel-1.3.6-1mdk.i586.rpm

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
  <title>libQGLViewer examples</title>
  <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
  <link href="../qglviewer.css" rel="stylesheet" type="text/css" />
  <link rel="shortcut icon" href="../images/qglviewer.ico" type="image/x-icon" />
  <link rel="icon" href="../images/qglviewer.icon.png" type="image/png" />
</head>
<body>

<table class="banner">
  <tr>
     <td align="center"><a href="../index.html"><b>Home</b></a></td>
     <td align="center"><a href="../refManual/hierarchy.html"><b>Documentation</b></a></td>
     <td align="center"><a href="../download.html"><b>Download</b></a></td>
     <td align="center" class="qindexHL"><b>Screenshots</b></td>
     <td align="center"><a href="../developer.html"><b>Developer</b></a></td>
   </tr>
</table>

<h1>libQGLViewer examples</h1>

<h2>Introduction</h2>

Many pedagogical examples illustrate some functionalities of the viewer and are provided for
understanding and cut and paste. New users should read the <a href="../intro.html">introduction
page</a> and the <a href="../commented.html">commented example</a> to understand the philosophy of
the library. One should then test the following examples :

<table cellpadding="2" cellspacing="9">
  <tr>
    <td bgcolor="#eeeeff" align="center">
      <a href="simpleViewer.html"><img src="../images/simpleViewer.jpg" width="200" height="133" border="0" alt="simpleViewer"/><br/>
      <b>simpleViewer</b></a><br/> The simplest application example: 20 lines of code and yet all the power !
    </td>
    <td bgcolor="#eeeeff" align="center">
      <a href="manipulatedFrame.html"><img src="../images/manipulatedFrame.jpg" width="200" height="133" border="0" alt="manipulatedFrame"/><br/>
      <b>manipulatedFrame</b></a><br/> A <code>ManipulatedFrame</code> can be moved with the mouse in the scene.
    </td>
    <td bgcolor="#eeeeff" align="center">
      <a href="select.html"><img src="../images/select.jpg" width="200" height="133" border="0" alt="select"/><br/>
      <b>select</b></a><br/> Selection of objects of the scene using <code>select()</code> and an OpenGL GL_SELECT render mode.
    </td>
    <td bgcolor="#eeeeff" align="center">
      <a href="keyboardAndMouse.html"><img src="../images/keyboardAndMouse.jpg" width="200" height="133" border="0" alt="keyboardAndMouse"/><br/>
      <b>keyboardAndMouse</b></a><br/> Shows how to customize your keyboard and mouse bindings.
    </td>
  </tr>
</table>

<h2>List of all the examples</h2>
<table cellpadding="2" cellspacing="9">
  <tr>
    <td bgcolor="#eeeeff" align="center">
      <a href="3dsViewer.html"><img src="../images/3dsViewer.jpg" width="200" height="133" border="0" alt="3dsViewer"/><br/>
      <b>3dsViewer</b></a><br/> The LGPL lib3ds library is used to load and display a 3ds scene.
    </td>
    <td bgcolor="#eeeeff" align="center">
      <a href="agora.html"><img src="../images/agora.jpg" width="200" height="133" border="0" alt="agora"/><br/>
      <b>agora</b></a><br/> Implementation of the game of <i>Agora</i>. 
    </td>
    <td bgcolor="#eeeeff" align="center">
      <a href="animation.html"><img src="../images/animation.jpg" width="200" height="133" border="0" alt="animation"/><br/>
      <b>animation</b></a><br/> The <code>animate()</code> function illustrated by a water particle simulation.
    </td>
  </tr>
  <tr>
    <td bgcolor="#eeeeff" align="center">
      <a href="callback.html"><img src="../images/callback.jpg" width="200" height="133" border="0" alt="callback"/><br/>
      <b>callback</b></a><br/> Using the Qt signal-slot mechanism to connect a QGLViewer and your scene.
    </td>
    <td bgcolor="#eeeeff" align="center">
      <a href="constrainedCamera.html"><img src="../images/constrainedCamera.jpg" width="200" height="133" border="0" alt="constrainedCamera"/><br/>
      <b>constrainedCamera</b></a><br/> Constraints applied on the Camera Frame to limit its translation and/or rotation.
    </td>
    <td bgcolor="#eeeeff" align="center">
      <a href="constrainedFrame.html"><img src="../images/constrainedFrame.jpg" width="200" height="133" border="0" alt="constrainedFrame"/><br/>
      <b>constrainedFrame</b></a><br/> Constraints can limit the translation and/or rotation of a (Manipulated)Frame.
    </td>
  </tr>
  <tr>
    <td bgcolor="#eeeeff" align="center">
      <a href="draw3DText.html"><img src="../images/draw3DText.jpg" width="200" height="133" border="0" alt="draw3DText"/><br/>
      <b>draw3DText</b></a><br/> An icosahedron is used to illustrate the <code>draw3DText()</code> function.
    </td>
    <td bgcolor="#eeeeff" align="center">
      <a href="drawLight.html"><img src="../images/drawLight.jpg" width="200" height="133" border="0" alt="drawLight"/><br/>
      <b>drawLight</b></a><br/> The <code>drawLight()</code> function is a light debugging tool.
    </td>
    <td bgcolor="#eeeeff" align="center">
      <a href="fastDraw.html"><img src="../images/fastDraw.jpg" width="200" height="133" border="0" alt="fastDraw"/><br/>
      <b>fastDraw</b></a><br/> The <code>fastDraw()</code> function keeps interactivity even with large scenes.
    </td>
  </tr>
  <tr>
    <td bgcolor="#eeeeff" align="center">
      <a href="frameTransform.html"><img src="../images/frameTransform.jpg" width="200" height="133" border="0" alt="frameTransform"/><br/>
      <b>frameTransform</b></a><br/> Coordinate transformation between different Frames. 
    </td>
    <td bgcolor="#eeeeff" align="center">
      <a href="interface.html"><img src="../images/interface.jpg" width="200" height="133" border="0" alt="interface"/><br/>
      <b>interface</b></a><br/> Adding a graphical user interface around a QGLViewer.
    </td>
    <td bgcolor="#eeeeff" align="center">
      <a href="keyFrames.html"><img src="../images/keyFrames.jpg" width="200" height="133" border="0" alt="keyFrames"/><br/>
      <b>keyFrames</b></a><br/> The <code>KeyFrameInterpolator</code> test example.
    </td>
  </tr>
  <tr>
    <td bgcolor="#eeeeff" align="center">
      <a href="keyboardAndMouse.html"><img src="../images/keyboardAndMouse.jpg" width="200" height="133" border="0" alt="keyboardAndMouse"/><br/>
      <b>keyboardAndMouse</b></a><br/> Shows how to customize your keyboard and mouse bindings.
    </td>
    <td bgcolor="#eeeeff" align="center">
      <a href="luxo.html"><img src="../images/luxo.jpg" width="200" height="133" border="0" alt="luxo"/><br/>
      <b>luxo</b></a><br/> A more complex exemple that combines manipulatedFrames, selection and constraints.
    </td>
    <td bgcolor="#eeeeff" align="center">
      <a href="manipulatedFrame.html"><img src="../images/manipulatedFrame.jpg" width="200" height="133" border="0" alt="manipulatedFrame"/><br/>
      <b>manipulatedFrame</b></a><br/> A <code>ManipulatedFrame</code> can be moved with the mouse in the scene.
    </td>
  </tr>
  <tr>
    <td bgcolor="#eeeeff" align="center">
      <a href="mouseGrabber.html"><img src="../images/mouseGrabber.jpg" width="200" height="133" border="0" alt="mouseGrabber"/><br/>
      <b>mouseGrabber</b></a><br/> Illustration of the <code>MouseGrabber</code> class.
    </td>
    <td bgcolor="#eeeeff" align="center">
      <a href="multiView.html"><img src="../images/multiView.jpg" width="200" height="133" border="0" alt="multiView"/><br/>
      <b>multiView</b></a><br/> A multi-view application, with constrained camera displacements.
    </td>
    <td bgcolor="#eeeeff" align="center">
      <a href="screenCoordSystem.html"><img src="../images/screenCoordSystem.jpg" width="200" height="133" border="0" alt="screenCoordSystem"/><br/>
      <b>screenCoordSystem</b></a><br/> A saucers control viewer that illustrates the screen coordinate system feature. 
    </td>
  </tr>
  <tr>
    <td bgcolor="#eeeeff" align="center">
      <a href="select.html"><img src="../images/select.jpg" width="200" height="133" border="0" alt="select"/><br/>
      <b>select</b></a><br/> Selection of objects of the scene using <code>select()</code> and an OpenGL GL_SELECT render mode.
    </td>
    <td bgcolor="#eeeeff" align="center">
      <a href="simpleViewer.html"><img src="../images/simpleViewer.jpg" width="200" height="133" border="0" alt="simpleViewer"/><br/>
      <b>simpleViewer</b></a><br/> The simplest application example: 20 lines of code and yet all the power !
    </td>
    <td bgcolor="#eeeeff" align="center">
      <a href="spinningFrame.html"><img src="../images/spinningFrame.jpg" width="200" height="133" border="0" alt="spinningFrame"/><br/>
      <b>spinningFrame</b></a><br/> Illustration of the <code>SpinningFrame</code> class.
    </td>
  </tr>
  <tr>
    <td bgcolor="#eeeeff" align="center">
      <a href="stereoViewer.html"><img src="../images/stereoViewer.jpg" width="200" height="133" border="0" alt="stereoViewer"/><br/>
      <b>stereoViewer</b></a><br/> Simply press S to toggle stereo display (architecture dependent).
    </td>
    <td bgcolor="#eeeeff" align="center">
      <a href="textureViewer.html"><img src="../images/textureViewer.jpg" width="200" height="133" border="0" alt="textureViewer"/><br/>
      <b>textureViewer</b></a><br/> Loads image files and textures map polygons with it.
    </td>
    <td bgcolor="#eeeeff" align="center">
      <a href="x3dViewer.html"><img src="../images/x3dViewer.jpg" width="200" height="133" border="0" alt="x3dViewer"/><br/>
      <b>x3dViewer</b></a><br/> The X3D Toolkit library is used to load and display a x3d scene.
    </td>
  </tr>
</table>

<h2>Compilation</h2>

<p>
<img src="../images/linux.png" width="49" height="54" align="middle" alt="linux"/>
<img src="../images/mac.png" width="55" height="54" align="middle" alt="mac"/>
If you installed the RPM, the examples' source files are in <code>/usr/share/doc/QGLViewer/examples</code> and you
have to copy the desired example(s) directories to a place where you have write permission.<br/>
If you have downloaded the archive instead, simply go to the <code>examples</code> directory.
</p>

Use the following code to compile all the examples (can also be done in a specific example directory
to compile only this example) :
<pre>
> cd examples
> qmake [INCLUDE_DIR=...] [LIB_DIR=...]
> make
</pre>

The optional <code>INCLUDE_DIR</code> and <code>LIB_DIR</code> parameters are needed if you
customized your <a href="../download.html#linux"><code>make install</code></a>. Use <code>qmake
INCLUDE_DIR=../.. LIB_DIR=../../QGLViewer</code> if you didn't "install" the library.

<p>
You may prompted an <code>"error while loading shared libraries"</code> message when trying to
execute an example. In that case, you probably forgot to add the directory of the library to your
default library path. On unix, this is done like this (on SGI IRIX, replace
<code>LD_LIBRARY_PATH</code> by <code>LD_LIBRARYN32_PATH</code>):
</p>
<pre>
[bash] > export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:${HOME}/PathToQGLViewer/lib
[tcsh] > setenv LD_LIBRARY_PATH ${LD_LIBRARY_PATH}:${HOME}/PathToQGLViewer/lib
</pre>

<p>
<img src="../images/windows.png" width="55" height="54" align="middle" alt="windows"/>
Windows users have to compile each example separately, using the <i>Open (or Generate) Qt project</i> icon.
<br/>
Add the path to <code>libQGLViewer-<i>version</i></code> to your
<i>Project-QGLViewer properties-C/C++-General-Additional Include Directories</i>
(<i>Tools-Options-Directories-include files</i> with MSVS 6.0).
<br/>
Add the path to <code>libQGLViewer-<i>version</i>\QGLViewer</code> to your
<i>Linker-General-Additional Library Directories</i>
(<i>Tools-Options-Directories-Library files</i> with MSVS 6.0).
<br/>
Qt 2.3 users have to edit the examples <code>.pro</code> files
as is detailed in these files.
</p>

<p>
  <a href="http://validator.w3.org/check/referer"><img src="../images/xhtml.png" alt="Valid XHTML 1.0!" height="31" width="88" border="0"/></a>
  <a href="http://jigsaw.w3.org/css-validator/check/referer"><img src="../images/css.png" alt="Valid CSS!" width="88" height="31" border="0"/></a>
<i>Last modified on Thursday, February 5, 2004.</i>
</p>

</body>
</html>