Last change
on this file since 2837 was
2837,
checked in by ldelgass, 12 years ago
|
More misc. cleanups
|
-
Property svn:eol-style set to
native
|
File size:
1.0 KB
|
Rev | Line | |
---|
[2798] | 1 | /* -*- mode: c++; c-basic-offset: 4; indent-tabs-mode: nil -*- */ |
---|
[401] | 2 | /* |
---|
| 3 | * ---------------------------------------------------------------------- |
---|
| 4 | * Renderable.cpp: abstract class, a drawable thing |
---|
| 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 | */ |
---|
[2837] | 16 | #include "Renderable.h" |
---|
[401] | 17 | |
---|
[2837] | 18 | Renderable::Renderable() |
---|
| 19 | { |
---|
| 20 | } |
---|
[401] | 21 | |
---|
[2837] | 22 | Renderable::Renderable(const Vector3& loc) : |
---|
[1474] | 23 | location(loc), |
---|
| 24 | enabled(true) |
---|
| 25 | { |
---|
| 26 | } |
---|
[401] | 27 | |
---|
[2837] | 28 | Renderable::~Renderable() |
---|
| 29 | {} |
---|
[401] | 30 | |
---|
[2837] | 31 | void Renderable::move(const Vector3& new_loc) |
---|
| 32 | { |
---|
| 33 | location = new_loc; |
---|
| 34 | } |
---|
[401] | 35 | |
---|
[2837] | 36 | void Renderable::enable() |
---|
| 37 | { |
---|
| 38 | enabled = true; |
---|
| 39 | } |
---|
| 40 | |
---|
| 41 | void Renderable::disable() |
---|
| 42 | { |
---|
| 43 | enabled = false; |
---|
| 44 | } |
---|
| 45 | |
---|
| 46 | bool Renderable::is_enabled() const |
---|
| 47 | { |
---|
| 48 | return enabled; |
---|
| 49 | } |
---|
| 50 | |
---|
Note: See
TracBrowser
for help on using the repository browser.