00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00022 #ifndef __vtkPVVolumeAppearanceEditor_h
00023 #define __vtkPVVolumeAppearanceEditor_h
00024
00025 #include "vtkPVTracedWidget.h"
00026
00027 class vtkKWPushButton;
00028 class vtkPVRenderView;
00029 class vtkPVSource;
00030 class vtkPVArrayInformation;
00031 class vtkPVVolumePropertyWidget;
00032 class vtkVolumeProperty;
00033 class vtkPVVolumeAppearanceEditorObserver;
00034
00035 class VTK_EXPORT vtkPVVolumeAppearanceEditor : public vtkPVTracedWidget
00036 {
00037 public:
00038 static vtkPVVolumeAppearanceEditor* New();
00039 vtkTypeRevisionMacro(vtkPVVolumeAppearanceEditor, vtkPVTracedWidget);
00040 void PrintSelf(ostream& os, vtkIndent indent);
00041
00043 virtual void Create(vtkKWApplication *app);
00044
00048 void BackButtonCallback();
00049
00051 void SetPVRenderView(vtkPVRenderView *view);
00052
00053 void Close();
00054
00061 virtual void UpdateEnableState();
00062
00063 void SetPVSourceAndArrayInfo(vtkPVSource *source,
00064 vtkPVArrayInformation *arrayInfo );
00065
00066 void VolumePropertyChangedCallback();
00067 void VolumePropertyChangingCallback();
00068
00070
00071 void SetScalarOpacityUnitDistance(double d);
00072 void SetColorSpace(int s);
00074
00076 void SetHSVWrap(int w);
00077
00079
00082 void AppendColorPoint(double s, double r, double g, double b);
00083 void RemoveAllColorPoints();
00085
00087
00090 void AppendScalarOpacityPoint(double scalar, double opacity);
00091 void RemoveAllScalarOpacityPoints();
00093
00095 void SaveState(ofstream *file);
00096
00098 void RefreshGUI();
00099
00100 protected:
00101 vtkPVVolumeAppearanceEditor();
00102 ~vtkPVVolumeAppearanceEditor();
00103
00104 vtkKWPushButton *BackButton;
00105
00106 vtkPVRenderView *PVRenderView;
00107
00108 vtkPVSource *PVSource;
00109 vtkPVArrayInformation *ArrayInfo;
00110
00111 void RenderView();
00112
00113 vtkPVVolumePropertyWidget *VolumePropertyWidget;
00114
00115
00116
00117
00118 vtkVolumeProperty *InternalVolumeProperty;
00119
00120 void VolumePropertyInternalCallback();
00121
00122
00123 void UpdateFromProxy();
00124
00125 vtkPVVolumeAppearanceEditorObserver* VolumeAppearanceObserver;
00126
00127 friend class vtkPVVolumeAppearanceEditorObserver;
00128
00129
00130 private:
00131 vtkPVVolumeAppearanceEditor(const vtkPVVolumeAppearanceEditor&);
00132 void operator=(const vtkPVVolumeAppearanceEditor&);
00133 };
00134
00135 #endif