Commit 511b76b5 authored by allens's avatar allens

removed the option to optionally generate lines and points - going forward...

removed the option to optionally generate lines and points - going forward this will be handled in the pseudocolor plot

git-svn-id: http://visit.ilight.com/svn/visit/trunk/src@23719 18c085ea-50e0-402c-830e-de6fd14e8384
parent bcb31cac
......@@ -250,8 +250,6 @@ IntegralCurveAttributes::ChangesRequireRecalculation(const IntegralCurveAttribut
cropEndFlag != obj.cropEndFlag ||
cropEnd != obj.cropEnd ||
cropValue != obj.cropValue ||
showPoints != obj.showPoints ||
showLines != obj.showLines ||
pathlines != obj.pathlines ||
pathlinesOverrideStartingTimeFlag != obj.pathlinesOverrideStartingTimeFlag ||
pathlinesOverrideStartingTime != obj.pathlinesOverrideStartingTime ||
......
......@@ -240,12 +240,6 @@
<Field name="displayGeometry" label="Display geometry" type="enum" subtype="DisplayGeometry">
Lines
</Field>
<Field name="showLines" label="Show Lines" type="bool">
true
</Field>
<Field name="showPoints" label="Show Points" type="bool">
false
</Field>
<Field name="cropBeginFlag" label="Crop from" type="bool">
false
</Field>
......
......@@ -518,8 +518,6 @@ void IntegralCurveAttributes::Init()
pathlinesPeriod = 0;
pathlinesCMFE = POS_CMFE;
displayGeometry = Lines;
showLines = true;
showPoints = false;
cropBeginFlag = false;
cropBegin = 0;
cropEndFlag = false;
......@@ -633,8 +631,6 @@ void IntegralCurveAttributes::Copy(const IntegralCurveAttributes &obj)
pathlinesPeriod = obj.pathlinesPeriod;
pathlinesCMFE = obj.pathlinesCMFE;
displayGeometry = obj.displayGeometry;
showLines = obj.showLines;
showPoints = obj.showPoints;
cropBeginFlag = obj.cropBeginFlag;
cropBegin = obj.cropBegin;
cropEndFlag = obj.cropEndFlag;
......@@ -903,8 +899,6 @@ IntegralCurveAttributes::operator == (const IntegralCurveAttributes &obj) const
(pathlinesPeriod == obj.pathlinesPeriod) &&
(pathlinesCMFE == obj.pathlinesCMFE) &&
(displayGeometry == obj.displayGeometry) &&
(showLines == obj.showLines) &&
(showPoints == obj.showPoints) &&
(cropBeginFlag == obj.cropBeginFlag) &&
(cropBegin == obj.cropBegin) &&
(cropEndFlag == obj.cropEndFlag) &&
......@@ -1227,8 +1221,6 @@ IntegralCurveAttributes::SelectAll()
Select(ID_pathlinesPeriod, (void *)&pathlinesPeriod);
Select(ID_pathlinesCMFE, (void *)&pathlinesCMFE);
Select(ID_displayGeometry, (void *)&displayGeometry);
Select(ID_showLines, (void *)&showLines);
Select(ID_showPoints, (void *)&showPoints);
Select(ID_cropBeginFlag, (void *)&cropBeginFlag);
Select(ID_cropBegin, (void *)&cropBegin);
Select(ID_cropEndFlag, (void *)&cropEndFlag);
......@@ -1547,18 +1539,6 @@ IntegralCurveAttributes::CreateNode(DataNode *parentNode, bool completeSave, boo
node->AddNode(new DataNode("displayGeometry", DisplayGeometry_ToString(displayGeometry)));
}
if(completeSave || !FieldsEqual(ID_showLines, &defaultObject))
{
addToParent = true;
node->AddNode(new DataNode("showLines", showLines));
}
if(completeSave || !FieldsEqual(ID_showPoints, &defaultObject))
{
addToParent = true;
node->AddNode(new DataNode("showPoints", showPoints));
}
if(completeSave || !FieldsEqual(ID_cropBeginFlag, &defaultObject))
{
addToParent = true;
......@@ -1941,10 +1921,6 @@ IntegralCurveAttributes::SetFromNode(DataNode *parentNode)
SetDisplayGeometry(value);
}
}
if((node = searchNode->GetNode("showLines")) != 0)
SetShowLines(node->AsBool());
if((node = searchNode->GetNode("showPoints")) != 0)
SetShowPoints(node->AsBool());
if((node = searchNode->GetNode("cropBeginFlag")) != 0)
SetCropBeginFlag(node->AsBool());
if((node = searchNode->GetNode("cropBegin")) != 0)
......@@ -2348,20 +2324,6 @@ IntegralCurveAttributes::SetDisplayGeometry(IntegralCurveAttributes::DisplayGeom
Select(ID_displayGeometry, (void *)&displayGeometry);
}
void
IntegralCurveAttributes::SetShowLines(bool showLines_)
{
showLines = showLines_;
Select(ID_showLines, (void *)&showLines);
}
void
IntegralCurveAttributes::SetShowPoints(bool showPoints_)
{
showPoints = showPoints_;
Select(ID_showPoints, (void *)&showPoints);
}
void
IntegralCurveAttributes::SetCropBeginFlag(bool cropBeginFlag_)
{
......@@ -2850,18 +2812,6 @@ IntegralCurveAttributes::GetDisplayGeometry() const
return DisplayGeometry(displayGeometry);
}
bool
IntegralCurveAttributes::GetShowLines() const
{
return showLines;
}
bool
IntegralCurveAttributes::GetShowPoints() const
{
return showPoints;
}
bool
IntegralCurveAttributes::GetCropBeginFlag() const
{
......@@ -3144,8 +3094,6 @@ IntegralCurveAttributes::GetFieldName(int index) const
case ID_pathlinesPeriod: return "pathlinesPeriod";
case ID_pathlinesCMFE: return "pathlinesCMFE";
case ID_displayGeometry: return "displayGeometry";
case ID_showLines: return "showLines";
case ID_showPoints: return "showPoints";
case ID_cropBeginFlag: return "cropBeginFlag";
case ID_cropBegin: return "cropBegin";
case ID_cropEndFlag: return "cropEndFlag";
......@@ -3236,8 +3184,6 @@ IntegralCurveAttributes::GetFieldType(int index) const
case ID_pathlinesPeriod: return FieldType_double;
case ID_pathlinesCMFE: return FieldType_enum;
case ID_displayGeometry: return FieldType_enum;
case ID_showLines: return FieldType_bool;
case ID_showPoints: return FieldType_bool;
case ID_cropBeginFlag: return FieldType_bool;
case ID_cropBegin: return FieldType_double;
case ID_cropEndFlag: return FieldType_bool;
......@@ -3328,8 +3274,6 @@ IntegralCurveAttributes::GetFieldTypeName(int index) const
case ID_pathlinesPeriod: return "double";
case ID_pathlinesCMFE: return "enum";
case ID_displayGeometry: return "enum";
case ID_showLines: return "bool";
case ID_showPoints: return "bool";
case ID_cropBeginFlag: return "bool";
case ID_cropBegin: return "double";
case ID_cropEndFlag: return "bool";
......@@ -3643,16 +3587,6 @@ IntegralCurveAttributes::FieldsEqual(int index_, const AttributeGroup *rhs) cons
retval = (displayGeometry == obj.displayGeometry);
}
break;
case ID_showLines:
{ // new scope
retval = (showLines == obj.showLines);
}
break;
case ID_showPoints:
{ // new scope
retval = (showPoints == obj.showPoints);
}
break;
case ID_cropBeginFlag:
{ // new scope
retval = (cropBeginFlag == obj.cropBeginFlag);
......@@ -3846,8 +3780,6 @@ IntegralCurveAttributes::ChangesRequireRecalculation(const IntegralCurveAttribut
cropEndFlag != obj.cropEndFlag ||
cropEnd != obj.cropEnd ||
cropValue != obj.cropValue ||
showPoints != obj.showPoints ||
showLines != obj.showLines ||
pathlines != obj.pathlines ||
pathlinesOverrideStartingTimeFlag != obj.pathlinesOverrideStartingTimeFlag ||
pathlinesOverrideStartingTime != obj.pathlinesOverrideStartingTime ||
......
......@@ -222,8 +222,6 @@ public:
void SetPathlinesPeriod(double pathlinesPeriod_);
void SetPathlinesCMFE(PathlinesCMFE pathlinesCMFE_);
void SetDisplayGeometry(DisplayGeometry displayGeometry_);
void SetShowLines(bool showLines_);
void SetShowPoints(bool showPoints_);
void SetCropBeginFlag(bool cropBeginFlag_);
void SetCropBegin(double cropBegin_);
void SetCropEndFlag(bool cropEndFlag_);
......@@ -303,8 +301,6 @@ public:
double GetPathlinesPeriod() const;
PathlinesCMFE GetPathlinesCMFE() const;
DisplayGeometry GetDisplayGeometry() const;
bool GetShowLines() const;
bool GetShowPoints() const;
bool GetCropBeginFlag() const;
double GetCropBegin() const;
bool GetCropEndFlag() const;
......@@ -440,8 +436,6 @@ public:
ID_pathlinesPeriod,
ID_pathlinesCMFE,
ID_displayGeometry,
ID_showLines,
ID_showPoints,
ID_cropBeginFlag,
ID_cropBegin,
ID_cropEndFlag,
......@@ -512,8 +506,6 @@ private:
double pathlinesPeriod;
int pathlinesCMFE;
int displayGeometry;
bool showLines;
bool showPoints;
bool cropBeginFlag;
double cropBegin;
bool cropEndFlag;
......@@ -541,6 +533,6 @@ private:
static const char *TypeMapFormatString;
static const private_tmfs_t TmfsStruct;
};
#define INTEGRALCURVEATTRIBUTES_TMFS "iDDDDDDdDDbd*iiiisiibdbddbddiddidDiiiiibbddiibbbdbdidddbbiibbbbddddis"
#define INTEGRALCURVEATTRIBUTES_TMFS "iDDDDDDdDDbd*iiiisiibdbddbddiddidDiiiiibbddiibdbdidddbbiibbbbddddis"
#endif
......@@ -552,16 +552,6 @@ PyIntegralCurveAttributes_ToString(const IntegralCurveAttributes *atts, const ch
break;
}
if(atts->GetShowLines())
SNPRINTF(tmpStr, 1000, "%sshowLines = 1\n", prefix);
else
SNPRINTF(tmpStr, 1000, "%sshowLines = 0\n", prefix);
str += tmpStr;
if(atts->GetShowPoints())
SNPRINTF(tmpStr, 1000, "%sshowPoints = 1\n", prefix);
else
SNPRINTF(tmpStr, 1000, "%sshowPoints = 0\n", prefix);
str += tmpStr;
if(atts->GetCropBeginFlag())
SNPRINTF(tmpStr, 1000, "%scropBeginFlag = 1\n", prefix);
else
......@@ -2123,54 +2113,6 @@ IntegralCurveAttributes_GetDisplayGeometry(PyObject *self, PyObject *args)
return retval;
}
/*static*/ PyObject *
IntegralCurveAttributes_SetShowLines(PyObject *self, PyObject *args)
{
IntegralCurveAttributesObject *obj = (IntegralCurveAttributesObject *)self;
int ival;
if(!PyArg_ParseTuple(args, "i", &ival))
return NULL;
// Set the showLines in the object.
obj->data->SetShowLines(ival != 0);
Py_INCREF(Py_None);
return Py_None;
}
/*static*/ PyObject *
IntegralCurveAttributes_GetShowLines(PyObject *self, PyObject *args)
{
IntegralCurveAttributesObject *obj = (IntegralCurveAttributesObject *)self;
PyObject *retval = PyInt_FromLong(obj->data->GetShowLines()?1L:0L);
return retval;
}
/*static*/ PyObject *
IntegralCurveAttributes_SetShowPoints(PyObject *self, PyObject *args)
{
IntegralCurveAttributesObject *obj = (IntegralCurveAttributesObject *)self;
int ival;
if(!PyArg_ParseTuple(args, "i", &ival))
return NULL;
// Set the showPoints in the object.
obj->data->SetShowPoints(ival != 0);
Py_INCREF(Py_None);
return Py_None;
}
/*static*/ PyObject *
IntegralCurveAttributes_GetShowPoints(PyObject *self, PyObject *args)
{
IntegralCurveAttributesObject *obj = (IntegralCurveAttributesObject *)self;
PyObject *retval = PyInt_FromLong(obj->data->GetShowPoints()?1L:0L);
return retval;
}
/*static*/ PyObject *
IntegralCurveAttributes_SetCropBeginFlag(PyObject *self, PyObject *args)
{
......@@ -2809,10 +2751,6 @@ PyMethodDef PyIntegralCurveAttributes_methods[INTEGRALCURVEATTRIBUTES_NMETH] = {
{"GetPathlinesCMFE", IntegralCurveAttributes_GetPathlinesCMFE, METH_VARARGS},
{"SetDisplayGeometry", IntegralCurveAttributes_SetDisplayGeometry, METH_VARARGS},
{"GetDisplayGeometry", IntegralCurveAttributes_GetDisplayGeometry, METH_VARARGS},
{"SetShowLines", IntegralCurveAttributes_SetShowLines, METH_VARARGS},
{"GetShowLines", IntegralCurveAttributes_GetShowLines, METH_VARARGS},
{"SetShowPoints", IntegralCurveAttributes_SetShowPoints, METH_VARARGS},
{"GetShowPoints", IntegralCurveAttributes_GetShowPoints, METH_VARARGS},
{"SetCropBeginFlag", IntegralCurveAttributes_SetCropBeginFlag, METH_VARARGS},
{"GetCropBeginFlag", IntegralCurveAttributes_GetCropBeginFlag, METH_VARARGS},
{"SetCropBegin", IntegralCurveAttributes_SetCropBegin, METH_VARARGS},
......@@ -3072,10 +3010,6 @@ PyIntegralCurveAttributes_getattr(PyObject *self, char *name)
if(strcmp(name, "Ribbons") == 0)
return PyInt_FromLong(long(IntegralCurveAttributes::Ribbons));
if(strcmp(name, "showLines") == 0)
return IntegralCurveAttributes_GetShowLines(self, NULL);
if(strcmp(name, "showPoints") == 0)
return IntegralCurveAttributes_GetShowPoints(self, NULL);
if(strcmp(name, "cropBeginFlag") == 0)
return IntegralCurveAttributes_GetCropBeginFlag(self, NULL);
if(strcmp(name, "cropBegin") == 0)
......@@ -3234,10 +3168,6 @@ PyIntegralCurveAttributes_setattr(PyObject *self, char *name, PyObject *args)
obj = IntegralCurveAttributes_SetPathlinesCMFE(self, tuple);
else if(strcmp(name, "displayGeometry") == 0)
obj = IntegralCurveAttributes_SetDisplayGeometry(self, tuple);
else if(strcmp(name, "showLines") == 0)
obj = IntegralCurveAttributes_SetShowLines(self, tuple);
else if(strcmp(name, "showPoints") == 0)
obj = IntegralCurveAttributes_SetShowPoints(self, tuple);
else if(strcmp(name, "cropBeginFlag") == 0)
obj = IntegralCurveAttributes_SetCropBeginFlag(self, tuple);
else if(strcmp(name, "cropBegin") == 0)
......
......@@ -44,7 +44,7 @@
//
// Functions exposed to the VisIt module.
//
#define INTEGRALCURVEATTRIBUTES_NMETH 138
#define INTEGRALCURVEATTRIBUTES_NMETH 134
void PyIntegralCurveAttributes_StartUp(IntegralCurveAttributes *subj, void *data);
void PyIntegralCurveAttributes_CloseDown();
PyMethodDef * PyIntegralCurveAttributes_GetMethodTable(int *nMethods);
......
......@@ -804,61 +804,43 @@ QvisIntegralCurveWindow::CreateAppearanceTab(QWidget *pageAppearance)
connect(correlationDistanceMinDistEdit, SIGNAL(returnPressed()),
this, SLOT(processCorrelationDistanceMinDistEditText()));
// Create the display group box.
QGroupBox *displayGroup = new QGroupBox(central);
displayGroup->setTitle(tr("Display"));
mainLayout->addWidget(displayGroup, 1, 0);
QGridLayout *displayLayout = new QGridLayout(displayGroup);
displayLayout->setMargin(5);
displayLayout->setSpacing(10);
showLines = new QCheckBox(tr("Show lines"), displayGroup);
connect(showLines, SIGNAL(toggled(bool)),
this, SLOT(showLinesChanged(bool)));
displayLayout->addWidget(showLines, 0, 0);
showPoints = new QCheckBox(tr("Show points"), displayGroup);
connect(showPoints, SIGNAL(toggled(bool)), this,
SLOT(showPointsChanged(bool)));
displayLayout->addWidget(showPoints, 0, 1);
// Create the crop group
QGroupBox *cropGrp = new QGroupBox(pageAppearance);
cropGrp->setTitle(tr("Crop a portion of the integral curve (for animations)"));
cropGrp->setTitle(tr("Crop the integral curve (for animations)"));
mainLayout->addWidget(cropGrp, 3, 0);
QGridLayout *cropLayout = new QGridLayout(cropGrp);
cropLayout->setMargin(5);
cropLayout->setSpacing(10);
cropBeginFlag = new QCheckBox(tr("Crop from"), cropGrp);
QLabel *cropValueLabel = new QLabel(tr("Crop value"), cropGrp);
cropLayout->addWidget(cropValueLabel, 0, 0);
cropValueComboBox = new QComboBox(cropGrp);
cropValueComboBox->addItem(tr("Distance"));
cropValueComboBox->addItem(tr("Time"));
cropValueComboBox->addItem(tr("Step numbers"));
connect(cropValueComboBox, SIGNAL(activated(int)), this, SLOT(cropValueChanged(int)));
cropLayout->addWidget(cropValueComboBox, 0, 1);
cropBeginFlag = new QCheckBox(tr("From"), cropGrp);
connect(cropBeginFlag, SIGNAL(toggled(bool)), this, SLOT(cropBeginFlagChanged(bool)));
cropLayout->addWidget(cropBeginFlag, 0, 0);
cropLayout->addWidget(cropBeginFlag, 1, 0);
cropBegin = new QLineEdit(cropGrp);
connect(cropBegin, SIGNAL(returnPressed()), this, SLOT(cropBeginProcessText()));
cropLayout->addWidget(cropBegin, 0, 1);
cropLayout->addWidget(cropBegin, 1, 1);
cropEndFlag = new QCheckBox(tr("To"), cropGrp);
connect(cropEndFlag, SIGNAL(toggled(bool)), this, SLOT(cropEndFlagChanged(bool)));
cropLayout->addWidget(cropEndFlag, 0, 2);
cropLayout->addWidget(cropEndFlag, 1, 2);
cropEnd = new QLineEdit(cropGrp);
connect(cropEnd, SIGNAL(returnPressed()), this, SLOT(cropEndProcessText()));
cropLayout->addWidget(cropEnd, 0, 3);
QLabel *cropValueLabel = new QLabel(tr("Crop value"), cropGrp);
cropLayout->addWidget(cropValueLabel, 1, 0);
cropValueComboBox = new QComboBox(cropGrp);
cropValueComboBox->addItem(tr("Distance"));
cropValueComboBox->addItem(tr("Time"));
cropValueComboBox->addItem(tr("Step numbers"));
connect(cropValueComboBox, SIGNAL(activated(int)), this, SLOT(cropValueChanged(int)));
cropLayout->addWidget(cropValueComboBox, 1, 1);
cropLayout->addWidget(cropEnd, 1, 3);
// Streamlines/Pathline Group.
QGroupBox *icGrp = new QGroupBox(pageAppearance);
......@@ -1326,17 +1308,6 @@ QvisIntegralCurveWindow::UpdateWindow(bool doAll)
TurnOff(correlationDistanceMinDistType);
}
break;
case IntegralCurveAttributes::ID_showLines:
showLines->blockSignals(true);
showLines->setChecked(atts->GetShowLines());
showLines->blockSignals(false);
break;
case IntegralCurveAttributes::ID_showPoints:
showPoints->blockSignals(true);
showPoints->setChecked(atts->GetShowPoints());
showPoints->blockSignals(false);
break;
case IntegralCurveAttributes::ID_cropBeginFlag:
cropBeginFlag->blockSignals(true);
......@@ -2903,20 +2874,6 @@ QvisIntegralCurveWindow::cropValueChanged(int val)
Apply();
}
void
QvisIntegralCurveWindow::showLinesChanged(bool val)
{
atts->SetShowLines(val);
Apply();
}
void
QvisIntegralCurveWindow::showPointsChanged(bool val)
{
atts->SetShowPoints(val);
Apply();
}
void
QvisIntegralCurveWindow::useWholeBoxChanged(bool val)
{
......
......@@ -255,9 +255,6 @@ class QvisIntegralCurveWindow : public QvisOperatorWindow
void cropEndProcessText();
void cropValueChanged(int val);
void showLinesChanged(bool val);
void showPointsChanged(bool val);
// Advanced
void parallelAlgorithmChanged(int val);
void maxSLCountChanged(int val);
......@@ -360,9 +357,6 @@ class QvisIntegralCurveWindow : public QvisOperatorWindow
QLineEdit *cropEnd;
QComboBox *cropValueComboBox;
QCheckBox *showLines;
QCheckBox *showPoints;
// Advanced
QLabel *parallelAlgoLabel;
QComboBox *parallelAlgo;
......
......@@ -92,23 +92,25 @@ CreateVTKVertex(double p[3], double val,
std::vector< std::string > secondaryVariables,
double *secondaryVals )
{
vtkPoints *pt = vtkPoints::New();
pt->SetNumberOfPoints(1);
pt->SetPoint(0, p[0], p[1], p[2]);
vtkPolyData *pd = vtkPolyData::New();
vtkPoints *points = vtkPoints::New();
points->SetNumberOfPoints(1);
points->SetPoint(0, p[0], p[1], p[2]);
vtkPolyData *point = vtkPolyData::New();
point->SetPoints(pt);
pt->Delete();
pd->SetPoints(points);
points->Delete();
vtkIdType ids[1] = {0};
point->Allocate(1);
point->InsertNextCell(VTK_VERTEX, 1, ids);
pd->Allocate(1);
pd->InsertNextCell(VTK_VERTEX, 1, ids);
vtkFloatArray *arr = vtkFloatArray::New();
arr->SetName("colorVar");
arr->SetNumberOfTuples(1);
arr->SetTuple1(0, val);
point->GetPointData()->SetScalars(arr);
pd->GetPointData()->SetScalars(arr);
arr->Delete();
// secondary scalars
......@@ -118,11 +120,12 @@ CreateVTKVertex(double p[3], double val,
secondary->SetName(secondaryVariables[i].c_str());
secondary->SetNumberOfTuples(1);
secondary->SetTuple1(0, secondaryVals[i]);
point->GetPointData()->AddArray(secondary);
pd->GetPointData()->AddArray(secondary);
secondary->Delete();
}
return point;
return pd;
}
......@@ -2599,16 +2602,16 @@ avtIntegralCurveFilter::CreateIntegralCurveOutput(std::vector<avtIntegralCurve *
for( unsigned int i=0; i<secondaryVariables.size(); ++i )
secondarys[i]->InsertTuple1(pIdx, s.secondarys[i]);
if( atts.GetShowPoints() )
{
double pt[3] = {s.position.x, s.position.y, s.position.z};
// if( atts.GetShowPoints() )
// {
// double pt[3] = {s.position.x, s.position.y, s.position.z};
vtkPolyData *vert = CreateVTKVertex(pt, data_value,
secondaryVariables,
s.secondarys );
append->AddInputData(vert);
vert->Delete();
}
// vtkPolyData *vert = CreateVTKVertex(pt, data_value,
// secondaryVariables,
// s.secondarys );
// append->AddInputData(vert);
// vert->Delete();
// }
pIdx++;
}
......@@ -2702,8 +2705,8 @@ avtIntegralCurveFilter::CreateIntegralCurveOutput(std::vector<avtIntegralCurve *
for( unsigned int i=0; i<secondaryVariables.size(); ++i )
secondarys[i]->Delete();
if( atts.GetShowLines() )
{
// if( atts.GetShowLines() )
// {
vtkCleanPolyData *clean = vtkCleanPolyData::New();
clean->ConvertLinesToPointsOff();
clean->ConvertPolysToLinesOff();
......@@ -2716,9 +2719,9 @@ avtIntegralCurveFilter::CreateIntegralCurveOutput(std::vector<avtIntegralCurve *
vtkPolyData *cleanPD = clean->GetOutput();
append->AddInputData(cleanPD);
cleanPD->Delete();
}
else
pd->Delete();
// }
// else
// pd->Delete();
append->Update();
vtkPolyData *outPD = append->GetOutput();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment