proj home

Files   Classes   Functions   Hierarchy  

graphmisc.h File Reference

#include <cassert>
#include <string>
#include <sstream>
#include <iostream>
#include <vector>
#include <GL/glut.h>
#include <commandline.h>
#include <mathlib.h>
#include <print.h>
#include <gobj.h>

Include dependency graph for graphmisc.h:

Go to the source code of this file.

Classes

class  OpenGLinitialisation
 A default OpenGL session. More...
class  myRotate
 Rotate. More...
class  myglPushMatrixMode
 Push and pop the current OpenGL matrix mode. More...
class  myglPushMatrix
 Push and pop the current OpenGL matrix. More...
class  myglPushAttrib
 Save and restore the attribute. More...
class  myglCapability
 Enable and disable an attriub. More...
class  myglMode
class  myLightingTurnOff
 Turn the lighting off. More...
class  myaxes
 Draw axes at the origin. More...
class  camera
 View manipulator. More...
class  framerate< period >
 Display a Glut applications framerate. More...
class  gltextmsg
class  gobjMyTranslateDraw
 Save the coordinate system, translate, draw, restore. More...
class  gobjQuadric
class  gobjMyDiscDraw
class  gobjMySphereDraw
 Draw a translated sphere. More...
class  gobjMyCircle
 Sampled circle or ellipse. More...
class  gobjMyCircleDraw
 Draw a circle or ellipse in xy plane. More...
class  gobjMyBitmapCharacter
 Display a character string in 3D space. More...
class  gobjMyArrow
 Draw a primitive flat arrow in 3D space. More...
class  gobjMyDiskDraw
class  colorfunction
 Mapping a color from blue to red along a unit length. More...
class  gridsquare
 Draw a square grid. More...
class  graphmisc
 Miscellaneous graphics functions. More...

Functions

void glerrordisplay ()
 Write OpenGl errors to cout.
void axes (doublec length)
 Draw axes red(x), green(y), blue(z).
void wirerectangle (floatc x, floatc y, floatc z)
 Draw a wire box with the following dimensions.


Function Documentation

void axes ( doublec  length  ) 

Draw axes red(x), green(y), blue(z).

Definition at line 89 of file graphmisc.cpp.

Referenced by display(), and vrmlshape::writePN().

00090 {
00091   myLightingTurnOff temp;
00092 
00093   glBegin(GL_LINES);
00094    
00095   glColor3f(1.0,0.0,0.0);
00096   glVertex3f(0.0,0.0,0.0);
00097   glVertex3f(length,0.0,0.0);
00098 
00099   glColor3f(0.0,1.0,0.0);
00100   glVertex3f(0.0,0.0,0.0);
00101   glVertex3f(0.0,length,0.0);
00102   
00103   glColor3f(0.0,0.0,1.0);
00104   glVertex3f(0.0,0.0,0.0);
00105   glVertex3f(0.0,0.0,length);
00106 
00107   glEnd();
00108 }

void glerrordisplay (  )  [inline]

Write OpenGl errors to cout.

Definition at line 110 of file graphmisc.cpp.

Referenced by zprtest::display(), visenv::display(), simplexD1tessapp01::display(), menusystemtest04::display(), menusystemtest03::display(), menusystemtest02::display(), menusystemtest01::display(), d2simplextest::display(), test07::display(), test06::display(), test05::display(), test01obj< P, PD >::display(), bsptree001::display(), display(), partitionstest::display01(), helixtestscope::helixtest::display01(), spiralindextest::display01(), snakesorttest::display01(), simplexD2tessapp01::display01(), quickhull3Dtest::display01(), quickhull2Dtest::display01(), triangletest::display01(), tetrahedrontest::display01(), plotpolartest::display01(), maze005::display01(), maze004::display01(), maze003::display01(), maze002::display01(), maze001::display01(), buttonpanel01test::display01(), diskinttest::display01(), circleD2test::display01(), boxOBBhalfspaceD2test::display01(), triangles3Tdisplaytest::display01(), menusystemtest::display01(), graphicsImmediateDeferredTest::display01(), gobjtest::display01(), delaunaysimpleD2test::display01(), cubegui::display01(), regionD2linkedtest::display01(), polytopesD2linkedtest::display01(), pathlinesegtest::display01(), display01(), partitionstest::display02(), menusystemtest::display02(), display02(), cubedraw3d::draw(), cubedraw2d::draw(), meshpatchtestdisplay01(), planeinttestdisplay01(), pointsurfacetestdisplay01(), zpr::readProjection(), zpr::readScreenDimensions(), zpr::write(), and zpr::zpr().

00111 {
00112   GLenum errval = glGetError();
00113   if (errval != GL_NO_ERROR)
00114      cout << gluErrorString( errval ) << endl;
00115 }

void wirerectangle ( floatc  x,
floatc  y,
floatc  z 
)

Draw a wire box with the following dimensions.

[scales]

Definition at line 48 of file graphmisc.cpp.

00053 {
00054   myglPushMatrix temp;
00055   glScalef (x,y,z);
00056   glutWireCube (1.0);
00057 }


Generated on Fri Mar 4 00:49:37 2011 for Chelton Evans Source by  doxygen 1.5.8