TransferFunction Class Reference

#include <TransferFunction.h>

Collaboration diagram for TransferFunction:

Collaboration graph
[legend]
List of all members.

Detailed Description

TransferFunction: this class specifies the transfer function that is used for displaying the slices/volume the user can change this function in the CEditTransferFunction dialog

requirements
win98 or later
win2k or later
MFC
Version:
1.0 first version
Date:
12-09-2004
Author:
Johanna Beyer, Christoph Heinzl
license
This code is absolutely free to use and modify. The code is provided "as is" with no expressed or implied warranty. The author accepts no liability if it causes any damage to your computer, causes your pet to fall ill, increases baldness or makes your car start emitting strange noises when you start it up. This code has no bugs, just undocumented features!

:

:


Public Member Functions

 TransferFunction (CVisualize3DDoc *doc, int max)
void CreateTransferFunction (std::map< int, COLORREF > m, std::map< int, int > mOp)
unsigned short * GetTransferFunction ()
void ResetTF ()
void CreateWindowingFunction (int min, int max)
void CreateWindowingTransferFunction (std::map< int, COLORREF > m, std::map< int, int > mOp)

Private Types

typedef std::pair< int, COLORREF > tf_Pair
typedef std::pair< int, int > tf_OpPair

Private Member Functions

void CalcTF (int oldK, int newK, COLORREF oldV, COLORREF newV, int oldOp, int newOp)

Private Attributes

double ratio
int m_max
CVisualize3DDoc * m_doc
int startPos
int endPos
std::map< int, COLORREF > lastMap
std::map< int, int > lastOpMap
unsigned short * tf


Constructor & Destructor Documentation

TransferFunction::TransferFunction CVisualize3DDoc *  doc,
int  max
 

TransferFunction-Erstellung

Parameters:
doc 
max 
Returns:


Member Function Documentation

void TransferFunction::CalcTF int  oldK,
int  newK,
COLORREF  oldV,
COLORREF  newV,
int  oldOp,
int  newOp
[private]
 

interpolates colors and opacities between to specified points

Parameters:
oldK 
newK 
oldV 
newV 
oldOp 
newOp 

void TransferFunction::CreateTransferFunction std::map< int, COLORREF >  m,
std::map< int, int >  mOp
 

creates a transfer function of given input (entries with specified intensity value, color and opacity)

Parameters:
std::map<int 
m 
std::map<int 
mOp 

void TransferFunction::CreateWindowingFunction int  min,
int  max
 

does windowing (resets all values outside of window and calls CreateWindowingTransferFunction

Parameters:
min 
max 

void TransferFunction::CreateWindowingTransferFunction std::map< int, COLORREF >  m,
std::map< int, int >  mOp
 

creates the transfer function within the windowing window

Parameters:
std::map<int 
m 
std::map<int 
mOp 

unsigned short * TransferFunction::GetTransferFunction  ) 
 

Returns:
tf (transfer function array)

void TransferFunction::ResetTF  ) 
 

resets transfer function


Generated on Thu Dec 9 12:08:25 2004 for Visualize3D by doxygen 1.3.1 using KingsTools