30 #ifndef vtkSMTransferFunctionPresets_h 31 #define vtkSMTransferFunctionPresets_h 56 unsigned int GetNumberOfPresets();
62 std::string GetPresetAsString(
unsigned int index);
70 bool AddPreset(
const char* name,
const std::string& preset);
75 bool RemovePreset(
unsigned int index);
83 const Json::Value& GetFirstPresetWithName(
const char* name,
int& idx);
84 const Json::Value& GetFirstPresetWithName(
const char* name);
90 const Json::Value& GetPreset(
unsigned int index);
95 std::string GetPresetName(
unsigned int index);
100 bool HasPreset(
const char* name);
105 bool GetPresetHasOpacities(
const Json::Value& preset);
108 return this->GetPresetHasOpacities(this->GetPreset(index));
114 bool GetPresetHasIndexedColors(
const Json::Value& preset);
117 return this->GetPresetHasIndexedColors(this->GetPreset(index));
123 bool GetPresetHasAnnotations(
const Json::Value& preset);
126 return this->GetPresetHasAnnotations(this->GetPreset(index));
133 bool IsPresetDefault(
const Json::Value& preset);
140 bool SetPreset(
const char*
name,
const Json::Value& preset);
145 bool AddPreset(
const char* name,
const Json::Value& preset);
151 std::string AddUniquePreset(
const Json::Value& preset,
const char* prefix = NULL);
157 bool IsPresetBuiltin(
unsigned int index);
162 bool RenamePreset(
unsigned int index,
const char* newname);
171 bool ImportPresets(
const char* filename);
172 bool ImportPresets(
const Json::Value& presets);
178 void ReloadPresets();
189 vtkInternals* Internals;
bool IsPresetDefault(unsigned int index)
#define VTKREMOTINGVIEWS_EXPORT
bool GetPresetHasOpacities(unsigned int index)
manages presets for color, opacity, and annotation presets.
superclass for most server manager classes
bool GetPresetHasIndexedColors(unsigned int index)
bool GetPresetHasAnnotations(unsigned int index)
static vtkSMObject * New()
This is used by vtkPVXMLParser to represent an XML document starting at the root element.
void PrintSelf(ostream &os, vtkIndent indent) override