#include <OpenGLView.h>
Inheritance diagram for OpenGLView:

Public Member Functions | |
| virtual | ~OpenGLView () |
| virtual BOOL | initOpenGL () |
| CVolumeRendererDoc * | GetDocument () |
| virtual void | renderScene ()=0 |
| void | setContext () |
Public Attributes | |
| CDC * | device_context_ |
| The device context. | |
Protected Member Functions | |
| OpenGLView () | |
| Implementation for type information about the MFC classes at runtime. | |
| virtual BOOL | createViewGLContext () |
| BOOL | setupPixelFormat () |
| void | swapGLBuffers () |
| virtual void | OnDraw (CDC *device_context) |
| virtual BOOL | PreCreateWindow (CREATESTRUCT &create_struct) |
| afx_msg int | OnCreate (LPCREATESTRUCT create_struct) |
| afx_msg void | OnDestroy () |
| afx_msg BOOL | OnEraseBkgnd (CDC *device_context) |
| afx_msg void | OnTimer (UINT event_id) |
Protected Attributes | |
| Volume * | volume_ |
| The volume. | |
| VolumeLoader * | volume_loader_ |
| The volume loader. | |
| HGLRC | rendering_context_ |
| The rendering context handle. | |
| double | view_width_height_ratio_ |
| GLfloat * | ambient_light_ |
| The ambient light for the lighting of objects. | |
| GLfloat * | diffuse_light_ |
| The diffuse light for the lighting of objects. | |
| GLfloat * | light_position_ |
| The light position. | |
| OpenGLView::OpenGLView | ( | ) | [protected] |
Implementation for type information about the MFC classes at runtime.
The default constructor.
| OpenGLView::~OpenGLView | ( | ) | [virtual] |
The destructor.
| BOOL OpenGLView::createViewGLContext | ( | ) | [protected, virtual] |
Creates the OpenGL context for drawing on the view.
| CVolumeRendererDoc * OpenGLView::GetDocument | ( | ) | [inline] |
Call this function to get a pointer to the view's document.
| BOOL OpenGLView::initOpenGL | ( | ) | [virtual] |
| int OpenGLView::OnCreate | ( | LPCREATESTRUCT | create_struct | ) | [protected] |
The MFC framework calls this member function when an application requests that the Windows window be created by calling the Create or CreateEx member function.
| create_struct | Points to a CREATESTRUCT structure that contains information about the CWnd object being created. |
| void OpenGLView::OnDestroy | ( | ) | [protected] |
| void OpenGLView::OnDraw | ( | CDC * | device_context | ) | [protected, virtual] |
This overrided method is resonsible for rendering of an image of the document.
| device_context | This is used to render an image of the document. |
| BOOL OpenGLView::OnEraseBkgnd | ( | CDC * | device_context | ) | [protected] |
| void OpenGLView::OnTimer | ( | UINT | event_id | ) | [protected] |
The framework calls this member function after each interval specified in the SetTimer member function used to install a timer.
| event_id | Specifies the identifier of the timer. |
| BOOL OpenGLView::PreCreateWindow | ( | CREATESTRUCT & | create_struct | ) | [protected, virtual] |
Called before the creation of the Windows window attached to this CWnd object.
| create_struct | This structure defines the initialization parameters passed to the window procedure of an application. |
| virtual void OpenGLView::renderScene | ( | ) | [pure virtual] |
| void OpenGLView::setContext | ( | ) |
Sets the rendering context.
| BOOL OpenGLView::setupPixelFormat | ( | ) | [protected] |
Sets the format of the pixels to draw.
| void OpenGLView::swapGLBuffers | ( | ) | [protected] |
Sets the device context.
GLfloat* OpenGLView::ambient_light_ [protected] |
The ambient light for the lighting of objects.
The device context.
GLfloat* OpenGLView::diffuse_light_ [protected] |
The diffuse light for the lighting of objects.
GLfloat* OpenGLView::light_position_ [protected] |
The light position.
HGLRC OpenGLView::rendering_context_ [protected] |
The rendering context handle.
double OpenGLView::view_width_height_ratio_ [protected] |
The ratio between the width of the view and the height of the view.
Volume* OpenGLView::volume_ [protected] |
The volume.
VolumeLoader* OpenGLView::volume_loader_ [protected] |
1.4.7