ImagePixelView Class Reference
[Views]

The class for a view of an 2 dimensional pixel image. More...

#include <image_pixel_view.h>

Inherits PixelView.

Inheritance diagram for ImagePixelView:

Inheritance graph
[legend]
Collaboration diagram for ImagePixelView:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 ImagePixelView ()
virtual ~ImagePixelView ()
view_pointer_type clone () const
virtual void setDataset (dataset_pointer_type dataset) throw (NullPointerException, InvalidCastException)
virtual double getMinPixelValue () const
virtual double getMaxPixelValue () const
virtual void setIntensity (double window, double level) throw (NullPointerException)
virtual double getIntensityWindow () const
virtual double getIntensityLevel () const
dataset_key_type getDatasetKey () const
dataset_position_type const & getSize () const
virtual void setParent (QWidget *view_parent) throw (NullPointerException)
void updateView () throw (NullPointerException)
virtual void onDataChangedEvent (dataset_attribute_type changed_attribute) throw (NullPointerException)
virtual void setFocusPoint2D (index_type dim_1, index_type dim_2) throw (NullPointerException)
ImedgineImageViewergetRenderArea ()
SoSeparator * getDynamicSceneSeparator () const
SoMaterial * getSliceDatasetMaterial ()
SoMaterial * getSliceSecondDatasetMaterial ()

Protected Member Functions

 ImagePixelView (ImagePixelView const &src)
virtual void createSceneGraph ()
virtual void drawCrosshair ()

Protected Attributes

image_pixel_dataset_pointer_type image_dataset_
 The dataset of this view.
std::auto_ptr< ImedgineImageViewerrender_area_
 The viewer that displays the slices.
SoOrthographicCamera * dynamic_camera_
SoSeparator * slice_separator_
SoMaterial * slice_dataset_material_
SoTexture2 * current_image_texture_
 Slice texture that is extracted from the dataset.
SoCube * slice_plane_
SoMaterial * slice_second_dataset_material_
SoTexture2 * current_second_image_texture_
SoCube * second_slice_plane_
SoSeparator * crosshair_sep_
SoBaseColor * crosshair_color_
 Color of the crosshair.
SoCoordinate3 * crosshair_coords_
 Point coordinates of the crosshair.
SoLineSet * crosshair_lines_
 Lines to draw the crosshair.

Detailed Description

The class for a view of an 2 dimensional pixel image.

Author:
Tobias Gross (tobias.gross@imedgine.org)

Christian Koerner (christian.koerner@imedgine.org)

Alexander Lex (alexander.lex@imedgine.org)

Marc Streit (marc.streit@imedgine.org)

Martin Reininger (martin.reininger@imedgine.org)

Definition at line 54 of file image_pixel_view.h.


Constructor & Destructor Documentation

ImagePixelView  ) 
 

Constructor

Definition at line 24 of file image_pixel_view.cpp.

References ImagePixelView::createSceneGraph().

Referenced by ImagePixelView::clone().

Here is the call graph for this function:

~ImagePixelView  )  [virtual]
 

Destructor

Definition at line 40 of file image_pixel_view.cpp.

ImagePixelView ImagePixelView const &  src  )  [protected]
 

Copy constructor

Definition at line 32 of file image_pixel_view.cpp.

References ImagePixelView::createSceneGraph().

Here is the call graph for this function:


Member Function Documentation

view_pointer_type clone  )  const [virtual]
 

Virtual Copy Constructor

Implements View.

Definition at line 46 of file image_pixel_view.cpp.

References ImagePixelView::ImagePixelView().

Here is the call graph for this function:

void createSceneGraph  )  [protected, virtual]
 

All scene graph nodes are created here. The method will be called in the constructor and the copy constructor (for view copies).

Reimplemented from View.

Definition at line 67 of file image_pixel_view.cpp.

References View::createSceneGraph(), ImagePixelView::crosshair_color_, ImagePixelView::crosshair_coords_, ImagePixelView::crosshair_lines_, ImagePixelView::crosshair_sep_, ImagePixelView::current_image_texture_, ImagePixelView::dynamic_camera_, View::dynamic_sep_, ImagePixelView::slice_dataset_material_, ImagePixelView::slice_plane_, and ImagePixelView::slice_separator_.

Referenced by ImagePixelView::ImagePixelView().

Here is the call graph for this function:

void drawCrosshair  )  [protected, virtual]
 

Draws the crosshair position at current focus position. This method is to be implemented differently by the concrete slice view implemenations in deriving classes.

Definition at line 314 of file image_pixel_view.cpp.

References ImagePixelView::crosshair_coords_, ImagePixelView::crosshair_lines_, ImagePixelView::image_dataset_, ImagePixelView::render_area_, X_DIMENSION, and Y_DIMENSION.

dataset_key_type getDatasetKey  )  const [virtual]
 

Get the key of the image or an empty string if it is not set.

Returns:
The key of the second dataset or ""

Implements PixelView.

Definition at line 53 of file image_pixel_view.cpp.

References ImagePixelView::image_dataset_.

Referenced by ImedgineImageViewer::updateDatasetStatusInfo().

double getIntensityLevel  )  const [virtual]
 

Returns the intensity level of the dataset displayed

Returns:
The intensity level

Implements PixelView.

Definition at line 270 of file image_pixel_view.cpp.

References ImagePixelView::image_dataset_.

double getIntensityWindow  )  const [virtual]
 

Returns the intensity window of the dataset displayed

Returns:
The intensity window

Implements PixelView.

Definition at line 259 of file image_pixel_view.cpp.

References ImagePixelView::image_dataset_.

double getMaxPixelValue  )  const [virtual]
 

Return the maximum pixel value of the dataset.

Returns:
The maximum pixel value of the dataset.

Implements PixelView.

Definition at line 233 of file image_pixel_view.cpp.

References ImagePixelView::image_dataset_.

Referenced by ImedgineImageViewer::ImedgineImageViewer().

double getMinPixelValue  )  const [virtual]
 

Return the mimimum pixel value of the dataset.

Returns:
The mimimum pixel value of the dataset.

Implements PixelView.

Definition at line 222 of file image_pixel_view.cpp.

References ImagePixelView::image_dataset_.

Referenced by ImedgineImageViewer::ImedgineImageViewer().

ImedgineImageViewer* getRenderArea  )  [inline]
 

Get the viewer that displays the slice images

Returns:
The render area of this view

Definition at line 177 of file image_pixel_view.h.

References ImagePixelView::render_area_.

Referenced by ImedgineImageViewer::convertCoordsFromScreenToTexture().

dataset_position_type const & getSize  )  const
 

Returns a vector storing the number of pixels in the two dimensions of the image

Returns:
The size of the dimensions of the image

Definition at line 164 of file image_pixel_view.cpp.

References ImagePixelView::image_dataset_.

Referenced by ImedgineImageViewer::convertCoordsFromScreenToTexture(), and ImedgineImageViewer::convertCoordsFromTextureToWorld().

void onDataChangedEvent dataset_attribute_type  changed_attribute  )  throw (NullPointerException) [virtual]
 

React to a change of dataset. In case of a different focus point redraw the crosshair and load a new slice.

Parameters:
changed_attribute The specification of the the dataset attribute that has been changed.

Reimplemented from View.

Definition at line 197 of file image_pixel_view.cpp.

void setDataset dataset_pointer_type  dataset  )  throw (NullPointerException, InvalidCastException) [virtual]
 

Set the dataset to display the slices from

Parameters:
dataset The dataset to set

Reimplemented from View.

Definition at line 121 of file image_pixel_view.cpp.

void setFocusPoint2D index_type  dim_1,
index_type  dim_2
throw (NullPointerException) [virtual]
 

Update the 2D focus point of the image and fire the dataset changed event of type DATASET_ATTRIBUTE_FOCUS_POINT.

Parameters:
dim_1 First dimension of the 2D focus point
dim_2 Second dimension of the 2D focus point

Definition at line 281 of file image_pixel_view.cpp.

References X_DIMENSION, and Y_DIMENSION.

void setIntensity double  window,
double  level
throw (NullPointerException) [virtual]
 

Set the intensity within the dataset by specifying the pixel value level and window

Parameters:
window The intensity window
level The intensity level

Implements PixelView.

Definition at line 244 of file image_pixel_view.cpp.

void setParent QWidget *  view_parent  )  throw (NullPointerException) [virtual]
 

Set the GUI parent element of this view

Parameters:
view_parent The GUI view parent

Reimplemented from View.

Definition at line 102 of file image_pixel_view.cpp.

References View::setParent().

Here is the call graph for this function:

void updateView  )  throw (NullPointerException) [virtual]
 

Re-render the current dataset

Implements View.

Definition at line 171 of file image_pixel_view.cpp.

References ImagePixelView::render_area_.


Member Data Documentation

SoSeparator* crosshair_sep_ [protected]
 

Crosshair separator that cointains all releavant scene graph nodes for the crosshair

Definition at line 253 of file image_pixel_view.h.

Referenced by ImagePixelView::createSceneGraph().

SoOrthographicCamera* dynamic_camera_ [protected]
 

Orthorgraphic camera that views the scene and that is taken by the ImdegineViewer to navigate in the scene.

Definition at line 224 of file image_pixel_view.h.

Referenced by ImagePixelView::createSceneGraph().

SoSeparator* slice_separator_ [protected]
 

Separator that cointains the plane and the texture of the slice

Definition at line 230 of file image_pixel_view.h.

Referenced by ImagePixelView::createSceneGraph().


The documentation for this class was generated from the following files:
Generated on Sun Aug 13 18:20:04 2006 for iMEDgine by  doxygen 1.4.6