Commit 456084b1 authored by hrchilds's avatar hrchilds
Browse files

Update from March 16, 2005

git-svn-id: http://visit.ilight.com/svn/visit/trunk/src@432 18c085ea-50e0-402c-830e-de6fd14e8384
parent bf718f7f
......@@ -126,7 +126,7 @@ QueryList::Groups_FromString(const std::string &s, QueryList::Groups &val)
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Wed Dec 15 17:09:04 PST 2004
// Creation: Tue Mar 15 17:06:58 PST 2005
//
// Modifications:
//
......@@ -145,7 +145,7 @@ QueryList::QueryList() : AttributeSubject("s*i*i*i*i*i*i*")
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Wed Dec 15 17:09:04 PST 2004
// Creation: Tue Mar 15 17:06:58 PST 2005
//
// Modifications:
//
......@@ -173,7 +173,7 @@ QueryList::QueryList(const QueryList &obj) : AttributeSubject("s*i*i*i*i*i*i*")
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Wed Dec 15 17:09:04 PST 2004
// Creation: Tue Mar 15 17:06:58 PST 2005
//
// Modifications:
//
......@@ -193,7 +193,7 @@ QueryList::~QueryList()
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Wed Dec 15 17:09:04 PST 2004
// Creation: Tue Mar 15 17:06:58 PST 2005
//
// Modifications:
//
......@@ -224,7 +224,7 @@ QueryList::operator = (const QueryList &obj)
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Wed Dec 15 17:09:04 PST 2004
// Creation: Tue Mar 15 17:06:58 PST 2005
//
// Modifications:
//
......@@ -252,7 +252,7 @@ QueryList::operator == (const QueryList &obj) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Wed Dec 15 17:09:04 PST 2004
// Creation: Tue Mar 15 17:06:58 PST 2005
//
// Modifications:
//
......@@ -273,7 +273,7 @@ QueryList::operator != (const QueryList &obj) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Wed Dec 15 17:09:04 PST 2004
// Creation: Tue Mar 15 17:06:58 PST 2005
//
// Modifications:
//
......@@ -294,7 +294,7 @@ QueryList::TypeName() const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Wed Dec 15 17:09:04 PST 2004
// Creation: Tue Mar 15 17:06:58 PST 2005
//
// Modifications:
//
......@@ -322,7 +322,7 @@ QueryList::CopyAttributes(const AttributeGroup *atts)
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Wed Dec 15 17:09:04 PST 2004
// Creation: Tue Mar 15 17:06:58 PST 2005
//
// Modifications:
//
......@@ -348,7 +348,7 @@ QueryList::CreateCompatible(const std::string &tname) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Wed Dec 15 17:09:04 PST 2004
// Creation: Tue Mar 15 17:06:58 PST 2005
//
// Modifications:
//
......@@ -375,7 +375,7 @@ QueryList::NewInstance(bool copy) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Wed Dec 15 17:09:04 PST 2004
// Creation: Tue Mar 15 17:06:58 PST 2005
//
// Modifications:
//
......@@ -406,7 +406,7 @@ QueryList::SelectAll()
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Wed Dec 15 17:09:04 PST 2004
// Creation: Tue Mar 15 17:06:58 PST 2005
//
// Modifications:
//
......@@ -484,7 +484,7 @@ QueryList::CreateNode(DataNode *parentNode, bool completeSave, bool forceAdd)
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Wed Dec 15 17:09:04 PST 2004
// Creation: Tue Mar 15 17:06:58 PST 2005
//
// Modifications:
//
......@@ -718,7 +718,7 @@ QueryList::SelectTimeQuery()
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Wed Dec 15 17:09:04 PST 2004
// Creation: Tue Mar 15 17:06:58 PST 2005
//
// Modifications:
//
......@@ -749,7 +749,7 @@ QueryList::GetFieldName(int index) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Wed Dec 15 17:09:04 PST 2004
// Creation: Tue Mar 15 17:06:58 PST 2005
//
// Modifications:
//
......@@ -780,7 +780,7 @@ QueryList::GetFieldType(int index) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Wed Dec 15 17:09:04 PST 2004
// Creation: Tue Mar 15 17:06:58 PST 2005
//
// Modifications:
//
......@@ -811,7 +811,7 @@ QueryList::GetFieldTypeName(int index) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Wed Dec 15 17:09:04 PST 2004
// Creation: Tue Mar 15 17:06:58 PST 2005
//
// Modifications:
//
......@@ -1010,3 +1010,30 @@ QueryList::TimeQueryAvailable(const std::string &name)
return canDoTime;
}
// ****************************************************************************
// Method: GetWindowType
//
// Purpose:
// Returns the window type for the named query.
//
// Programmer: Kathleen Bonnell
// Creation: March 15, 2005
//
// ****************************************************************************
int
QueryList::GetWindowType(const std::string &name)
{
int i;
int wt = -1;
for (i = 0; i < names.size(); i++)
{
if (name == names[i])
{
wt = winType[i];
break;
}
}
return wt;
}
......@@ -154,3 +154,34 @@ QueryList::TimeQueryAvailable(const std::string &name)
return canDoTime;
}
Function: GetWindowType
Declaration: int GetWindowType(const std::string &name) ;
Definition:
// ****************************************************************************
// Method: GetWindowType
//
// Purpose:
// Returns the window type for the named query.
//
// Programmer: Kathleen Bonnell
// Creation: March 15, 2005
//
// ****************************************************************************
int
QueryList::GetWindowType(const std::string &name)
{
int i;
int wt = -1;
for (i = 0; i < names.size(); i++)
{
if (name == names[i])
{
wt = winType[i];
break;
}
}
return wt;
}
......@@ -13,7 +13,7 @@
// Notes: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Wed Dec 15 17:09:04 PST 2004
// Creation: Tue Mar 15 17:06:58 PST 2005
//
// Modifications:
//
......@@ -130,6 +130,7 @@ public:
int NumberOfInputsForQuery(const std::string &name);
int AllowedVarsForQuery(const std::string &name);
bool TimeQueryAvailable(const std::string &name) ;
int GetWindowType(const std::string &name) ;
private:
stringVector names;
intVector types;
......
......@@ -47,4 +47,6 @@
</Function>
<Function name="TimeQueryAvailable" user="true" member="true">
</Function>
<Function name="GetWindowType" user="true" member="true">
</Function>
</Attribute>
......@@ -77,6 +77,10 @@ avtTimeLoopFilter::~avtTimeLoopFilter()
// Hank Childs, Fri Mar 4 09:41:53 PST 2005
// Don't do dynamic load balancing with time queries.
//
// Kathleen Bonnell, Tue Mar 15 17:41:26 PST 2005
// Update Queryable source at end, to ensure the pipeline is in the same
// state as when we began.
//
// ****************************************************************************
bool
......@@ -141,6 +145,11 @@ avtTimeLoopFilter::Update(avtPipelineSpecification_p spec)
CreateFinalOutput();
RefashionDataObjectInfo();
//
// Ensure the pipeline is in the same state as when we began.
//
GetInput()->GetQueryableSource()->GetOutput()->Update(spec);
return modified;
}
......
......@@ -54,6 +54,13 @@ avtL2NormQuery::~avtL2NormQuery()
// Programmer: Hank Childs
// Creation: October 3, 2003
//
// Modifications:
//
// Hank Childs, Tue Mar 15 15:43:31 PST 2005
// The assumption that x-coords won't be duplicated came from the original
// implementation of this query -- the L2-norm between curves query. That
// assumption is not true for this query, so add explicit checking.
//
// ****************************************************************************
double
......@@ -69,8 +76,13 @@ avtL2NormQuery::CurveQuery(int n1, const float *x1, const float *y1)
pt2[0] = x1[i+1];
pt2[1] = y1[i+1];
// Degeneracies like this can occur from lineouts due to numerical
// sensititives. They also can be in a file from a database (like
// a pre-existing degeneracy in an Ultra file).
if (pt1[0] == pt2[0])
continue;
// Calculate the line in f(x) = mx+b notation.
// Note that pt1[0] != pt2[0] because we threw out duplicated points.
double rise = pt2[1] - pt1[1];
double run = pt2[0] - pt1[0];
double m = rise / run;
......
......@@ -10,6 +10,10 @@
// Programmer: Kathleen Bonnell
// Creation: March 18, 2004
//
// Modifications:
// Kathleen Bonnell, Tue Mar 15 17:41:26 PST 2005
// Initialize clone.
//
// ****************************************************************************
ClonedDataNetwork::ClonedDataNetwork(DataNetwork *base) : DataNetwork()
{
......@@ -19,6 +23,7 @@ ClonedDataNetwork::ClonedDataNetwork(DataNetwork *base) : DataNetwork()
SetPipelineSpec(base->GetPipelineSpec());
SetDataSpec(base->GetDataSpec());
nodeList = base->GetNodeList();
clone = true;
}
// ****************************************************************************
......
......@@ -23,6 +23,10 @@ using std::deque;
//
// Mark C. Miller, Tue Jan 4 10:23:19 PST 2005
// Added window id (wid)
//
// Kathleen Bonnell, Tue Mar 15 17:41:26 PST 2005
// Initialize clone.
//
// ****************************************************************************
DataNetwork::DataNetwork(void)
{
......@@ -32,6 +36,7 @@ DataNetwork::DataNetwork(void)
dspec = NULL;
writer = NULL;
plotActor = NULL;
clone = false;
}
// ****************************************************************************
......@@ -50,13 +55,17 @@ DataNetwork::DataNetwork(void)
// Do not clear the nodes before releasing the data -- we would then not
// release the data in those nodes.
//
// Kathleen Bonnell, Tue Mar 15 17:41:26 PST 2005
// Don't release data if this network is a clone.
//
// ****************************************************************************
DataNetwork::~DataNetwork(void)
{
// The terminal node has already been freed by this point.
terminalNode = NULL;
ReleaseData();
if (!clone)
ReleaseData();
}
// ****************************************************************************
......
......@@ -57,6 +57,9 @@
// Added wid for window id
// Added methods to set/get window id
//
// Kathleen Bonnell, Tue Mar 15 17:41:26 PST 2005
// Added clone.
//
// ****************************************************************************
class DataNetwork
{
......@@ -109,6 +112,7 @@ protected:
avtPlot_p plot;
std::string plottype;
int time;
bool clone;
};
#endif
......@@ -941,6 +941,10 @@ ViewerQueryManager::GetQueryClientAtts()
// If we have plots that were generated dynamically, regenerate them before
// performing our query.
//
// Kathleen Bonnell, Tue Mar 15 17:39:33 PST 2005
// Only set 'DataType' from arg1 if the named query is an 'actual/original'
// type of query, otherwise set DataType to 'Actual'.
//
// ****************************************************************************
void
......@@ -1030,18 +1034,28 @@ ViewerQueryManager::DatabaseQuery(ViewerWindow *oWin, const string &qName,
return;
}
QueryAttributes qa;
qa.SetName(qName);
qa.SetUseGlobalId(elementIsGlobal);
// Right now, use of Element and DataType are mutually
// exclusive, and we don't necessarily have to know thich one
// the query will use, so go ahead and use arg1 to set both atts.
if (arg1)
qa.SetDataType(QueryAttributes::ActualData);
if (queryTypes->GetWindowType(qName) == QueryList::ActualData ||
queryTypes->GetWindowType(qName) == QueryList::ActualDataVars)
{
if (arg1)
qa.SetDataType(QueryAttributes::ActualData);
else
qa.SetDataType(QueryAttributes::OriginalData);
}
else
qa.SetDataType(QueryAttributes::OriginalData);
{
qa.SetDataType(QueryAttributes::ActualData);
}
qa.SetElement(arg1);
qa.SetDomain(arg2);
if (qName == "Variable by Zone")
......@@ -1068,7 +1082,6 @@ ViewerQueryManager::DatabaseQuery(ViewerWindow *oWin, const string &qName,
return;
}
//
// Single input queries need only one engineKey, multiple input
// queries currently require all inputs to be on same host,
......
......@@ -7944,6 +7944,9 @@ visit_Query(PyObject *self, PyObject *args)
// Kathleen Bonnell, Thu Apr 22 15:28:31 PDT 2004
// Changed arg1 default to 1 (is used to specify 'actual' data).
//
// Kathleen Bonnell, Wed Feb 23 11:23:23 PST 2005
// Changed arg1 default to 0 (is used to specify 'original' data).
//
// ****************************************************************************
STATIC PyObject *
......@@ -7952,7 +7955,7 @@ visit_QueryOverTime(PyObject *self, PyObject *args)
ENSURE_VIEWER_EXISTS();
char *queryName;
int arg1 = 1, arg2 = 0;
int arg1 = 0, arg2 = 0;
PyObject *tuple = NULL;
if (!PyArg_ParseTuple(args, "sii|O", &queryName, &arg1, &arg2, &tuple))
{
......
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