Last change
on this file since 2822 was
2822,
checked in by ldelgass, 12 years ago
|
Const correctness fixes, pass vector/matrix objects by reference, various
formatting and style cleanups, don't spam syslog and uncomment openlog() call.
Still needs to be compiled with -DWANT_TRACE to get tracing, but now trace
output will be output to file in /tmp.
|
-
Property svn:eol-style set to
native
|
File size:
1.2 KB
|
Line | |
---|
1 | /* -*- mode: c++; c-basic-offset: 4; indent-tabs-mode: nil -*- */ |
---|
2 | /* |
---|
3 | * ---------------------------------------------------------------------- |
---|
4 | * Sphere.h : Sphere class |
---|
5 | * |
---|
6 | * ====================================================================== |
---|
7 | * AUTHOR: Wei Qiao <qiaow@purdue.edu> |
---|
8 | * Purdue Rendering and Perceptualization Lab (PURPL) |
---|
9 | * |
---|
10 | * Copyright (c) 2004-2006 Purdue Research Foundation |
---|
11 | * |
---|
12 | * See the file "license.terms" for information on usage and |
---|
13 | * redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES. |
---|
14 | * ====================================================================== |
---|
15 | */ |
---|
16 | |
---|
17 | #ifndef _SPHERE_H_ |
---|
18 | #define _SPHERE_H_ |
---|
19 | |
---|
20 | #include <GL/glew.h> |
---|
21 | #include <GL/glu.h> |
---|
22 | |
---|
23 | #include "Trace.h" |
---|
24 | |
---|
25 | #include "Color.h" |
---|
26 | #include "Renderable.h" |
---|
27 | |
---|
28 | class Sphere : public Renderable |
---|
29 | { |
---|
30 | public: |
---|
31 | float radius; |
---|
32 | Color color; |
---|
33 | int stack; |
---|
34 | int slice; |
---|
35 | |
---|
36 | Sphere(float x, float y, float z, float r, float g, float b, float _radius, |
---|
37 | int _stack, int _slice); |
---|
38 | |
---|
39 | virtual ~Sphere(); |
---|
40 | |
---|
41 | void set_vertical_res(int _stack); |
---|
42 | void set_horizontal_res(int _slice); |
---|
43 | |
---|
44 | //display the sphere |
---|
45 | void draw(GLUquadric* q); |
---|
46 | void render(); |
---|
47 | }; |
---|
48 | |
---|
49 | #endif |
---|
Note: See
TracBrowser
for help on using the repository browser.