Commit d0353488 authored by hrchilds's avatar hrchilds
Browse files

Update from April 8, 2004

git-svn-id: http://visit.ilight.com/svn/visit/trunk/src@216 18c085ea-50e0-402c-830e-de6fd14e8384
parent 9a898bd4
......@@ -56,6 +56,9 @@
# I added keyframe and simplekeyframe to the skip list until I
# fix keyframing.
#
# Brad Whitlock, Wed Apr 7 17:21:25 PST 2004
# I removed keyframing tests from the skip list.
#
# ----------------------------------------------------------------------------
# list of users who want email every night with the log file
......@@ -183,20 +186,14 @@ curdate=`date +%Y-%m-%d-%p%I%M`
modes="serial parallel scalable,parallel"
# set list of tests/modes to skip
skipList="serial:tests/hybrid/keyframe.py \
serial:tests/session/simplekeyframe.py \
parallel:tests/databases/samrai.py \
skipList="parallel:tests/databases/samrai.py \
parallel:tests/hybrid/sil.py \
parallel:tests/rendering/volume.py \
parallel:tests/hybrid/keyframe.py \
parallel:tests/session/simplekeyframe.py \
scalable,parallel:tests/databases/multi_format2.py \
scalable,parallel:tests/hybrid/gradient.py \
scalable,parallel:tests/hybrid/lineout.py \
scalable,parallel:tests/operators/operators.py \
scalable,parallel:tests/rendering/volume.py \
scalable,parallel:tests/hybrid/keyframe.py \
scalable,parallel:tests/session/simplekeyframe.py"
scalable,parallel:tests/rendering/volume.py"
# run the test(s)
error=0
......
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -2366,7 +2366,7 @@ operator << (ostream& os, const AttributeGroup& atts)
os << *((AttributeGroup *)pos->address);
break;
case msgTypeBool:
os << *((bool *)pos->address);
os << (*((bool *)pos->address) ? "true" : "false");
break;
// lists of primitive types
......
......@@ -10,16 +10,17 @@
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Sun Jan 25 00:26:16 PDT 2004
// Creation: Tue Apr 6 23:39:58 PST 2004
//
// Modifications:
//
// ****************************************************************************
KeyframeAttributes::KeyframeAttributes() : AttributeSubject("bi")
KeyframeAttributes::KeyframeAttributes() : AttributeSubject("bib")
{
enabled = false;
nFrames = 0;
nFramesWasUserSet = false;
}
// ****************************************************************************
......@@ -31,16 +32,17 @@ KeyframeAttributes::KeyframeAttributes() : AttributeSubject("bi")
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Sun Jan 25 00:26:16 PDT 2004
// Creation: Tue Apr 6 23:39:58 PST 2004
//
// Modifications:
//
// ****************************************************************************
KeyframeAttributes::KeyframeAttributes(const KeyframeAttributes &obj) : AttributeSubject("bi")
KeyframeAttributes::KeyframeAttributes(const KeyframeAttributes &obj) : AttributeSubject("bib")
{
enabled = obj.enabled;
nFrames = obj.nFrames;
nFramesWasUserSet = obj.nFramesWasUserSet;
SelectAll();
}
......@@ -54,7 +56,7 @@ KeyframeAttributes::KeyframeAttributes(const KeyframeAttributes &obj) : Attribut
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Sun Jan 25 00:26:16 PDT 2004
// Creation: Tue Apr 6 23:39:58 PST 2004
//
// Modifications:
//
......@@ -74,7 +76,7 @@ KeyframeAttributes::~KeyframeAttributes()
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Sun Jan 25 00:26:16 PDT 2004
// Creation: Tue Apr 6 23:39:58 PST 2004
//
// Modifications:
//
......@@ -85,6 +87,7 @@ KeyframeAttributes::operator = (const KeyframeAttributes &obj)
{
enabled = obj.enabled;
nFrames = obj.nFrames;
nFramesWasUserSet = obj.nFramesWasUserSet;
SelectAll();
}
......@@ -98,7 +101,7 @@ KeyframeAttributes::operator = (const KeyframeAttributes &obj)
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Sun Jan 25 00:26:16 PDT 2004
// Creation: Tue Apr 6 23:39:58 PST 2004
//
// Modifications:
//
......@@ -109,7 +112,8 @@ KeyframeAttributes::operator == (const KeyframeAttributes &obj) const
{
// Create the return value
return ((enabled == obj.enabled) &&
(nFrames == obj.nFrames));
(nFrames == obj.nFrames) &&
(nFramesWasUserSet == obj.nFramesWasUserSet));
}
// ****************************************************************************
......@@ -121,7 +125,7 @@ KeyframeAttributes::operator == (const KeyframeAttributes &obj) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Sun Jan 25 00:26:16 PDT 2004
// Creation: Tue Apr 6 23:39:58 PST 2004
//
// Modifications:
//
......@@ -142,7 +146,7 @@ KeyframeAttributes::operator != (const KeyframeAttributes &obj) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Sun Jan 25 00:26:16 PDT 2004
// Creation: Tue Apr 6 23:39:58 PST 2004
//
// Modifications:
//
......@@ -163,7 +167,7 @@ KeyframeAttributes::TypeName() const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Sun Jan 25 00:26:16 PDT 2004
// Creation: Tue Apr 6 23:39:58 PST 2004
//
// Modifications:
//
......@@ -191,7 +195,7 @@ KeyframeAttributes::CopyAttributes(const AttributeGroup *atts)
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Sun Jan 25 00:26:16 PDT 2004
// Creation: Tue Apr 6 23:39:58 PST 2004
//
// Modifications:
//
......@@ -217,7 +221,7 @@ KeyframeAttributes::CreateCompatible(const std::string &tname) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Sun Jan 25 00:26:16 PDT 2004
// Creation: Tue Apr 6 23:39:58 PST 2004
//
// Modifications:
//
......@@ -244,7 +248,7 @@ KeyframeAttributes::NewInstance(bool copy) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Sun Jan 25 00:26:16 PDT 2004
// Creation: Tue Apr 6 23:39:58 PST 2004
//
// Modifications:
//
......@@ -255,6 +259,7 @@ KeyframeAttributes::SelectAll()
{
Select(0, (void *)&enabled);
Select(1, (void *)&nFrames);
Select(2, (void *)&nFramesWasUserSet);
}
///////////////////////////////////////////////////////////////////////////////
......@@ -270,7 +275,7 @@ KeyframeAttributes::SelectAll()
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Sun Jan 25 00:26:16 PDT 2004
// Creation: Tue Apr 6 23:39:58 PST 2004
//
// Modifications:
//
......@@ -299,6 +304,12 @@ KeyframeAttributes::CreateNode(DataNode *parentNode, bool completeSave, bool for
node->AddNode(new DataNode("nFrames", nFrames));
}
if(completeSave || !FieldsEqual(2, &defaultObject))
{
addToParent = true;
node->AddNode(new DataNode("nFramesWasUserSet", nFramesWasUserSet));
}
// Add the node to the parent node.
if(addToParent || forceAdd)
......@@ -318,7 +329,7 @@ KeyframeAttributes::CreateNode(DataNode *parentNode, bool completeSave, bool for
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Sun Jan 25 00:26:16 PDT 2004
// Creation: Tue Apr 6 23:39:58 PST 2004
//
// Modifications:
//
......@@ -340,6 +351,8 @@ KeyframeAttributes::SetFromNode(DataNode *parentNode)
SetEnabled(node->AsBool());
if((node = searchNode->GetNode("nFrames")) != 0)
SetNFrames(node->AsInt());
if((node = searchNode->GetNode("nFramesWasUserSet")) != 0)
SetNFramesWasUserSet(node->AsBool());
}
///////////////////////////////////////////////////////////////////////////////
......@@ -360,6 +373,13 @@ KeyframeAttributes::SetNFrames(int nFrames_)
Select(1, (void *)&nFrames);
}
void
KeyframeAttributes::SetNFramesWasUserSet(bool nFramesWasUserSet_)
{
nFramesWasUserSet = nFramesWasUserSet_;
Select(2, (void *)&nFramesWasUserSet);
}
///////////////////////////////////////////////////////////////////////////////
// Get property methods
///////////////////////////////////////////////////////////////////////////////
......@@ -376,6 +396,12 @@ KeyframeAttributes::GetNFrames() const
return nFrames;
}
bool
KeyframeAttributes::GetNFramesWasUserSet() const
{
return nFramesWasUserSet;
}
///////////////////////////////////////////////////////////////////////////////
// Keyframing methods
///////////////////////////////////////////////////////////////////////////////
......@@ -389,7 +415,7 @@ KeyframeAttributes::GetNFrames() const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Sun Jan 25 00:26:16 PDT 2004
// Creation: Tue Apr 6 23:39:58 PST 2004
//
// Modifications:
//
......@@ -402,6 +428,7 @@ KeyframeAttributes::GetFieldName(int index) const
{
case 0: return "Enabled";
case 1: return "Number of animation frames";
case 2: return "Number frames was set by the user";
default: return "invalid index";
}
}
......@@ -415,7 +442,7 @@ KeyframeAttributes::GetFieldName(int index) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Sun Jan 25 00:26:16 PDT 2004
// Creation: Tue Apr 6 23:39:58 PST 2004
//
// Modifications:
//
......@@ -428,6 +455,7 @@ KeyframeAttributes::GetFieldType(int index) const
{
case 0: return FieldType_bool;
case 1: return FieldType_int;
case 2: return FieldType_bool;
default: return FieldType_unknown;
}
}
......@@ -441,7 +469,7 @@ KeyframeAttributes::GetFieldType(int index) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Sun Jan 25 00:26:16 PDT 2004
// Creation: Tue Apr 6 23:39:58 PST 2004
//
// Modifications:
//
......@@ -454,6 +482,7 @@ KeyframeAttributes::GetFieldTypeName(int index) const
{
case 0: return "bool";
case 1: return "int";
case 2: return "bool";
default: return "invalid index";
}
}
......@@ -467,7 +496,7 @@ KeyframeAttributes::GetFieldTypeName(int index) const
// Note: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Sun Jan 25 00:26:16 PDT 2004
// Creation: Tue Apr 6 23:39:58 PST 2004
//
// Modifications:
//
......@@ -490,6 +519,11 @@ KeyframeAttributes::FieldsEqual(int index_, const AttributeGroup *rhs) const
retval = (nFrames == obj.nFrames);
}
break;
case 2:
{ // new scope
retval = (nFramesWasUserSet == obj.nFramesWasUserSet);
}
break;
default: retval = false;
}
......
......@@ -12,7 +12,7 @@
// Notes: Autogenerated by xml2atts.
//
// Programmer: xml2atts
// Creation: Sun Jan 25 00:26:16 PDT 2004
// Creation: Tue Apr 6 23:39:58 PST 2004
//
// Modifications:
//
......@@ -40,10 +40,12 @@ public:
// Property setting methods
void SetEnabled(bool enabled_);
void SetNFrames(int nFrames_);
void SetNFramesWasUserSet(bool nFramesWasUserSet_);
// Property getting methods
bool GetEnabled() const;
int GetNFrames() const;
bool GetNFramesWasUserSet() const;
// Persistence methods
virtual bool CreateNode(DataNode *node, bool completeSave, bool forceAdd);
......@@ -59,6 +61,7 @@ public:
private:
bool enabled;
int nFrames;
bool nFramesWasUserSet;
};
#endif
......@@ -6,4 +6,7 @@
<Field name="nFrames" label="Number of animation frames" type="int">
0
</Field>
<Field name="nFramesWasUserSet" label="Number frames was set by the user" type="bool">
false
</Field>
</Attribute>
......@@ -66,9 +66,14 @@ avtWeightedVariableSummationQuery::~avtWeightedVariableSummationQuery()
// Creation: February 3, 2004
//
// Modifications:
//
// Kathleen Bonnell, Wed Mar 31 16:20:39 PST 2004
// Added logic for time-varying case.
//
// Hank Childs, Thu Apr 8 08:24:12 PDT 2004
// Allow time varying data to access database, so it can consider more than
// one timestep.
//
// ****************************************************************************
avtDataObject_p
......@@ -120,20 +125,29 @@ avtWeightedVariableSummationQuery::ApplyFilters(avtDataObject_p inData)
}
else
{
//
// Create an artificial pipeline.
//
avtDataset_p ds;
CopyTo(ds, inData);
avtSourceFromAVTDataset termsrc(ds);
avtDataObject_p dob = termsrc.GetOutput();
avtDataObject_p dob = inData;
//
// Set up our base class so it is ready to sum.
//
avtDataSpecification_p dspec = GetInput()->GetTerminatingSource()
->GetFullDataSpecification();
string varname = dspec->GetVariable();
avtDataSpecification_p oldSpec = inData->GetTerminatingSource()->
GetGeneralPipelineSpecification()->GetDataSpecification();
avtDataSpecification_p newDS = new
avtDataSpecification(oldSpec->GetVariable(),
queryAtts.GetTimeStep(), oldSpec->GetRestriction());
newDS->GetRestriction()->TurnOnAll();
for (int i = 0; i < silUseSet.size(); i++)
{
if (silUseSet[i] == 0)
newDS->GetRestriction()->TurnOffSet(i);
}
avtPipelineSpecification_p pspec =
new avtPipelineSpecification(newDS, queryAtts.GetPipeIndex());
string varname = newDS->GetVariable();
SetSumType(varname);
int topo = GetInput()->GetInfo().GetAttributes().GetTopologicalDimension();
......@@ -156,8 +170,6 @@ avtWeightedVariableSummationQuery::ApplyFilters(avtDataObject_p inData)
//
// Cause our artificial pipeline to execute.
//
avtPipelineSpecification_p pspec = inData->GetTerminatingSource()
->GetGeneralPipelineSpecification();
multiply->GetOutput()->Update(pspec);
return multiply->GetOutput();
......
......@@ -16,6 +16,7 @@
#include <DebugStream.h>
#include <FileServerList.h>
#include <GlobalAttributes.h>
#include <KeyframeAttributes.h>
#include <NameSimplifier.h>
#include <WindowInformation.h>
#include <ViewerProxy.h>
......@@ -795,7 +796,17 @@ QvisFilePanel::UpdateAnimationControls(bool doAll)
currentState = windowInfo->GetTimeSliderCurrentStates()[activeTS];
nTotalStates = activeTSCorrelation->GetNumStates();
}
// else set nTotalStates from #frames in animation if in keyframing mode??
else if(viewer->GetKeyframeAttributes()->GetEnabled())
{
//
// Keyframing is enabled so we must be using the keyframing time
// slider if we didn't find a correlation for the active time
// slider. Get the number of keyframes and use that as the
// length of the time slider.
//
currentState = windowInfo->GetTimeSliderCurrentStates()[activeTS];
nTotalStates = viewer->GetKeyframeAttributes()->GetNFrames();
}
animationPosition->blockSignals(true);
animationPosition->setRange(0, nTotalStates - 1);
......
......@@ -35,6 +35,8 @@
#include <algorithm>
#define KF_TIME_SLIDER "Keyframe animation"
using std::vector;
using std::map;
......@@ -402,7 +404,11 @@ QvisKeyframeWindow::~QvisKeyframeWindow()
// Jeremy Meredith, Fri Jan 31 16:05:18 PST 2003
// Added database keyframe widgets.
//
// Brad Whitlock, Tue Apr 6 23:53:31 PST 2004
// I hooked up a new signal to nFrames.
//
// ****************************************************************************
void
QvisKeyframeWindow::CreateWindowContents()
{
......@@ -460,6 +466,8 @@ QvisKeyframeWindow::CreateWindowContents()
connect(nFrames, SIGNAL(returnPressed()),
this, SLOT(nFramesProcessText()));
connect(nFrames, SIGNAL(textChanged(const QString &)),
this, SLOT(userSetNFrames(const QString &)));
connect(ts, SIGNAL(valueChanged(int)),
lv, SLOT(timeChanged(int)));
connect(ts, SIGNAL(valueChanged(int)),
......@@ -510,16 +518,50 @@ QvisKeyframeWindow::apply()
// Brad Whitlock, Tue Jan 27 21:47:40 PST 2004
// Changed to support multiple time sliders, etc.
//
// Brad Whitlock, Wed Apr 7 00:08:51 PDT 2004
// I added code to switch to the keyframing time slider if that's not the
// current time slider.
//
// ****************************************************************************
void
QvisKeyframeWindow::timeChanged(int t)
{
#ifdef BEFORE_NEW_FILE_SELECTION
viewer->AnimationSetFrame(t);
#else
//
// Set the active time slider to be the keyframing time slider if that's
// not the currently active time slider.
//
if((windowInfo->GetActiveTimeSlider() >= 0) &&
(windowInfo->GetTimeSliders()[windowInfo->GetActiveTimeSlider()] !=
KF_TIME_SLIDER))
{
viewer->SetActiveTimeSlider(KF_TIME_SLIDER);
}
// Set the active time slider to the kf time slider???
viewer->SetTimeSliderState(t);
#endif
}
// ****************************************************************************
// Method: QvisKeyframeWindow::userSetNFrames
//
// Purpose:
// This is a Qt slot function that is called when the number of frames
// changes. The purpose is only to record that the user entered a number
// of frames so it is not okay to automatically calculate a number of
// frames.
//
// Programmer: Brad Whitlock
// Creation: Tue Apr 6 23:50:53 PST 2004
//
// Modifications:
//
// ****************************************************************************
void
QvisKeyframeWindow::userSetNFrames(const QString &)
{
kfAtts->SetNFramesWasUserSet(true);
}
// ****************************************************************************
......@@ -574,7 +616,9 @@ QvisKeyframeWindow::keyframeEnabledToggled(bool k)
// Creation: Sun Jan 25 00:19:01 PDT 2004
//
// Modifications:
//
// Brad Whitlock, Tue Apr 6 23:46:31 PST 2004
// I changed the name of the keyframe time slider.
//
// ****************************************************************************
int
......@@ -584,7 +628,7 @@ QvisKeyframeWindow::GetCurrentFrame() const
for(int i = 0; i < windowInfo->GetTimeSliders().size(); ++i)
{
if(windowInfo->GetTimeSliders()[i] == "Animation")
if(windowInfo->GetTimeSliders()[i] == KF_TIME_SLIDER)
{
curFrame = windowInfo->GetTimeSliderCurrentStates()[i];
break;
......@@ -614,6 +658,9 @@ QvisKeyframeWindow::GetCurrentFrame() const
// I made it use the window information and I made the number of frames
// come from the keyframe atts.
//
// Brad Whitlock, Tue Apr 6 23:54:37 PST 2004
// I added code to block signals from nFrames.
//
// ****************************************************************************
void
......@@ -626,8 +673,8 @@ QvisKeyframeWindow::UpdateWindowInformation()
//
// If we're in keyframing mode then there will be a time slider called
// "Animation". Look for it in the time slider list and get the number
// of frames from the keyframe attributes.
// "Keyframe animation". Look for it in the time slider list and get
// the number of frames from the keyframe attributes.
//
int curFrame = GetCurrentFrame();
......@@ -648,7 +695,10 @@ QvisKeyframeWindow::UpdateWindowInformation()
ts->setValue(curFrame);
ts->blockSignals(false);
temp.sprintf("%d", numFrames);
nFrames->blockSignals(true);
nFrames->setText(temp);
nFrames->blockSignals(false);
if (!viewItem)
{
......@@ -912,6 +962,9 @@ QvisKeyframeWindow::UpdatePlotList()
// Brad Whitlock, Sun Jan 25 00:16:58 PDT 2004
// I made it windowInfo instead of globalAtts.
//
// Brad Whitlock, Wed Apr 7 00:13:09 PDT 2004
// I added code to disable the time slider if we're not in keyframing mode.
//
// ****************************************************************************
void
......@@ -938,6 +991,7 @@ QvisKeyframeWindow::UpdateWindow(bool doAll)
keyframeEnabledCheck->blockSignals(true);
keyframeEnabledCheck->setChecked(kfAtts->GetEnabled());
keyframeEnabledCheck->blockSignals(false);
ts->setEnabled(kfAtts->GetEnabled());
break;
case 1: // nFrames
UpdateWindowInformation();
......@@ -1064,13 +1118,29 @@ QvisKeyframeWindow::GetCurrentValues(int which_widget)
// Programmer: Jeremy Meredith
// Creation: May 8, 2002
//
// Modifications:
// Brad Whitlock, Wed Apr 7 00:02:24 PDT 2004
// I changed the code so the number of frames is not set unless the user
// first set it. I did this because the viewer has support for
// automatically determining a good number of frames when you first enter
// keyframing mode and by always setting the number before entering
// keyframe mode, we can't automatically determine a good number of frames.
//
// ****************************************************************************
void
QvisKeyframeWindow::Apply(bool ignore)
{
if(AutoUpdate() || ignore)
{
GetCurrentValues(-1);
//
// If the user changed the number of frames then send it. Otherwise,
// don't set the number of frames so the number can be determined
// automatically.
//
if(kfAtts->GetNFramesWasUserSet())
GetCurrentValues(-1);
kfAtts->Notify();
viewer->SetKeyframeAttributes();
......