Program: wxMaracas
Module: $RCSfile: wxMaracas_N_ViewersWidget.cxx,v $
Language: C++
- Date: $Date: 2010/03/26 14:52:24 $
- Version: $Revision: 1.16 $
+ Date: $Date: 2010/05/03 13:46:48 $
+ Version: $Revision: 1.17 $
Copyright: (c) 2002, 2003
License:
//-----------------------------------------------------------------------------------
double wxMaracas_N_ViewersWidget :: GetX()
-{
+{
+ invariant();
return mvtkmprbasedata->GetX();
// return wxwindow1->GetX();
}
//-----------------------------------------------------------------------------------
double wxMaracas_N_ViewersWidget :: GetY()
{
+ invariant();
return mvtkmprbasedata->GetY();
// return wxwindow1->GetY();
}
//-----------------------------------------------------------------------------------
double wxMaracas_N_ViewersWidget :: GetZ()
{
+ invariant();
return mvtkmprbasedata->GetZ();
// return wxwindow1->GetZ();
}
+void wxMaracas_N_ViewersWidget :: invariant(){
+ if(mvtkmprbasedata == 0){
+ throw "The image has not been set in the viewer";
+ }
+}
+
void wxMaracas_N_ViewersWidget::setColorTransferFunction(vtkColorTransferFunction* colortable){
if (wxwindow1!=NULL) {
wxwindow1->setColorTransferFunction(colortable);