TFEditDialog Class Reference

#include <TFEditDialog.h>

Collaboration diagram for TFEditDialog:

Collaboration graph
[legend]

List of all members.

Public Types

enum  { IDD = IDD_TFEDITDIALOG }

Public Member Functions

 TFEditDialog (CWnd *pParent=NULL)
virtual ~TFEditDialog ()
afx_msg void OnBnClickedButtonclose ()
afx_msg void OnPaint ()
LRESULT OnRangeChange (WPARAM wParam, LPARAM lParam)
afx_msg void OnLButtonDblClk (UINT nFlags, CPoint point)
afx_msg void OnLButtonDown (UINT nFlags, CPoint point)
afx_msg void OnLButtonUp (UINT nFlags, CPoint point)
afx_msg void OnMouseMove (UINT nFlags, CPoint point)
afx_msg void OnRButtonUp (UINT nFlags, CPoint point)

Protected Member Functions

virtual void DoDataExchange (CDataExchange *pDX)
virtual BOOL OnInitDialog ()

Protected Attributes

CStatic m_OpacityControl
CStatic m_ColorControl
CRangeSlider c_RangeSliderHor
CRangeSlider c_RangeSliderVert
double m_Left
double m_Right
double m_Top
double m_Bottom

Private Member Functions

void RedrawColorAndOpacity ()
void GetColorControlPos (CPoint point, int &xPos, double &zoomFaktorX)
void GetOpacityControlPos (CPoint point, int &xPos, float &yPos, double &zoomFaktorX, double &zoomFaktorY)

Private Attributes

bool m_MouseOpacity
bool m_MouseColor
CPoint m_MousePos
int m_MouseIndexPoint

Static Private Attributes

static const int MIN_X_ZOOM = 100
static const int MIN_Y_ZOOM = 5


Detailed Description

Transferfunction Edit Dialog

Member Enumeration Documentation

anonymous enum

Enumerator:
IDD 


Constructor & Destructor Documentation

TFEditDialog::TFEditDialog ( CWnd *  pParent = NULL  ) 

TFEditDialog::~TFEditDialog (  )  [virtual]


Member Function Documentation

void TFEditDialog::DoDataExchange ( CDataExchange *  pDX  )  [protected, virtual]

void TFEditDialog::GetColorControlPos ( CPoint  point,
int &  xPos,
double &  zoomFaktorX 
) [private]

Returns the relative position of a point in the color control window. It is used to determine the position in the color control window on a mouse click, taking into account the current zoom factor and the current x offset

Parameters:
point Mouse position
xPos Relative x position in the color control window
zoomFaktorX current zoom Factor set for color control window

void TFEditDialog::GetOpacityControlPos ( CPoint  point,
int &  xPos,
float &  yPos,
double &  zoomFaktorX,
double &  zoomFaktorY 
) [private]

Returns the relative position of a point in the opacity control window. It is used to determine the position in the opacity control window on a mouse click, taking into account the current zoom factor and the current x and y offset

Parameters:
point Mouse position
xPos Relative x position in the opacity control window
yPos Relative y psoition in the opacity control window
zoomFaktorX X zoom factor set for opacity control window
zoomFaktorY Y zoom factor set for opacity control window
The position of the mouse cursor is converted into a density value (x direction) and a opacity value (y direction) depending on the relative position to the opacity control and on the current zoom settings
Parameters:
point Absolute position of mouse cursor
xPos Density (0-4095)
yPos Opacity (0-1.0)
zoomFaktorX 
zoomFaktorY 

void TFEditDialog::OnBnClickedButtonclose (  ) 

Close Button. Hide Dialog

BOOL TFEditDialog::OnInitDialog (  )  [protected, virtual]

void TFEditDialog::OnLButtonDblClk ( UINT  nFlags,
CPoint  point 
)

Left mouse button double click. Add a point to the transfer function

void TFEditDialog::OnLButtonDown ( UINT  nFlags,
CPoint  point 
)

Left mouse button click. Drag and Drop points

void TFEditDialog::OnLButtonUp ( UINT  nFlags,
CPoint  point 
)

Left mouse button release. End of drag and drop

void TFEditDialog::OnMouseMove ( UINT  nFlags,
CPoint  point 
)

Mouse movement. Move transfer function point when left mouse button is pressed and mouse was on a transfer function point

void TFEditDialog::OnPaint (  ) 

Redraw Transfer function

LRESULT TFEditDialog::OnRangeChange ( WPARAM  wParam,
LPARAM  lParam 
)

Callback function for zoom sliders.

void TFEditDialog::OnRButtonUp ( UINT  nFlags,
CPoint  point 
)

Right mouse button release. Remove point, when mouse is on a opacity or color transfer function point

void TFEditDialog::RedrawColorAndOpacity (  )  [private]

Update the color and opacity transfer function window on main screen and redraw 2D and 3D views. This method should be called when the transfer function has been changed


Member Data Documentation

double TFEditDialog::m_Bottom [protected]

CStatic TFEditDialog::m_ColorControl [protected]

double TFEditDialog::m_Left [protected]

CPoint TFEditDialog::m_MousePos [private]

CStatic TFEditDialog::m_OpacityControl [protected]

double TFEditDialog::m_Right [protected]

double TFEditDialog::m_Top [protected]

const int TFEditDialog::MIN_X_ZOOM = 100 [static, private]

Minimum zoom range allowed in X direction

const int TFEditDialog::MIN_Y_ZOOM = 5 [static, private]

Minimum zoom range allowed in Y direction


The documentation for this class was generated from the following files:

Generated on Wed Dec 10 12:18:31 2008 for volRendering by  doxygen 1.5.7.1