VectorAttributes::LimitsMode VectorAttributes::GetLimitsMode() const { return LimitsMode(limitsMode); }
void VectorAttributes::SetFromNode(DataNode *parentNode) { if(parentNode == 0) return; DataNode *searchNode = parentNode->GetNode("VectorAttributes"); if(searchNode == 0) return; DataNode *node; if((node = searchNode->GetNode("glyphLocation")) != 0) { // Allow enums to be int or string in the config file if(node->GetNodeType() == INT_NODE) { int ival = node->AsInt(); if(ival >= 0 && ival < 2) SetGlyphLocation(GlyphLocation(ival)); } else if(node->GetNodeType() == STRING_NODE) { GlyphLocation value; if(GlyphLocation_FromString(node->AsString(), value)) SetGlyphLocation(value); } } if((node = searchNode->GetNode("useStride")) != 0) SetUseStride(node->AsBool()); if((node = searchNode->GetNode("stride")) != 0) SetStride(node->AsInt()); if((node = searchNode->GetNode("nVectors")) != 0) SetNVectors(node->AsInt()); if((node = searchNode->GetNode("lineStyle")) != 0) SetLineStyle(node->AsInt()); if((node = searchNode->GetNode("lineWidth")) != 0) SetLineWidth(node->AsInt()); if((node = searchNode->GetNode("scale")) != 0) SetScale(node->AsDouble()); if((node = searchNode->GetNode("scaleByMagnitude")) != 0) SetScaleByMagnitude(node->AsBool()); if((node = searchNode->GetNode("autoScale")) != 0) SetAutoScale(node->AsBool()); if((node = searchNode->GetNode("headSize")) != 0) SetHeadSize(node->AsDouble()); if((node = searchNode->GetNode("headOn")) != 0) SetHeadOn(node->AsBool()); if((node = searchNode->GetNode("colorByMag")) != 0) SetColorByMag(node->AsBool()); if((node = searchNode->GetNode("useLegend")) != 0) SetUseLegend(node->AsBool()); if((node = searchNode->GetNode("vectorColor")) != 0) vectorColor.SetFromNode(node); if((node = searchNode->GetNode("colorTableName")) != 0) SetColorTableName(node->AsString()); if((node = searchNode->GetNode("invertColorTable")) != 0) SetInvertColorTable(node->AsBool()); if((node = searchNode->GetNode("vectorOrigin")) != 0) { // Allow enums to be int or string in the config file if(node->GetNodeType() == INT_NODE) { int ival = node->AsInt(); if(ival >= 0 && ival < 3) SetVectorOrigin(OriginType(ival)); } else if(node->GetNodeType() == STRING_NODE) { OriginType value; if(OriginType_FromString(node->AsString(), value)) SetVectorOrigin(value); } } if((node = searchNode->GetNode("minFlag")) != 0) SetMinFlag(node->AsBool()); if((node = searchNode->GetNode("maxFlag")) != 0) SetMaxFlag(node->AsBool()); if((node = searchNode->GetNode("limitsMode")) != 0) { // Allow enums to be int or string in the config file if(node->GetNodeType() == INT_NODE) { int ival = node->AsInt(); if(ival >= 0 && ival < 2) SetLimitsMode(LimitsMode(ival)); } else if(node->GetNodeType() == STRING_NODE) { LimitsMode value; if(LimitsMode_FromString(node->AsString(), value)) SetLimitsMode(value); } } if((node = searchNode->GetNode("min")) != 0) SetMin(node->AsDouble()); if((node = searchNode->GetNode("max")) != 0) SetMax(node->AsDouble()); if((node = searchNode->GetNode("lineStem")) != 0) { // Allow enums to be int or string in the config file if(node->GetNodeType() == INT_NODE) { int ival = node->AsInt(); if(ival >= 0 && ival < 2) SetLineStem(LineStem(ival)); } else if(node->GetNodeType() == STRING_NODE) { LineStem value; if(LineStem_FromString(node->AsString(), value)) SetLineStem(value); } } if((node = searchNode->GetNode("geometryQuality")) != 0) { // Allow enums to be int or string in the config file if(node->GetNodeType() == INT_NODE) { int ival = node->AsInt(); if(ival >= 0 && ival < 2) SetGeometryQuality(Quality(ival)); } else if(node->GetNodeType() == STRING_NODE) { Quality value; if(Quality_FromString(node->AsString(), value)) SetGeometryQuality(value); } } if((node = searchNode->GetNode("stemWidth")) != 0) SetStemWidth(node->AsDouble()); if((node = searchNode->GetNode("origOnly")) != 0) SetOrigOnly(node->AsBool()); if((node = searchNode->GetNode("glyphType")) != 0) { // Allow enums to be int or string in the config file if(node->GetNodeType() == INT_NODE) { int ival = node->AsInt(); if(ival >= 0 && ival < 2) SetGlyphType(GlyphType(ival)); } else if(node->GetNodeType() == STRING_NODE) { GlyphType value; if(GlyphType_FromString(node->AsString(), value)) SetGlyphType(value); } } }
SurfaceFilterAttributes::LimitsMode SurfaceFilterAttributes::GetLimitsMode() const { return LimitsMode(limitsMode); }
void SurfaceFilterAttributes::SetFromNode(DataNode *parentNode) { if(parentNode == 0) return; DataNode *searchNode = parentNode->GetNode("SurfaceFilterAttributes"); if(searchNode == 0) return; DataNode *node; if((node = searchNode->GetNode("limitsMode")) != 0) { // Allow enums to be int or string in the config file if(node->GetNodeType() == INT_NODE) { int ival = node->AsInt(); if(ival >= 0 && ival < 2) SetLimitsMode(LimitsMode(ival)); } else if(node->GetNodeType() == STRING_NODE) { LimitsMode value; if(LimitsMode_FromString(node->AsString(), value)) SetLimitsMode(value); } } if((node = searchNode->GetNode("minFlag")) != 0) SetMinFlag(node->AsBool()); if((node = searchNode->GetNode("maxFlag")) != 0) SetMaxFlag(node->AsBool()); if((node = searchNode->GetNode("scaling")) != 0) { // Allow enums to be int or string in the config file if(node->GetNodeType() == INT_NODE) { int ival = node->AsInt(); if(ival >= 0 && ival < 3) SetScaling(Scaling(ival)); } else if(node->GetNodeType() == STRING_NODE) { Scaling value; if(Scaling_FromString(node->AsString(), value)) SetScaling(value); } } if((node = searchNode->GetNode("skewFactor")) != 0) SetSkewFactor(node->AsDouble()); if((node = searchNode->GetNode("min")) != 0) SetMin(node->AsDouble()); if((node = searchNode->GetNode("max")) != 0) SetMax(node->AsDouble()); if((node = searchNode->GetNode("zeroFlag")) != 0) SetZeroFlag(node->AsBool()); if((node = searchNode->GetNode("variable")) != 0) SetVariable(node->AsString()); if((node = searchNode->GetNode("useXYLimits")) != 0) SetUseXYLimits(node->AsBool()); if((node = searchNode->GetNode("generateNodalOutput")) != 0) SetGenerateNodalOutput(node->AsBool()); }
void SurfaceAttributes::SetFromNode(DataNode *parentNode) { if(parentNode == 0) return; DataNode *searchNode = parentNode->GetNode("SurfaceAttributes"); if(searchNode == 0) return; DataNode *node; if((node = searchNode->GetNode("legendFlag")) != 0) SetLegendFlag(node->AsBool()); if((node = searchNode->GetNode("lightingFlag")) != 0) SetLightingFlag(node->AsBool()); if((node = searchNode->GetNode("surfaceFlag")) != 0) SetSurfaceFlag(node->AsBool()); if((node = searchNode->GetNode("wireframeFlag")) != 0) SetWireframeFlag(node->AsBool()); if((node = searchNode->GetNode("limitsMode")) != 0) { // Allow enums to be int or string in the config file if(node->GetNodeType() == INT_NODE) { int ival = node->AsInt(); if(ival >= 0 && ival < 2) SetLimitsMode(LimitsMode(ival)); } else if(node->GetNodeType() == STRING_NODE) { LimitsMode value; if(LimitsMode_FromString(node->AsString(), value)) SetLimitsMode(value); } } if((node = searchNode->GetNode("minFlag")) != 0) SetMinFlag(node->AsBool()); if((node = searchNode->GetNode("maxFlag")) != 0) SetMaxFlag(node->AsBool()); if((node = searchNode->GetNode("colorByZFlag")) != 0) SetColorByZFlag(node->AsBool()); if((node = searchNode->GetNode("scaling")) != 0) { // Allow enums to be int or string in the config file if(node->GetNodeType() == INT_NODE) { int ival = node->AsInt(); if(ival >= 0 && ival < 3) SetScaling(Scaling(ival)); } else if(node->GetNodeType() == STRING_NODE) { Scaling value; if(Scaling_FromString(node->AsString(), value)) SetScaling(value); } } if((node = searchNode->GetNode("lineStyle")) != 0) SetLineStyle(node->AsInt()); if((node = searchNode->GetNode("lineWidth")) != 0) SetLineWidth(node->AsInt()); if((node = searchNode->GetNode("surfaceColor")) != 0) surfaceColor.SetFromNode(node); if((node = searchNode->GetNode("wireframeColor")) != 0) wireframeColor.SetFromNode(node); if((node = searchNode->GetNode("skewFactor")) != 0) SetSkewFactor(node->AsDouble()); if((node = searchNode->GetNode("min")) != 0) SetMin(node->AsDouble()); if((node = searchNode->GetNode("max")) != 0) SetMax(node->AsDouble()); if((node = searchNode->GetNode("colorTableName")) != 0) SetColorTableName(node->AsString()); if((node = searchNode->GetNode("invertColorTable")) != 0) SetInvertColorTable(node->AsBool()); }
void HistogramAttributes::SetFromNode(DataNode *parentNode) { if(parentNode == 0) return; DataNode *searchNode = parentNode->GetNode("HistogramAttributes"); if(searchNode == 0) return; DataNode *node; if((node = searchNode->GetNode("basedOn")) != 0) { // Allow enums to be int or string in the config file if(node->GetNodeType() == INT_NODE) { int ival = node->AsInt(); if(ival >= 0 && ival < 2) SetBasedOn(BasedOn(ival)); } else if(node->GetNodeType() == STRING_NODE) { BasedOn value; if(BasedOn_FromString(node->AsString(), value)) SetBasedOn(value); } } if((node = searchNode->GetNode("histogramType")) != 0) { // Allow enums to be int or string in the config file if(node->GetNodeType() == INT_NODE) { int ival = node->AsInt(); if(ival >= 0 && ival < 3) SetHistogramType(BinContribution(ival)); } else if(node->GetNodeType() == STRING_NODE) { BinContribution value; if(BinContribution_FromString(node->AsString(), value)) SetHistogramType(value); } } if((node = searchNode->GetNode("weightVariable")) != 0) SetWeightVariable(node->AsString()); if((node = searchNode->GetNode("limitsMode")) != 0) { // Allow enums to be int or string in the config file if(node->GetNodeType() == INT_NODE) { int ival = node->AsInt(); if(ival >= 0 && ival < 2) SetLimitsMode(LimitsMode(ival)); } else if(node->GetNodeType() == STRING_NODE) { LimitsMode value; if(LimitsMode_FromString(node->AsString(), value)) SetLimitsMode(value); } } if((node = searchNode->GetNode("minFlag")) != 0) SetMinFlag(node->AsBool()); if((node = searchNode->GetNode("maxFlag")) != 0) SetMaxFlag(node->AsBool()); if((node = searchNode->GetNode("min")) != 0) SetMin(node->AsDouble()); if((node = searchNode->GetNode("max")) != 0) SetMax(node->AsDouble()); if((node = searchNode->GetNode("numBins")) != 0) SetNumBins(node->AsInt()); if((node = searchNode->GetNode("domain")) != 0) SetDomain(node->AsInt()); if((node = searchNode->GetNode("zone")) != 0) SetZone(node->AsInt()); if((node = searchNode->GetNode("useBinWidths")) != 0) SetUseBinWidths(node->AsBool()); if((node = searchNode->GetNode("outputType")) != 0) { // Allow enums to be int or string in the config file if(node->GetNodeType() == INT_NODE) { int ival = node->AsInt(); if(ival >= 0 && ival < 2) SetOutputType(OutputType(ival)); } else if(node->GetNodeType() == STRING_NODE) { OutputType value; if(OutputType_FromString(node->AsString(), value)) SetOutputType(value); } } if((node = searchNode->GetNode("lineStyle")) != 0) SetLineStyle(node->AsInt()); if((node = searchNode->GetNode("lineWidth")) != 0) SetLineWidth(node->AsInt()); if((node = searchNode->GetNode("color")) != 0) color.SetFromNode(node); if((node = searchNode->GetNode("dataScale")) != 0) { // Allow enums to be int or string in the config file if(node->GetNodeType() == INT_NODE) { int ival = node->AsInt(); if(ival >= 0 && ival < 3) SetDataScale(DataScale(ival)); } else if(node->GetNodeType() == STRING_NODE) { DataScale value; if(DataScale_FromString(node->AsString(), value)) SetDataScale(value); } } if((node = searchNode->GetNode("binScale")) != 0) { // Allow enums to be int or string in the config file if(node->GetNodeType() == INT_NODE) { int ival = node->AsInt(); if(ival >= 0 && ival < 3) SetBinScale(DataScale(ival)); } else if(node->GetNodeType() == STRING_NODE) { DataScale value; if(DataScale_FromString(node->AsString(), value)) SetBinScale(value); } } if((node = searchNode->GetNode("normalizeHistogram")) != 0) SetNormalizeHistogram(node->AsBool()); if((node = searchNode->GetNode("computeAsCDF")) != 0) SetComputeAsCDF(node->AsBool()); }
HistogramAttributes::LimitsMode HistogramAttributes::GetLimitsMode() const { return LimitsMode(limitsMode); }