#include <DrawObj.H>
Inherited by IS3D::ArrowObj, IS3D::AxesObj, IS3D::BoxObj, IS3D::DebugDraw, IS3D::Default3DMenu, IS3D::EventDisplay, IS3D::EyeProjectionObj, IS3D::IFSObj, IS3D::ModelObj, IS3D::MultiColumnMenu, IS3D::NamedAxesObj, IS3D::NektarModelObj, IS3D::ProgressBar, IS3D::ScreenTextObj, IS3D::SphereObj, IS3D::TextObj, IS3D::TextScreen, and IS3D::VRMLObj.
Public Member Functions | |
| DrawObj (std::string name, int roomObj=0, int displayInitially=1) | |
| virtual | ~DrawObj () |
| virtual void | contextInit () |
| virtual void | draw ()=0 |
| Override this function and place your G3D draw calls inside it. | |
| virtual void | highlight () |
| default selection feedback is just to show the bounding box | |
| virtual void | unhighlight () |
| default deselection feedback is just to hide the bounding box | |
| virtual void | reColor (const Color4 &c, int colorNum=0) |
| virtual void | reTexture (const std::string &texname, int texNum=0) |
| virtual void | setCoordinateFrame (CoordinateFrame cf) |
| virtual void | setBoundingBox (BBox bbox) |
| virtual void | setDisplayed (bool d) |
| virtual void | setBoundingBoxDisplayed (bool d) |
| virtual void | setMovable (bool m) |
| virtual void | setRenderAsTransparent (bool t) |
| virtual void | setRoomObj (bool r) |
| virtual void | setDrawingPass (int d) |
| virtual void | setContextInitialized () |
| virtual void | setLit (bool l) |
| std::string | getName () |
| CoordinateFrame | getCoordinateFrame () |
| BBox | getBoundingBox () |
| bool | getDisplayed () |
| bool | getBoundingBoxDisplayed () |
| bool | getMovable () |
| bool | getSelectable () |
| bool | getRenderAsTransparent () |
| bool | getRoomObj () |
| int | getDrawingPass () |
| bool | getContextInitialized () |
| bool | getLit () |
| virtual void | show () |
| virtual void | hide () |
| virtual void | showBoundingBox () |
| virtual void | hideBoundingBox () |
| virtual bool | pointIntersectCoarse (const Vector3 &pobj) |
| virtual bool | pointIntersectFine (const Vector3 &pobj) |
| virtual void | writeVRML (ostream *os) |
| Write VRML 1.0 (.wrl) format description of the DrawObj. | |
| virtual void | readVRML (istream *is) |
| Read VRML 1.0 (.wrl) format description of the DrawObj. | |
| virtual void | writeIS3 (ostream *os) |
| Write InSpace3D (.is3) format description of the DrawObj. | |
| virtual void | readIS3 (istream *is) |
| Read InSpace3D (.is3) format description of the DrawObj. | |
Protected Attributes | |
| std::string | _name |
| CoordinateFrame | _frame |
| BBox | _bbox |
| bool | _displayed |
| bool | _bboxDisplayed |
| bool | _movable |
| bool | _selectable |
| bool | _transparent |
| bool | _roomObj |
| int | _drawingPass |
| bool | _contextInitialized |
| bool | _lit |
| IS3D::DrawObj::DrawObj | ( | std::string | name, | |
| int | roomObj = 0, |
|||
| int | displayInitially = 1 | |||
| ) |
| virtual IS3D::DrawObj::~DrawObj | ( | ) | [virtual] |
| virtual void IS3D::DrawObj::contextInit | ( | ) | [inline, virtual] |
Implement this to do any GL specific initialization that you need to within your object. Called once per GL context the first frame after the object is created (when the GL context is active).
| virtual void IS3D::DrawObj::draw | ( | ) | [pure virtual] |
Override this function and place your G3D draw calls inside it.
Implemented in IS3D::DebugDraw, IS3D::Default3DMenu, IS3D::EventDisplay, IS3D::EyeProjectionObj, IS3D::IFSObj, IS3D::ModelObj, IS3D::MultiColumnMenu, IS3D::ProgressBar, IS3D::BoxObj, IS3D::ArrowObj, IS3D::AxesObj, IS3D::SphereObj, IS3D::TextObj, IS3D::ScreenTextObj, IS3D::NamedAxesObj, IS3D::TextScreen, IS3D::VRMLObj, and IS3D::NektarModelObj.
| virtual void IS3D::DrawObj::highlight | ( | ) | [inline, virtual] |
default selection feedback is just to show the bounding box
| virtual void IS3D::DrawObj::unhighlight | ( | ) | [inline, virtual] |
default deselection feedback is just to hide the bounding box
| virtual void IS3D::DrawObj::reColor | ( | const Color4 & | c, | |
| int | colorNum = 0 | |||
| ) | [virtual] |
Some interactive widgets assume they can call this functions on any DrawObj, you should override if appropriate.
Reimplemented in IS3D::IFSObj, IS3D::VRMLObj, and IS3D::NektarModelObj.
| virtual void IS3D::DrawObj::reTexture | ( | const std::string & | texname, | |
| int | texNum = 0 | |||
| ) | [virtual] |
Some interactive widgets assume they can call this functions on any DrawObj, you should override if appropriate.
Reimplemented in IS3D::IFSObj, IS3D::VRMLObj, and IS3D::NektarModelObj.
| virtual void IS3D::DrawObj::setCoordinateFrame | ( | CoordinateFrame | cf | ) | [inline, virtual] |
| virtual void IS3D::DrawObj::setBoundingBox | ( | BBox | bbox | ) | [inline, virtual] |
| virtual void IS3D::DrawObj::setDisplayed | ( | bool | d | ) | [virtual] |
| virtual void IS3D::DrawObj::setBoundingBoxDisplayed | ( | bool | d | ) | [inline, virtual] |
| virtual void IS3D::DrawObj::setMovable | ( | bool | m | ) | [inline, virtual] |
| virtual void IS3D::DrawObj::setRenderAsTransparent | ( | bool | t | ) | [inline, virtual] |
| virtual void IS3D::DrawObj::setRoomObj | ( | bool | r | ) | [inline, virtual] |
| virtual void IS3D::DrawObj::setDrawingPass | ( | int | d | ) | [inline, virtual] |
| virtual void IS3D::DrawObj::setContextInitialized | ( | ) | [inline, virtual] |
| virtual void IS3D::DrawObj::setLit | ( | bool | l | ) | [inline, virtual] |
| std::string IS3D::DrawObj::getName | ( | ) | [inline] |
| CoordinateFrame IS3D::DrawObj::getCoordinateFrame | ( | ) | [inline] |
| BBox IS3D::DrawObj::getBoundingBox | ( | ) | [inline] |
| bool IS3D::DrawObj::getDisplayed | ( | ) | [inline] |
| bool IS3D::DrawObj::getBoundingBoxDisplayed | ( | ) | [inline] |
| bool IS3D::DrawObj::getMovable | ( | ) | [inline] |
| bool IS3D::DrawObj::getSelectable | ( | ) | [inline] |
| bool IS3D::DrawObj::getRenderAsTransparent | ( | ) | [inline] |
| bool IS3D::DrawObj::getRoomObj | ( | ) | [inline] |
| int IS3D::DrawObj::getDrawingPass | ( | ) | [inline] |
| bool IS3D::DrawObj::getContextInitialized | ( | ) | [inline] |
| bool IS3D::DrawObj::getLit | ( | ) | [inline] |
| virtual void IS3D::DrawObj::show | ( | ) | [inline, virtual] |
| virtual void IS3D::DrawObj::hide | ( | ) | [inline, virtual] |
| virtual void IS3D::DrawObj::showBoundingBox | ( | ) | [inline, virtual] |
| virtual void IS3D::DrawObj::hideBoundingBox | ( | ) | [inline, virtual] |
| virtual bool IS3D::DrawObj::pointIntersectCoarse | ( | const Vector3 & | pobj | ) | [virtual] |
A fast routine to check whether this point falls within the object. Typically used for selection of objects. By default, this just checks to see whether the point falls within the object's bounding box. If it does, you will probably then want to proceed to call the pointIntersectFine() method to determine with more confidence whether the point actually lies within the object.
| virtual bool IS3D::DrawObj::pointIntersectFine | ( | const Vector3 & | pobj | ) | [virtual] |
Same idea as pointIntersectCoarse() except that this routine should be implemented by subclasses since it is more precise than the simple bounding box check. This is a slower routine that gives a better approximation to whether the point actually lies within the object.
| virtual void IS3D::DrawObj::writeVRML | ( | ostream * | os | ) | [virtual] |
Write VRML 1.0 (.wrl) format description of the DrawObj.
| virtual void IS3D::DrawObj::readVRML | ( | istream * | is | ) | [virtual] |
Read VRML 1.0 (.wrl) format description of the DrawObj.
| virtual void IS3D::DrawObj::writeIS3 | ( | ostream * | os | ) | [virtual] |
Write InSpace3D (.is3) format description of the DrawObj.
| virtual void IS3D::DrawObj::readIS3 | ( | istream * | is | ) | [virtual] |
Read InSpace3D (.is3) format description of the DrawObj.
std::string IS3D::DrawObj::_name [protected] |
Reimplemented in IS3D::MultiColumnMenu.
CoordinateFrame IS3D::DrawObj::_frame [protected] |
BBox IS3D::DrawObj::_bbox [protected] |
bool IS3D::DrawObj::_displayed [protected] |
bool IS3D::DrawObj::_bboxDisplayed [protected] |
bool IS3D::DrawObj::_movable [protected] |
bool IS3D::DrawObj::_selectable [protected] |
bool IS3D::DrawObj::_transparent [protected] |
bool IS3D::DrawObj::_roomObj [protected] |
int IS3D::DrawObj::_drawingPass [protected] |
bool IS3D::DrawObj::_contextInitialized [protected] |
bool IS3D::DrawObj::_lit [protected] |
1.5.1