00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00019 #ifndef __vtkKWVolumeMaterialPropertyWidget_h
00020 #define __vtkKWVolumeMaterialPropertyWidget_h
00021
00022 #include "vtkKWMaterialPropertyWidget.h"
00023
00024 class vtkKWApplication;
00025 class vtkKWCheckButtonWithLabel;
00026 class vtkKWScalarComponentSelectionWidget;
00027 class vtkVolumeProperty;
00028
00029 class KWWIDGETS_EXPORT vtkKWVolumeMaterialPropertyWidget : public vtkKWMaterialPropertyWidget
00030 {
00031 public:
00032 static vtkKWVolumeMaterialPropertyWidget *New();
00033 vtkTypeRevisionMacro(vtkKWVolumeMaterialPropertyWidget, vtkKWMaterialPropertyWidget);
00034 void PrintSelf(ostream& os, vtkIndent indent);
00035
00037 virtual void Create(vtkKWApplication *app);
00038
00040
00041 virtual void SetVolumeProperty(vtkVolumeProperty *prop);
00042 vtkGetObjectMacro(VolumeProperty, vtkVolumeProperty);
00044
00046
00047 virtual void SetSelectedComponent(int);
00048 vtkGetMacro(SelectedComponent, int);
00049 vtkGetObjectMacro(ComponentSelectionWidget,
00050 vtkKWScalarComponentSelectionWidget);
00052
00054
00055 virtual void SetNumberOfComponents(int);
00056 vtkGetMacro(NumberOfComponents, int);
00058
00060
00061 virtual void SetAllowEnableShading(int);
00062 vtkBooleanMacro(AllowEnableShading, int);
00063 vtkGetMacro(AllowEnableShading, int);
00065
00068 virtual void Update();
00069
00071
00072 virtual void EnableShadingCallback();
00073 virtual void SelectedComponentCallback(int);
00075
00082 virtual void UpdateEnableState();
00083
00084 protected:
00085
00086 vtkKWVolumeMaterialPropertyWidget();
00087 ~vtkKWVolumeMaterialPropertyWidget();
00088
00089 vtkVolumeProperty *VolumeProperty;
00090
00091 int SelectedComponent;
00092 int NumberOfComponents;
00093 int AllowEnableShading;
00094
00095
00096
00097 vtkKWScalarComponentSelectionWidget *ComponentSelectionWidget;
00098 vtkKWCheckButtonWithLabel *EnableShadingCheckButton;
00099
00101 virtual void Pack();
00102
00104
00106 virtual int UpdatePropertyFromInterface();
00107 virtual int UpdatePropertyFromPreset(const Preset *preset);
00109
00111 virtual void SendStateEvent(int event);
00112
00114 virtual int AreControlsEnabled();
00115
00116 private:
00117 vtkKWVolumeMaterialPropertyWidget(const vtkKWVolumeMaterialPropertyWidget&);
00118 void operator=(const vtkKWVolumeMaterialPropertyWidget&);
00119 };
00120
00121 #endif