3Depict
|
A class to draw rectangluar prisms. More...
#include <drawables.h>
Public Member Functions | |
DrawRectPrism () | |
~DrawRectPrism () | |
virtual unsigned int | getType () const |
virtual DrawableObj * | clone () const |
void | draw () const |
Draw object. More... | |
void | setDrawMode (unsigned int n) |
Set the draw mode. More... | |
void | setColour (float rnew, float gnew, float bnew, float anew=1.0f) |
Set colour of box. More... | |
void | setLineWidth (float lineWidth) |
Set thickness of box. More... | |
void | setAxisAligned (const Point3D &p1, const Point3D &p2) |
Set up box as axis-aligned rectangle using two points. More... | |
void | setAxisAligned (const BoundCube &b) |
Set up box as axis-aligned rectangle using bounding box. More... | |
void | getBoundingBox (BoundCube &b) const |
void | recomputeParams (const std::vector< Point3D > &vecs, const std::vector< float > &scalars, unsigned int mode) |
Recompute the internal parameters using the input vector information. More... | |
![]() | |
virtual bool | isOverlay () const |
Is this an overlay? By default, no. More... | |
DrawableObj () | |
Constructor. More... | |
virtual bool | needsDepthSorting () const |
Do we need to do element based depth sorting? More... | |
virtual bool | isExplodable () const |
Can we break this object down into constituent elements? More... | |
virtual void | explode (std::vector< DrawableObj *> &simpleObjects) |
Break object down into simple elements. More... | |
virtual bool | hasChanged () const |
void | setActive (bool active) |
Set the active state of the object. More... | |
void | setInteract (bool canAct) |
Set if user can interact with object, needed for opengl hit testing. More... | |
virtual | ~DrawableObj () |
Drawable destructor. More... | |
virtual Point3D | getCentroid () const |
Get the centre of the object. Only valid if object is simple. More... | |
Additional Inherited Members | |
![]() | |
static void | setUseAlphaBlending (bool willBlend) |
static void | setCurCamera (const Camera *c) |
Set the current camera. More... | |
static void | setTexPool (TexturePool *t) |
Set the current camera. More... | |
static void | clearTexPool () |
static void | setWindowSize (unsigned int x, unsigned int y) |
static void | setBackgroundColour (float r, float g, float b) |
![]() | |
bool | canSelect |
Can be selected from openGL viewport interactively? More... | |
bool | wantsLight |
Wants lighting calculations active during render? More... | |
![]() | |
static float | getHighContrastValue () |
![]() | |
bool | active |
Is the drawable active? More... | |
bool | haveChanged |
Is the object changed since last set? More... | |
![]() | |
static const Camera * | curCamera = 0 |
Pointer to current scene camera. More... | |
static float | backgroundR |
static float | backgroundG |
static float | backgroundB |
static TexturePool * | texPool =0 |
static bool | useAlphaBlend |
static unsigned int | winX |
static unsigned int | winY |
A class to draw rectangluar prisms.
DrawRectPrism::DrawRectPrism | ( | ) |
DrawRectPrism::~DrawRectPrism | ( | ) |
|
virtual |
Reimplemented from DrawableObj.
References DrawRectPrism().
|
virtual |
Draw object.
Implements DrawableObj.
References DrawableObj::active, ASSERT, DRAW_FLAT, DRAW_WIREFRAME, and drawBox().
Referenced by Scene::draw().
|
virtual |
Implements DrawableObj.
References BoundCube::setBounds().
|
inlinevirtual |
Implements DrawableObj.
References DRAW_TYPE_RECTPRISM.
|
virtual |
Recompute the internal parameters using the input vector information.
Reimplemented from DrawableObj.
References ASSERT, DRAW_RECT_BIND_CORNER_MOVE, and DRAW_RECT_BIND_TRANSLATE.
Set up box as axis-aligned rectangle using two points.
Referenced by Scene::draw(), BoundingBoxFilter::numBytesForCache(), IonClipFilter::refresh(), BoundingBoxFilter::refresh(), and SpatialAnalysisFilter::setPropFromBinding().
void DrawRectPrism::setAxisAligned | ( | const BoundCube & | b | ) |
Set up box as axis-aligned rectangle using bounding box.
References BoundCube::getBounds().
void DrawRectPrism::setColour | ( | float | rnew, |
float | gnew, | ||
float | bnew, | ||
float | anew = 1.0f |
||
) |
Set colour of box.
Referenced by Scene::draw(), BoundingBoxFilter::numBytesForCache(), BoundingBoxFilter::refresh(), and SpatialAnalysisFilter::setPropFromBinding().
|
inline |
Set the draw mode.
void DrawRectPrism::setLineWidth | ( | float | lineWidth | ) |
Set thickness of box.
References ASSERT.
Referenced by BoundingBoxFilter::numBytesForCache(), BoundingBoxFilter::refresh(), and SpatialAnalysisFilter::setPropFromBinding().