#include <vuRaycast.h>
Inheritance diagram for vuRaycast:
Public Member Functions | |
vuRaycast () | |
Constructor. | |
~vuRaycast () | |
Destructor. | |
bool | init (const char *DataFile) |
virtual vuCamera * | getCamera () |
This function must return a pointer to the camera that is taking the picture of the scene. | |
virtual vuImage * | getCurrentImage () |
This function must return a pointer to the current vuImage buffer that the method can write to or read from. | |
virtual void | DrawFromImage () |
This function must take the data vuImage buffer from the last call to getCurrent Image and draw that on the screen. | |
virtual void | addRight (wxSizer *sizer) |
This method adds controls to the bottom of the window. | |
virtual void | DrawAgain () |
This function must rerender the scene completely. | |
Static Public Member Functions | |
const char * | getFileType () |
Returns the type of vu Datafile that the utility works with. | |
Protected Member Functions | |
bool | glInit () |
Initializes open gl for the utility. | |
void | onRender () |
void | glResize () |
Resizes the gl viewport and renders the volume. | |
void | onMouse (wxMouseEvent &ev) |
Handles mouse commands from the user. | |
void | OnButtonRender (wxCommandEvent &event) |
initiate a refresh of the rendering | |
void | OnChangeSampDist (void) |
Called if sampling distance has been changed. | |
void | OnCheckBoxPreDraw (void) |
Called if someone's checking the checkbox. | |
void | OnCheckBoxDoSpec (void) |
Called if someone's checking the checkbox for specular shading. | |
void | OnSelectTFunc () |
Changes the method for evaluating the transfer function. | |
void | onKeyboard (wxKeyEvent &event) |
Keyboard handler. | |
vu1 * | getVolume () |
returns a pointer to m_Data | |
Private Attributes | |
vu1112113 * | m_Data |
The raycaster owned by the utility. | |
vuTFDesign | m_TFunc |
The transfer function. | |
vuTransferDialog | m_TFuncDlg |
The transfer function dialog. | |
vuPreviewWin * | m_Preview |
This is a handle for a preview box. | |
wxTextCtrl * | m_TCsmpDist |
for changing sampling distance | |
wxCheckBox * | m_CBdoSpec |
setting the state for preview drawing and specular shading | |
wxCheckBox * | m_CBdrawPrev |
setting the state for preview drawing and specular shading | |
wxListBox * | m_TFuncList |
list of the different methods for evaluating the transfer function |
Definition at line 20 of file vuRaycast.h.
|
Constructor.
Definition at line 40 of file vuRaycast.cpp. |
|
Destructor.
Definition at line 49 of file vuRaycast.cpp. References m_Data. |
|
This method adds controls to the bottom of the window.
Reimplemented from vuBasicUtility. Definition at line 137 of file vuRaycast.cpp. References idDOSPEC, idPREDRAW, idRENDER, idSMPDIST, idTFUNC, m_CBdoSpec, m_CBdrawPrev, m_Preview, m_TCsmpDist, m_TFuncList, NULL, and size. |
|
This function must rerender the scene completely. This is so that the key frame animator can set the camera, and then force a redraw by the method. Implements vuBasicUtility. Definition at line 173 of file vuRaycast.cpp. References vu1112113::doRefresh(), m_Data, and vuGLCanvas::redraw(). |
Here is the call graph for this function:
|
This function must take the data vuImage buffer from the last call to getCurrent Image and draw that on the screen. This is so that prerendered video animation can be displayed by the key frame animator by simply setting the vuImage returned by getCurrentImage and then calling this function. Implements vuBasicUtility. Definition at line 180 of file vuRaycast.cpp. References vuGLCanvas::redraw(). |
Here is the call graph for this function:
|
This function must return a pointer to the camera that is taking the picture of the scene. This is so that the key frame animator can read the camera when it needs to take a snapshot and change the camera when it wants the method to rerender the scene from a predetermined camera position. Implements vuBasicUtility. Definition at line 113 of file vuRaycast.cpp. References vu1::getCameraPtr(), and m_Data. |
Here is the call graph for this function:
|
This function must return a pointer to the current vuImage buffer that the method can write to or read from. This is how the key framer will update the screen. Implements vuBasicUtility. Definition at line 119 of file vuRaycast.cpp. References vu1112113::getImage(), and m_Data. |
Here is the call graph for this function:
|
Returns the type of vu Datafile that the utility works with.
Reimplemented from vuBasicUtility. Definition at line 58 of file vuRaycast.cpp. |
|
returns a pointer to m_Data
Reimplemented from vuBasicUtility. Definition at line 381 of file vuRaycast.cpp. |
|
Initializes open gl for the utility. The method calls the initgl() method so it can do the proper initialization. Reimplemented from vuBasicUtility. Definition at line 246 of file vuRaycast.cpp. References GL_DEPTH_TEST, GL_LESS, glDepthFunc(), glEnable(), vu1112113::initOpenGL(), and m_Data. |
Here is the call graph for this function:
|
Resizes the gl viewport and renders the volume.
Reimplemented from vuBasicUtility. Definition at line 289 of file vuRaycast.cpp. References vuGLCanvas::getHeight(), vuGLCanvas::getWidth(), GLint, glViewport(), m_Data, and vu1112113::setImageSize(). |
Here is the call graph for this function:
|
Initializes the utility window. A object is created and the volume data is read. The window appears when finished. Reimplemented from vuBasicUtility. Definition at line 67 of file vuRaycast.cpp. References vuTFDesign::addColour(), vuTFDesign::addOpacity(), vuPreviewWin::attachCamera(), vu1112113::doPreviewDraw(), vuTFDesign::generateFunction(), vu1::getCamera(), vu1112::getDim1Size(), vu1112::getDim2Size(), vu1112::getDim3Size(), vu1::getErrorMessage(), m_Data, m_Preview, m_TFunc, vu1112113::read(), vuTFDesign::setColourSmoothing(), vuPreviewWin::setCubeSize(), vu1::setFileName(), vuTFDesign::setOpacitySmoothing(), vu111211::setTransferFunc(), and vuCamera::translateXYZ(). |
Here is the call graph for this function:
|
initiate a refresh of the rendering
Definition at line 192 of file vuRaycast.cpp. References vu1112113::doRefresh(), m_Data, and vuGLCanvas::redraw(). |
Here is the call graph for this function:
|
Called if sampling distance has been changed.
Definition at line 218 of file vuRaycast.cpp. |
|
Called if someone's checking the checkbox for specular shading.
Definition at line 209 of file vuRaycast.cpp. |
|
Called if someone's checking the checkbox.
Definition at line 200 of file vuRaycast.cpp. |
|
Keyboard handler. Overridden from vuBasicUtility. As implemented so far 'V' will write out file viewpoint.def containing current viewpoint information and 'v' will read in this file to restore viewpoint. Reimplemented from vuBasicUtility. Definition at line 340 of file vuRaycast.cpp. References vu1::getCamera(), vuCamera::getLookAtVector(), vuCamera::getPosition(), vuCamera::getUpVector(), m_Data, vuCamera::setLookAtVector(), vuCamera::setPosition(), and vuCamera::setUpVector(). |
Here is the call graph for this function:
|
Handles mouse commands from the user. The mouse is the main interface between the user and the utility at the moment. This method receives mouse events from the window, and carries out commands. Reimplemented from vuBasicUtility. Definition at line 327 of file vuRaycast.cpp. References m_TFuncDlg. |
|
The method calls the render() method, setting it up to render to the window's gl canvas. It "automagically" creates a preview now -ms-. Reimplemented from vuBasicUtility. Definition at line 266 of file vuRaycast.cpp. References vu1112113::displayFromImage(), vu1::getCamera(), vuCamera::getHeight(), vuCamera::getWidth(), GL_COLOR_BUFFER_BIT, GL_DEPTH_BUFFER_BIT, GL_MODELVIEW, GL_PROJECTION, glClear(), glLoadIdentity(), glMatrixMode(), glOrtho(), m_Data, m_TFunc, vu1112113::render(), and vu111211::setTransferFunc(). |
Here is the call graph for this function:
|
Changes the method for evaluating the transfer function.
Definition at line 230 of file vuRaycast.cpp. |
|
setting the state for preview drawing and specular shading
Definition at line 122 of file vuRaycast.h. Referenced by addRight(). |
|
setting the state for preview drawing and specular shading
Definition at line 122 of file vuRaycast.h. Referenced by addRight(). |
|
The raycaster owned by the utility.
Definition at line 109 of file vuRaycast.h. Referenced by DrawAgain(), getCamera(), getCurrentImage(), glInit(), glResize(), init(), OnButtonRender(), onKeyboard(), onRender(), and ~vuRaycast(). |
|
This is a handle for a preview box.
Definition at line 116 of file vuRaycast.h. Referenced by addRight(), and init(). |
|
for changing sampling distance
Definition at line 119 of file vuRaycast.h. Referenced by addRight(). |
|
The transfer function.
Reimplemented from vuBasicUtility. Definition at line 111 of file vuRaycast.h. Referenced by init(), and onRender(). |
|
The transfer function dialog.
Definition at line 113 of file vuRaycast.h. Referenced by onMouse(). |
|
list of the different methods for evaluating the transfer function
Definition at line 125 of file vuRaycast.h. Referenced by addRight(). |