#include <mitkImageModel.h>
Inherits mitkDataModel.
Inheritance diagram for mitkImageModel:


Public Types | |
| enum | ViewMode { VIEW_XY, VIEW_YZ, VIEW_XZ } |
Public Member Functions | |
| virtual void | PrintSelf (ostream &os) |
| void | SetData (mitkVolume *data) |
| mitkVolume * | GetData () |
| virtual int | Render (mitkScene *scene) |
| void | SetViewMode (ViewMode viewMode) |
| ViewMode | GetViewMode () const |
| void | SetCurrentSliceNumber (int sliceNo) |
| int | GetCurrentSliceNumber () const |
| void | NextSlice () |
| void | PrevSlice () |
| int | GetTotalSliceNumber () const |
| int | GetWidth () const |
| int | GetHeight () const |
| float | GetSpacingX () const |
| float | GetSpacingY () |
| float | GetSpacingZ () const |
| void | SetOpacity (float opacity) |
| float | GetOpacity () const |
| virtual bool | IsOpaque () |
| void | CleanUp () |
| void | AdjustWidthCenter (int viewWidth, int viewHeight, float deltX, float deltY) |
| float | GetWindowWidth () const |
| float | GetWindowCenter () const |
| void | SetWindowWidth (float winWidth) |
| void | SetWindowCenter (float winCenter) |
| void | ResetWindowWidthCenter () |
| void | GetDataValueAndCoordinate (float objectX, float objectY, int &vx, int &vy, int &vz, float &rValue, float &gValue, float &bValue) const |
| void | GetCoordinate (float objectX, float objectY, int &vx, int &vy, int &vz) const |
| void | GetXYCoordinate (float objectX, float objectY, int &vx, int &vy) const |
| void | GetXYCoordinate (float objectX, float objectY, float &vx, float &vy) const |
| void | GetXYCoordinateDelta (float odx, float ody, float &vdx, float &vdy) const |
| void | GetObjectCoordinate (int vx, int vy, float &objX, float &objY) |
| void | GetObjectCoordinate (int vx, int vy, int vz, float &objX, float &objY) |
| float | GetActualLength (float opt0[2], float opt1[2]) const |
| float | GetActualLength (float x0, float y0, float x1, float y1) const |
| float | GetActualXLength (float objXLen) const |
| float | GetActualYLength (float objYLen) const |
| unsigned int | GetTextureID () const |
| void | GetIncrements (int incs[3]) const |
| mitkVolume * | GetCurrentSlice () |
| void | EnablePseudocolor (bool enable=true) |
| void | UpdatePseudocolor (bool rectChanged) |
mitkImageModel is a concrete model class used to display a 2D image in mitkImageScene. It can access a volume as input and display it in image scene. To use it, the code snippet is:
mitkImageModel *aModel = new mitkImageModel; aModel->SetData(aVolume); // Set the volume to be displayed aModel->SetViewMode(mitkImageModel::VIEW_XY); aModel->SetCurrentSliceNumber(0); //Display the first slice aImageScene->AddModel(aModel); aImageScene->Update(); aModel->NextSlice(); //Display the next slice aImageScene->Update();
|
|
Set the view mode of a volume. z| y
| /
| /
| /
|/
o------------x
|
|
||||||||||||||||||||
|
Adjust the window width and window center of this image model
|
|
|
Internal function, Don't call it directly. |
|
|
Enable pseudo-color function.
|
|
||||||||||||||||||||
|
Get the actual length of the line in volume coordinate system at used specified object coordinate.
|
|
||||||||||||
|
Get the actual length of the line in volume coordinate system at used specified object coordinate.
|
|
|
Get the actual length of the line in volume coordinate system at used specified object coordinate along x-axis.
|
|
|
Get the actual length of the line in volume coordinate system at used specified object coordinate.
|
|
||||||||||||||||||||||||
|
Get the volume coordinate at a specified object coordinate.
|
|
|
Get data of the slice currently displayed.
|
|
|
Get the current slice number displayed in ImageView
|
|
|
Get the volume data.
|
|
||||||||||||||||||||||||||||||||||||
|
Get the data value and volume coordinate at a specified object coordinate.
|
|
|
Internal function, Don't call it directly. |
|
|
Get the increments in x, y and z directions according to current view mode.
|
|
||||||||||||||||||||||||
|
Get the coordinates in the object space according to the given volume coordinates.
|
|
||||||||||||||||||||
|
Get the coordinates in the object space according to the given volume coordinates.
|
|
|
Get the opacity of this model.
|
|
|
Internal function, Don't call it directly. |
|
|
Internal function, Don't call it directly. |
|
|
Internal function, Don't call it directly. |
|
|
Get the texture ID.
|
|
|
Display previous slice. If current slice is the first slice in the volume, then display the last slice. |
|
|
Get the view mode of the volume.
|
|
|
Internal function, Don't call it directly. |
|
|
Get the window center of this image model
|
|
|
Get the window width of this image model
|
|
||||||||||||||||||||
|
Get the X-Y volume coordinate at a specified object coordinate according to the view mode.
|
|
||||||||||||||||||||
|
Get the X-Y volume coordinate at a specified object coordinate according to the view mode.
|
|
||||||||||||||||||||
|
Get the movement in volume coordinate at a specified object coordinate according to the view mode.
|
|
|
Whether this model is opaque.
Implements mitkModel. |
|
|
Display next slice. If current slice is the last slice in the volume, then display the first slice. |
|
|
Display previous slice. If current slice is the first slice in the volume, then display the last slice. |
|
|
Print the necessary information about this object for the debugging purpose.
Reimplemented from mitkDataModel. |
|
|
Render this model.
Reimplemented from mitkModel. |
|
|
Reset the window width and center to the default value. |
|
|
Set the current slice number for displaying.
|
|
|
Set the volume data.
|
|
|
Set the opacity of this model.
|
|
|
Set the view mode of the volume.
|
|
|
Set the window center of this image model
|
|
|
Set the window width of this image model
|
|
|
Update pseudo-color region if the region is changed.
|
1.4.3