Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

vu1512 Class Reference

The base class for bcc unimodal 3d data in the vuVolume data tree. More...

#include <3d.h>

Inheritance diagram for vu1512:

Inheritance graph
[legend]
Collaboration diagram for vu1512:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 vu1512 ()
 The default constructor.
 vu1512 (const vu1512 &inst)
 The copy constructor.
vu1512operator= (const vu1512 &rhs)
 The assignment operator.
dword getDim1Size (void) const
 Returns the size of the data along the first dimension.
dword getDim2Size (void) const
 Returns the size of the data along the second dimension.
dword getDim3Size (void) const
 Returns the size of the data along the third dimension.
dword getSpacing (void) const
 Returns the spacing of the 3d grid.
int getDim1Origin (void) const
 Returns the origin of the data in the first dimension.
int getDim2Origin (void) const
 Returns the origin of the data in the second dimension.
int getDim3Origin (void) const
 Returns the origin of the data in the third dimension.
vuVector getVoxelPosition (int x, int y, int z) const
 Returns the position of a point of given index.
vuVector getCenter () const
 returns the center of the dataset (virtual in volume.h)
void preview (int hint=0)
 draws an OpenGl cube

Protected Member Functions

virtual bool read (FILE *file)
 Asserts that the file is 3d data and reads the associated information.
virtual bool write (FILE *file)
 Writes the general 3d data information toe file.

Protected Attributes

dword m_Dim1Size
 The size of the data set in the first dimension.
dword m_Dim2Size
 The size of the data set in the second dimension.
dword m_Dim3Size
 The size of the data set in the third dimension.
dword m_Spacing
 The spacing of the grid.
int m_Dim1Origin
 The origin of the data set in the first dimension.
int m_Dim2Origin
 The origin of the data set in the second dimension.
int m_Dim3Origin
 The origin of the data set in the third dimension.

Static Protected Attributes

const float T = 1.41421356

Private Member Functions

void drawBox (float sx, float sy, float sz)

Detailed Description

The base class for bcc unimodal 3d data in the vuVolume data tree.

Definition at line 10 of file BCC/Unimodal/3d/3d.h.


Constructor & Destructor Documentation

vu1512::vu1512  ) 
 

The default constructor.

Definition at line 10 of file BCC/Unimodal/3d/3d.cpp.

References m_Dim1Origin, m_Dim1Size, m_Dim2Origin, m_Dim2Size, m_Dim3Origin, m_Dim3Size, and m_Spacing.

vu1512::vu1512 const vu1512 inst  ) 
 

The copy constructor.

Definition at line 27 of file BCC/Unimodal/3d/3d.cpp.

References m_Dim1Origin, m_Dim1Size, m_Dim2Origin, m_Dim2Size, m_Dim3Origin, m_Dim3Size, and m_Spacing.


Member Function Documentation

void vu1512::drawBox float  sx,
float  sy,
float  sz
[private]
 

Definition at line 237 of file BCC/Unimodal/3d/3d.cpp.

References getCenter(), GL_LINE_LOOP, glBegin(), glColor3fv(), glEnd(), GLfloat, GLint, glNormal3fv(), glTranslatef(), and glVertex3fv().

Referenced by preview().

Here is the call graph for this function:

vuVector vu1512::getCenter  )  const [inline, virtual]
 

returns the center of the dataset (virtual in volume.h)

Reimplemented from vu1.

Definition at line 47 of file BCC/Unimodal/3d/3d.h.

References getVoxelPosition(), m_Dim1Size, m_Dim2Size, and m_Dim3Size.

Referenced by drawBox(), vu1512113::read(), and vu1512122::read().

Here is the call graph for this function:

int vu1512::getDim1Origin void   )  const
 

Returns the origin of the data in the first dimension.

Definition at line 86 of file BCC/Unimodal/3d/3d.cpp.

dword vu1512::getDim1Size void   )  const
 

Returns the size of the data along the first dimension.

Definition at line 66 of file BCC/Unimodal/3d/3d.cpp.

References dword.

Referenced by vuBccSplat::glRender(), vuBCCMarchingTetrahedra::glRender(), vuBccSplat::glResize(), vuBCCSheetSplatter::glResize(), and vuBCCMarchingTetrahedra::glResize().

int vu1512::getDim2Origin void   )  const
 

Returns the origin of the data in the second dimension.

Definition at line 91 of file BCC/Unimodal/3d/3d.cpp.

dword vu1512::getDim2Size void   )  const
 

Returns the size of the data along the second dimension.

Definition at line 71 of file BCC/Unimodal/3d/3d.cpp.

References dword.

Referenced by vuBccSplat::glRender(), vuBCCMarchingTetrahedra::glRender(), vuBccSplat::glResize(), vuBCCSheetSplatter::glResize(), and vuBCCMarchingTetrahedra::glResize().

int vu1512::getDim3Origin void   )  const
 

Returns the origin of the data in the third dimension.

Definition at line 96 of file BCC/Unimodal/3d/3d.cpp.

dword vu1512::getDim3Size void   )  const
 

Returns the size of the data along the third dimension.

Definition at line 76 of file BCC/Unimodal/3d/3d.cpp.

References dword.

Referenced by vuBccSplat::glRender(), vuBCCMarchingTetrahedra::glRender(), vuBccSplat::glResize(), vuBCCSheetSplatter::glResize(), and vuBCCMarchingTetrahedra::glResize().

dword vu1512::getSpacing void   )  const
 

Returns the spacing of the 3d grid.

This is the spacing between the data values in each of the dimensions. This value is uniform in all dimensions since this is a bcc grid.

Definition at line 81 of file BCC/Unimodal/3d/3d.cpp.

References dword.

vuVector vu1512::getVoxelPosition int  x,
int  y,
int  z
const
 

Returns the position of a point of given index.

The position is relative to a cube of size getDim1Size x getDim2Size x getDim3Size.

Definition at line 179 of file BCC/Unimodal/3d/3d.cpp.

References T.

Referenced by getCenter(), preview(), vu1512112::read(), vu1512112::readRaw(), and vu1512112::sortByDistance().

vu1512 & vu1512::operator= const vu1512 rhs  ) 
 

The assignment operator.

Definition at line 44 of file BCC/Unimodal/3d/3d.cpp.

References m_Dim1Origin, m_Dim1Size, m_Dim2Origin, m_Dim2Size, m_Dim3Origin, m_Dim3Size, m_Spacing, and vu1::operator=().

Referenced by vu1512111::operator=(), vu1512112::operator=(), vu1512113::operator=(), vu1512121::operator=(), and vu1512122::operator=().

Here is the call graph for this function:

void vu1512::preview int  hint = 0  )  [virtual]
 

draws an OpenGl cube

Reimplemented from vu1.

Definition at line 197 of file BCC/Unimodal/3d/3d.cpp.

References drawBox(), dword, vu1::getCameraPtr(), vuCamera::getHeight(), getVoxelPosition(), vuCamera::getWidth(), GL_COLOR_BUFFER_BIT, GL_DEPTH_BUFFER_BIT, GL_DEPTH_TEST, GL_LESS, GL_MODELVIEW, GL_PROJECTION, glClear(), glDepthFunc(), glEnable(), vuCamera::glInit(), glLoadIdentity(), glMatrixMode(), vuCamera::gluLookAt(), vuCamera::glViewport(), m_Dim1Size, m_Dim2Size, and m_Dim3Size.

Here is the call graph for this function:

bool vu1512::read FILE *  file  )  [protected, virtual]
 

Asserts that the file is 3d data and reads the associated information.

This method reads in the general information for 3d data sets. It also asserts whether the data is indeed 3d or not.

Returns:
True if successful (data is bcc), false otherwise.

Reimplemented from vu151.

Reimplemented in vu15121.

Definition at line 105 of file BCC/Unimodal/3d/3d.cpp.

References dword, m_Dim1Origin, m_Dim1Size, m_Dim2Origin, m_Dim2Size, m_Dim3Origin, m_Dim3Size, m_Spacing, vu1::read(), and vu1::setInvalidFormatError().

Here is the call graph for this function:

bool vu1512::write FILE *  file  )  [protected, virtual]
 

Writes the general 3d data information toe file.

Returns:
True if successful, false otherwise.

Reimplemented from vu151.

Reimplemented in vu15121.

Definition at line 149 of file BCC/Unimodal/3d/3d.cpp.

References dword, m_Dim1Origin, m_Dim1Size, m_Dim2Origin, m_Dim2Size, m_Dim3Origin, m_Dim3Size, m_Spacing, vu1::setWriteError(), and vu1::write().

Here is the call graph for this function:


Member Data Documentation

int vu1512::m_Dim1Origin [protected]
 

The origin of the data set in the first dimension.

Definition at line 77 of file BCC/Unimodal/3d/3d.h.

Referenced by operator=(), read(), vu1512(), and write().

dword vu1512::m_Dim1Size [protected]
 

The size of the data set in the first dimension.

Definition at line 67 of file BCC/Unimodal/3d/3d.h.

Referenced by getCenter(), operator=(), preview(), read(), vu1512(), and write().

int vu1512::m_Dim2Origin [protected]
 

The origin of the data set in the second dimension.

Definition at line 79 of file BCC/Unimodal/3d/3d.h.

Referenced by operator=(), read(), vu1512(), and write().

dword vu1512::m_Dim2Size [protected]
 

The size of the data set in the second dimension.

Definition at line 69 of file BCC/Unimodal/3d/3d.h.

Referenced by getCenter(), operator=(), preview(), read(), vu1512(), and write().

int vu1512::m_Dim3Origin [protected]
 

The origin of the data set in the third dimension.

Definition at line 81 of file BCC/Unimodal/3d/3d.h.

Referenced by operator=(), read(), vu1512(), and write().

dword vu1512::m_Dim3Size [protected]
 

The size of the data set in the third dimension.

Definition at line 71 of file BCC/Unimodal/3d/3d.h.

Referenced by getCenter(), operator=(), preview(), read(), vu1512(), and write().

dword vu1512::m_Spacing [protected]
 

The spacing of the grid.

Definition at line 74 of file BCC/Unimodal/3d/3d.h.

Referenced by operator=(), read(), vu1512(), and write().

const float vu1512::T = 1.41421356 [static, protected]
 

Definition at line 63 of file BCC/Unimodal/3d/3d.h.

Referenced by getVoxelPosition().


The documentation for this class was generated from the following files:
Generated on Wed Dec 15 21:21:08 2004 for vuVolume by  doxygen 1.3.9.1