Commit 89a31988 authored by hrchilds's avatar hrchilds
Browse files

Merge avtStreamlineWrapper into avtStreamline. avtStreamlineFilter now...

Merge avtStreamlineWrapper into avtStreamline.  avtStreamlineFilter now operates directly on avtStreamlines.


git-svn-id: http://visit.ilight.com/svn/visit/trunk/src@11574 18c085ea-50e0-402c-830e-de6fd14e8384
parent 4b690075
...@@ -36,6 +36,9 @@ ...@@ -36,6 +36,9 @@
# #
# Modifications: # Modifications:
# #
# Hank Childs, Fri Jun 4 17:03:43 CDT 2010
# Remove avtStreamlineWrapper.
#
#****************************************************************************/ #****************************************************************************/
SET(AVTFILTERS_SOURCES SET(AVTFILTERS_SOURCES
...@@ -76,7 +79,6 @@ avtSLAlgorithm.C ...@@ -76,7 +79,6 @@ avtSLAlgorithm.C
avtSmoothPolyDataFilter.C avtSmoothPolyDataFilter.C
avtStreamlineFilter.C avtStreamlineFilter.C
avtStreamlinePolyDataFilter.C avtStreamlinePolyDataFilter.C
avtStreamlineWrapper.C
avtSummationFilter.C avtSummationFilter.C
avtSurfaceFilter.C avtSurfaceFilter.C
avtTiledImageCompositor.C avtTiledImageCompositor.C
......
...@@ -239,10 +239,13 @@ avtMasterSlaveSLAlgorithm::~avtMasterSlaveSLAlgorithm() ...@@ -239,10 +239,13 @@ avtMasterSlaveSLAlgorithm::~avtMasterSlaveSLAlgorithm()
// Dave Pugmire, Wed Apr 1 11:21:05 EDT 2009 // Dave Pugmire, Wed Apr 1 11:21:05 EDT 2009
// Message size and number of receives put in Initialize(). // Message size and number of receives put in Initialize().
// //
// Hank Childs, Fri Jun 4 19:58:30 CDT 2010
// Use avtStreamlines, not avtStreamlineWrappers.
//
// **************************************************************************** // ****************************************************************************
void void
avtMasterSlaveSLAlgorithm::Initialize(std::vector<avtStreamlineWrapper *> &seedPts) avtMasterSlaveSLAlgorithm::Initialize(std::vector<avtStreamline *> &seedPts)
{ {
int numRecvs = nProcs-1; int numRecvs = nProcs-1;
if (numRecvs > 64) if (numRecvs > 64)
...@@ -258,7 +261,7 @@ avtMasterSlaveSLAlgorithm::ResetStreamlinesForContinueExecute() ...@@ -258,7 +261,7 @@ avtMasterSlaveSLAlgorithm::ResetStreamlinesForContinueExecute()
} }
void void
avtMasterSlaveSLAlgorithm::AddStreamlines(std::vector<avtStreamlineWrapper*> &sls) avtMasterSlaveSLAlgorithm::AddStreamlines(std::vector<avtStreamline*> &sls)
{ {
EXCEPTION0(ImproperUseException); EXCEPTION0(ImproperUseException);
} }
...@@ -495,10 +498,13 @@ avtMasterSLAlgorithm::~avtMasterSLAlgorithm() ...@@ -495,10 +498,13 @@ avtMasterSLAlgorithm::~avtMasterSLAlgorithm()
// Dave Pugmire, Fri Feb 12 09:30:27 EST 2010 // Dave Pugmire, Fri Feb 12 09:30:27 EST 2010
// Wrong initial sizes for status and prevStatus. // Wrong initial sizes for status and prevStatus.
// //
// Hank Childs, Fri Jun 4 19:58:30 CDT 2010
// Use avtStreamlines, not avtStreamlineWrappers.
//
// **************************************************************************** // ****************************************************************************
void void
avtMasterSLAlgorithm::Initialize(std::vector<avtStreamlineWrapper *> &seedPts) avtMasterSLAlgorithm::Initialize(std::vector<avtStreamline *> &seedPts)
{ {
SortStreamlines(seedPts); SortStreamlines(seedPts);
avtMasterSlaveSLAlgorithm::Initialize(seedPts); avtMasterSlaveSLAlgorithm::Initialize(seedPts);
...@@ -1156,12 +1162,17 @@ avtMasterSLAlgorithm::ProcessOffloadSL(vector<int> &status) ...@@ -1156,12 +1162,17 @@ avtMasterSLAlgorithm::ProcessOffloadSL(vector<int> &status)
// Programmer: Dave Pugmire // Programmer: Dave Pugmire
// Creation: March 18, 2009 // Creation: March 18, 2009
// //
// Modifications:
//
// Hank Childs, Fri Jun 4 19:58:30 CDT 2010
// Use avtStreamlines, not avtStreamlineWrappers.
//
// **************************************************************************** // ****************************************************************************
void void
avtMasterSLAlgorithm::ProcessNewStreamlines() avtMasterSLAlgorithm::ProcessNewStreamlines()
{ {
list<avtStreamlineWrapper*> newSLs; list<avtStreamline*> newSLs;
RecvSLs(newSLs); RecvSLs(newSLs);
if (!newSLs.empty()) if (!newSLs.empty())
{ {
...@@ -1199,7 +1210,7 @@ avtMasterSLAlgorithm::ManageWorkgroup() ...@@ -1199,7 +1210,7 @@ avtMasterSLAlgorithm::ManageWorkgroup()
domLoaded[i] = 0; domLoaded[i] = 0;
} }
list<avtStreamlineWrapper *>::const_iterator s; list<avtStreamline *>::const_iterator s;
for (s = activeSLs.begin(); s != activeSLs.end(); ++s) for (s = activeSLs.begin(); s != activeSLs.end(); ++s)
slDomCnts[DomToIdx( (*s)->domain )] ++; slDomCnts[DomToIdx( (*s)->domain )] ++;
...@@ -1460,8 +1471,11 @@ avtMasterSLAlgorithm::FindSlackers(int oobFactor, ...@@ -1460,8 +1471,11 @@ avtMasterSLAlgorithm::FindSlackers(int oobFactor,
// Dave Pugmire, Tue Mar 10 12:41:11 EDT 2009 // Dave Pugmire, Tue Mar 10 12:41:11 EDT 2009
// Generalized domain to include domain/time. Pathine cleanup. // Generalized domain to include domain/time. Pathine cleanup.
// //
// Dave Pugmire, Sat Mar 28 10:04:01 EDT 2009 // Dave Pugmire, Sat Mar 28 10:04:01 EDT 2009
// Bug fix. Case1 never happened. forgot the "not" empty. // Bug fix. Case1 never happened. forgot the "not" empty.
//
// Hank Childs, Fri Jun 4 19:58:30 CDT 2010
// Use avtStreamlines, not avtStreamlineWrappers.
// //
// **************************************************************************** // ****************************************************************************
...@@ -1473,7 +1487,7 @@ avtMasterSLAlgorithm::Case1(int &counter) ...@@ -1473,7 +1487,7 @@ avtMasterSLAlgorithm::Case1(int &counter)
FindSlackers(); FindSlackers();
vector< vector< avtStreamlineWrapper *> > distributeSLs(nProcs); vector< vector< avtStreamline *> > distributeSLs(nProcs);
bool streamlinesToSend = false; bool streamlinesToSend = false;
for (int i = 0; i < slackers.size(); i++) for (int i = 0; i < slackers.size(); i++)
...@@ -1483,7 +1497,7 @@ avtMasterSLAlgorithm::Case1(int &counter) ...@@ -1483,7 +1497,7 @@ avtMasterSLAlgorithm::Case1(int &counter)
int cnt = 0; int cnt = 0;
int slackerRank = slaveInfo[slackers[i]].rank; int slackerRank = slaveInfo[slackers[i]].rank;
list<avtStreamlineWrapper *>::iterator s = activeSLs.begin(); list<avtStreamline *>::iterator s = activeSLs.begin();
while ( !activeSLs.empty() && cnt < maxCnt) while ( !activeSLs.empty() && cnt < maxCnt)
{ {
...@@ -1540,6 +1554,9 @@ avtMasterSLAlgorithm::Case1(int &counter) ...@@ -1540,6 +1554,9 @@ avtMasterSLAlgorithm::Case1(int &counter)
// Dave Pugmire, Fri Feb 12 09:30:27 EST 2010 // Dave Pugmire, Fri Feb 12 09:30:27 EST 2010
// Fix memory leak of domCnts. // Fix memory leak of domCnts.
// //
// Hank Childs, Fri Jun 4 19:58:30 CDT 2010
// Use avtStreamlines, not avtStreamlineWrappers.
//
// **************************************************************************** // ****************************************************************************
static bool domCntCompare( const int *a, const int *b) { return a[1] > b[1]; } static bool domCntCompare( const int *a, const int *b) { return a[1] > b[1]; }
...@@ -1552,7 +1569,7 @@ avtMasterSLAlgorithm::Case2(int &counter) ...@@ -1552,7 +1569,7 @@ avtMasterSLAlgorithm::Case2(int &counter)
FindSlackers(); FindSlackers();
vector< vector< avtStreamlineWrapper *> > distributeSLs(nProcs); vector< vector< avtStreamline *> > distributeSLs(nProcs);
bool streamlinesToSend = false; bool streamlinesToSend = false;
for (int s = 0; s < slackers.size(); s++) for (int s = 0; s < slackers.size(); s++)
...@@ -1607,7 +1624,7 @@ avtMasterSLAlgorithm::Case2(int &counter) ...@@ -1607,7 +1624,7 @@ avtMasterSLAlgorithm::Case2(int &counter)
int cnt = 0; int cnt = 0;
list<avtStreamlineWrapper *>::iterator sl = activeSLs.begin(); list<avtStreamline *>::iterator sl = activeSLs.begin();
while ( !activeSLs.empty() && cnt < maxCnt) while ( !activeSLs.empty() && cnt < maxCnt)
{ {
...@@ -2052,10 +2069,13 @@ avtSlaveSLAlgorithm::HandleLatencyTimer(int activeSLCnt, bool checkMaxLatency) ...@@ -2052,10 +2069,13 @@ avtSlaveSLAlgorithm::HandleLatencyTimer(int activeSLCnt, bool checkMaxLatency)
// Dave Pugmire, Tue Mar 10 12:41:11 EDT 2009 // Dave Pugmire, Tue Mar 10 12:41:11 EDT 2009
// Generalized domain to include domain/time. Pathine cleanup. // Generalized domain to include domain/time. Pathine cleanup.
// //
// Hank Childs, Fri Jun 4 19:58:30 CDT 2010
// Use avtStreamlines, not avtStreamlineWrappers.
//
// **************************************************************************** // ****************************************************************************
void void
avtSlaveSLAlgorithm::Initialize(std::vector<avtStreamlineWrapper *> &seedPts) avtSlaveSLAlgorithm::Initialize(std::vector<avtStreamline *> &seedPts)
{ {
avtMasterSlaveSLAlgorithm::Initialize(seedPts); avtMasterSlaveSLAlgorithm::Initialize(seedPts);
status.resize(NUM_DOMAINS,0); status.resize(NUM_DOMAINS,0);
...@@ -2074,6 +2094,11 @@ avtSlaveSLAlgorithm::Initialize(std::vector<avtStreamlineWrapper *> &seedPts) ...@@ -2074,6 +2094,11 @@ avtSlaveSLAlgorithm::Initialize(std::vector<avtStreamlineWrapper *> &seedPts)
// Programmer: Dave Pugmire // Programmer: Dave Pugmire
// Creation: January 27, 2009 // Creation: January 27, 2009
// //
// Modifications:
//
// Hank Childs, Fri Jun 4 19:58:30 CDT 2010
// Use avtStreamlines, not avtStreamlineWrappers.
//
// **************************************************************************** // ****************************************************************************
void void
...@@ -2090,7 +2115,7 @@ avtSlaveSLAlgorithm::UpdateStatus() ...@@ -2090,7 +2115,7 @@ avtSlaveSLAlgorithm::UpdateStatus()
} }
//Increment/decrement all the streamlines we have. //Increment/decrement all the streamlines we have.
list<avtStreamlineWrapper *>::const_iterator s; list<avtStreamline *>::const_iterator s;
bool prevWorkToDo = workToDo; bool prevWorkToDo = workToDo;
workToDo = false; workToDo = false;
...@@ -2195,13 +2220,13 @@ avtSlaveSLAlgorithm::SendStatus(bool forceSend) ...@@ -2195,13 +2220,13 @@ avtSlaveSLAlgorithm::SendStatus(bool forceSend)
// Dave Pugmire, Wed Mar 25 09:10:52 EDT 2009 // Dave Pugmire, Wed Mar 25 09:10:52 EDT 2009
// Enable latency. // Enable latency.
// //
// Dave Pugmire, Sat Mar 28 10:04:01 EDT 2009 // Dave Pugmire, Sat Mar 28 10:04:01 EDT 2009
// Resend status if getting no work from master. This is related to the tmp fix // Resend status if getting no work from master. This is related to the tmp
// above in the master. // fix above in the master.
// //
// Dave Pugmire, Wed Apr 1 11:21:05 EDT 2009 // Dave Pugmire, Wed Apr 1 11:21:05 EDT 2009
// Latency time was not always being reported accurately. Only send the latency // Latency time was not always being reported accurately. Only send the
// saving status update once. // latency saving status update once.
// //
// Dave Pugmire, Thu Sep 24 13:52:59 EDT 2009 // Dave Pugmire, Thu Sep 24 13:52:59 EDT 2009
// Change Execute to RunAlgorithm. // Change Execute to RunAlgorithm.
...@@ -2209,12 +2234,15 @@ avtSlaveSLAlgorithm::SendStatus(bool forceSend) ...@@ -2209,12 +2234,15 @@ avtSlaveSLAlgorithm::SendStatus(bool forceSend)
// Dave Pugmire, Fri Sep 25 15:35:32 EDT 2009 // Dave Pugmire, Fri Sep 25 15:35:32 EDT 2009
// Add auto-load code for slaves. // Add auto-load code for slaves.
// //
// Hank Childs, Fri Jun 4 19:58:30 CDT 2010
// Use avtStreamlines, not avtStreamlineWrappers.
//
// **************************************************************************** // ****************************************************************************
void void
avtSlaveSLAlgorithm::RunAlgorithm() avtSlaveSLAlgorithm::RunAlgorithm()
{ {
list<avtStreamlineWrapper *>::const_iterator si; list<avtStreamline *>::const_iterator si;
int timer = visitTimer->StartTimer(); int timer = visitTimer->StartTimer();
//Send initial status. //Send initial status.
...@@ -2225,7 +2253,7 @@ avtSlaveSLAlgorithm::RunAlgorithm() ...@@ -2225,7 +2253,7 @@ avtSlaveSLAlgorithm::RunAlgorithm()
while (1) while (1)
{ {
//Fill oobSLs list. //Fill oobSLs list.
list<avtStreamlineWrapper *>::iterator si = activeSLs.begin(); list<avtStreamline *>::iterator si = activeSLs.begin();
while (si != activeSLs.end()) while (si != activeSLs.end())
{ {
if (!DomainLoaded((*si)->domain)) if (!DomainLoaded((*si)->domain))
...@@ -2270,7 +2298,7 @@ avtSlaveSLAlgorithm::RunAlgorithm() ...@@ -2270,7 +2298,7 @@ avtSlaveSLAlgorithm::RunAlgorithm()
HandleLatencyTimer(activeSLs.size()); HandleLatencyTimer(activeSLs.size());
while (!activeSLs.empty() && !done) while (!activeSLs.empty() && !done)
{ {
avtStreamlineWrapper *s = activeSLs.front(); avtStreamline *s = activeSLs.front();
forceSend = false; forceSend = false;
if (activeSLs.size() <= LATENCY_SEND_CNT) if (activeSLs.size() <= LATENCY_SEND_CNT)
...@@ -2290,7 +2318,7 @@ avtSlaveSLAlgorithm::RunAlgorithm() ...@@ -2290,7 +2318,7 @@ avtSlaveSLAlgorithm::RunAlgorithm()
activeSLs.pop_front(); activeSLs.pop_front();
debug1<<"Integrate "<<s->domain<<"....."; debug1<<"Integrate "<<s->domain<<".....";
IntegrateStreamline(s); IntegrateStreamline(s);
if (s->status == avtStreamlineWrapper::TERMINATE) if (s->status == avtStreamline::STATUS_TERMINATE)
{ {
terminatedSLs.push_back(s); terminatedSLs.push_back(s);
numTerminated++; numTerminated++;
...@@ -2368,12 +2396,15 @@ avtSlaveSLAlgorithm::RunAlgorithm() ...@@ -2368,12 +2396,15 @@ avtSlaveSLAlgorithm::RunAlgorithm()
// Dave Pugmire, Mon Mar 16 15:05:14 EDT 2009 // Dave Pugmire, Mon Mar 16 15:05:14 EDT 2009
// Bug fix. Didn't use new DomainType structure for MSG_SEND_SL. // Bug fix. Didn't use new DomainType structure for MSG_SEND_SL.
// //
// Dave Pugmire, Wed Mar 18 21:55:32 EDT 2009 // Dave Pugmire, Wed Mar 18 21:55:32 EDT 2009
// Improve the logic for streamline offloading. Only offload streamlines // Improve the logic for streamline offloading. Only offload streamlines
// in unloaded domains. // in unloaded domains.
// //
// Dave Pugmire, Sat Mar 28 10:04:01 EDT 2009 // Dave Pugmire, Sat Mar 28 10:04:01 EDT 2009
// Handle streamline offloading (case5). // Handle streamline offloading (case5).
//
// Hank Childs, Fri Jun 4 19:58:30 CDT 2010
// Use avtStreamlines, not avtStreamlineWrappers.
// //
// **************************************************************************** // ****************************************************************************
...@@ -2421,14 +2452,14 @@ avtSlaveSLAlgorithm::ProcessMessages(bool &done, bool &newMsgs) ...@@ -2421,14 +2452,14 @@ avtSlaveSLAlgorithm::ProcessMessages(bool &done, bool &newMsgs)
else else
num = maxCnt; num = maxCnt;
vector< avtStreamlineWrapper *> sendSLs; vector< avtStreamline *> sendSLs;
for (int d = 0; d < numDoms; d++) for (int d = 0; d < numDoms; d++)
{ {
int domIdx = msg[4+d]; int domIdx = msg[4+d];
DomainType dom = IdxToDom(domIdx); DomainType dom = IdxToDom(domIdx);
list<avtStreamlineWrapper *>::iterator s = activeSLs.begin(); list<avtStreamline *>::iterator s = activeSLs.begin();
while (s != activeSLs.end() && while (s != activeSLs.end() &&
sendSLs.size() < num) sendSLs.size() < num)
{ {
...@@ -2473,8 +2504,8 @@ avtSlaveSLAlgorithm::ProcessMessages(bool &done, bool &newMsgs) ...@@ -2473,8 +2504,8 @@ avtSlaveSLAlgorithm::ProcessMessages(bool &done, bool &newMsgs)
int num = msg[4]; int num = msg[4];
debug1<<"MSG: Send "<<num<<" x dom= "<<dom<<" to "<<dst; debug1<<"MSG: Send "<<num<<" x dom= "<<dom<<" to "<<dst;
list<avtStreamlineWrapper *>::iterator s = activeSLs.begin(); list<avtStreamline *>::iterator s = activeSLs.begin();
vector< avtStreamlineWrapper *> sendSLs; vector< avtStreamline *> sendSLs;
while (s != activeSLs.end() && while (s != activeSLs.end() &&
sendSLs.size() < num) sendSLs.size() < num)
{ {
......
...@@ -66,11 +66,14 @@ class SlaveInfo; ...@@ -66,11 +66,14 @@ class SlaveInfo;
// Dave Pugmire, Wed Mar 18 17:17:40 EDT 2009 // Dave Pugmire, Wed Mar 18 17:17:40 EDT 2009
// Allow masters to share work loads. // Allow masters to share work loads.
// //
// Dave Pugmire, Mon Mar 23 12:48:12 EDT 2009 // Dave Pugmire, Mon Mar 23 12:48:12 EDT 2009
// Change how timings are reported/calculated. // Change how timings are reported/calculated.
// //
// Dave Pugmire, Fri Sep 25 15:35:32 EDT 2009 // Dave Pugmire, Fri Sep 25 15:35:32 EDT 2009
// New counters. // New counters.
//
// Hank Childs, Fri Jun 4 19:58:30 CDT 2010
// Use avtStreamlines, not avtStreamlineWrappers.
// //
// **************************************************************************** // ****************************************************************************
...@@ -81,11 +84,11 @@ class avtMasterSlaveSLAlgorithm : public avtParSLAlgorithm ...@@ -81,11 +84,11 @@ class avtMasterSlaveSLAlgorithm : public avtParSLAlgorithm
int maxCount); int maxCount);
virtual ~avtMasterSlaveSLAlgorithm(); virtual ~avtMasterSlaveSLAlgorithm();
virtual void Initialize(std::vector<avtStreamlineWrapper *> &); virtual void Initialize(std::vector<avtStreamline *> &);
virtual const char* AlgoName() const {return "MasterSlave";} virtual const char* AlgoName() const {return "MasterSlave";}
virtual void ResetStreamlinesForContinueExecute(); virtual void ResetStreamlinesForContinueExecute();
virtual void AddStreamlines(std::vector<avtStreamlineWrapper*> &sls); virtual void AddStreamlines(std::vector<avtStreamline*> &sls);
static avtMasterSlaveSLAlgorithm* Create(avtStreamlineFilter *slFilter, static avtMasterSlaveSLAlgorithm* Create(avtStreamlineFilter *slFilter,
int maxCount, int maxCount,
...@@ -166,7 +169,7 @@ class avtMasterSLAlgorithm : public avtMasterSlaveSLAlgorithm ...@@ -166,7 +169,7 @@ class avtMasterSLAlgorithm : public avtMasterSlaveSLAlgorithm
virtual ~avtMasterSLAlgorithm(); virtual ~avtMasterSLAlgorithm();
virtual const char* AlgoName() const {return "MasterSlave";} virtual const char* AlgoName() const {return "MasterSlave";}
virtual void Initialize(std::vector<avtStreamlineWrapper *> &); virtual void Initialize(std::vector<avtStreamline *> &);
protected: protected:
virtual void RunAlgorithm(); virtual void RunAlgorithm();
...@@ -193,7 +196,7 @@ class avtMasterSLAlgorithm : public avtMasterSlaveSLAlgorithm ...@@ -193,7 +196,7 @@ class avtMasterSLAlgorithm : public avtMasterSlaveSLAlgorithm
int master; int master;
std::vector<SlaveInfo> slaveInfo, masterInfo; std::vector<SlaveInfo> slaveInfo, masterInfo;
std::vector<int> slDomCnts, domLoaded, slackers; std::vector<int> slDomCnts, domLoaded, slackers;
std::list<avtStreamlineWrapper *> activeSLs; std::list<avtStreamline *> activeSLs;
void SendAllSlavesMsg(int msg); void SendAllSlavesMsg(int msg);
void SendAllSlavesMsg(std::vector<int> &msg); void SendAllSlavesMsg(std::vector<int> &msg);
...@@ -247,7 +250,7 @@ class avtSlaveSLAlgorithm : public avtMasterSlaveSLAlgorithm ...@@ -247,7 +250,7 @@ class avtSlaveSLAlgorithm : public avtMasterSlaveSLAlgorithm
int masterRank); int masterRank);
virtual ~avtSlaveSLAlgorithm(); virtual ~avtSlaveSLAlgorithm();
virtual void Initialize(std::vector<avtStreamlineWrapper *> &); virtual void Initialize(std::vector<avtStreamline *> &);
virtual void SendStatus(bool forceSend=false); virtual void SendStatus(bool forceSend=false);
virtual void UpdateStatus(); virtual void UpdateStatus();
...@@ -257,7 +260,7 @@ class avtSlaveSLAlgorithm : public avtMasterSlaveSLAlgorithm ...@@ -257,7 +260,7 @@ class avtSlaveSLAlgorithm : public avtMasterSlaveSLAlgorithm
int master, numTerminated, timeout; int master, numTerminated, timeout;
bool workToDo; bool workToDo;
std::vector<int> status, prevStatus; std::vector<int> status, prevStatus;
std::list<avtStreamlineWrapper *> activeSLs, oobSLs; std::list<avtStreamline *> activeSLs, oobSLs;
void ProcessMessages(bool &done, bool &newMsg); void ProcessMessages(bool &done, bool &newMsg);
void HandleLatencyTimer(int activeSLCnt, void HandleLatencyTimer(int activeSLCnt,
......
...@@ -114,10 +114,13 @@ avtParDomSLAlgorithm::~avtParDomSLAlgorithm() ...@@ -114,10 +114,13 @@ avtParDomSLAlgorithm::~avtParDomSLAlgorithm()
// Establish how many streamlines there are once each proc determines if a // Establish how many streamlines there are once each proc determines if a
// seed is in the domain. // seed is in the domain.
// //
// Hank Childs, Fri Jun 4 19:58:30 CDT 2010
// Use avtStreamlines, not avtStreamlineWrappers.
//
// **************************************************************************** // ****************************************************************************
void void
avtParDomSLAlgorithm::Initialize(vector<avtStreamlineWrapper *> &seedPts) avtParDomSLAlgorithm::Initialize(vector<avtStreamline *> &seedPts)
{ {
int numRecvs = nProcs-1; int numRecvs = nProcs-1;
if (numRecvs > 64) if (numRecvs > 64)
...@@ -139,19 +142,22 @@ avtParDomSLAlgorithm::Initialize(vector<avtStreamlineWrapper *> &seedPts) ...@@ -139,19 +142,22 @@ avtParDomSLAlgorithm::Initialize(vector<avtStreamlineWrapper *> &seedPts)
// //
// Modifications: // Modifications:
// //
// Hank Childs, Fri Jun 4 19:58:30 CDT 2010
// Use avtStreamlines, not avtStreamlineWrappers.
//
// **************************************************************************** // ****************************************************************************
void void
avtParDomSLAlgorithm::AddStreamlines(std::vector<avtStreamlineWrapper*> &sls) avtParDomSLAlgorithm::AddStreamlines(std::vector<avtStreamline*> &sls)
{ {
//Get the SLs that I own. //Get the SLs that I own.
for (int i = 0; i < sls.size(); i++) for (int i = 0; i < sls.size(); i++)
{ {
avtStreamlineWrapper *s = sls[i]; avtStreamline *s = sls[i];
if (OwnDomain(s->domain)) if (OwnDomain(s->domain))
{ {
avtVector endPt; avtVector endPt;
s->GetCurrentLocation(endPt); s->CurrentLocation(endPt);
if (PointInDomain(endPt, s->domain)) if (PointInDomain(endPt, s->domain))
activeSLs.push_back(s); activeSLs.push_back(s);
...@@ -168,7 +174,7 @@ avtParDomSLAlgorithm::AddStreamlines(std::vector<avtStreamlineWrapper*> &sls) ...@@ -168,7 +174,7 @@ avtParDomSLAlgorithm::AddStreamlines(std::vector<avtStreamlineWrapper*> &sls)
for (int i = 0; i < numSeedPoints; i++) for (int i = 0; i < numSeedPoints; i++)
idBuffer[i] = 0; idBuffer[i] = 0;
list<avtStreamlineWrapper *>::iterator s; list<avtStreamline *>::iterator s;
for (s = activeSLs.begin(); s != activeSLs.end(); ++s) for (s = activeSLs.begin(); s != activeSLs.end(); ++s)
idBuffer[(*s)->id]++; idBuffer[(*s)->id]++;
...@@ -191,7 +197,7 @@ avtParDomSLAlgorithm::AddStreamlines(std::vector<avtStreamlineWrapper*> &sls) ...@@ -191,7 +197,7 @@ avtParDomSLAlgorithm::AddStreamlines(std::vector<avtStreamlineWrapper*> &sls)
/* /*
debug5<<"Init_totalNumStreamlines= "<<totalNumStreamlines<<endl; debug5<<"Init_totalNumStreamlines= "<<totalNumStreamlines<<endl;
debug5<<"My SLs: "<<endl; debug5<<"My SLs: "<<endl;
list<avtStreamlineWrapper *>::iterator s; list<avtStreamline *>::iterator s;
for (s = activeSLs.begin(); s != activeSLs.end(); ++s) for (s = activeSLs.begin(); s != activeSLs.end(); ++s)
debug5<<"ID "<<(*s)->id<<" dom= "<<(*s)->domain<<endl; debug5<<"ID "<<(*s)->id<<" dom= "<<(*s)->domain<<endl;
*/ */
...@@ -284,8 +290,8 @@ avtParDomSLAlgorithm::PreRunAlgorithm() ...@@ -284,8 +290,8 @@ avtParDomSLAlgorithm::PreRunAlgorithm()
// integration was not handled correctly after the code refactor. Added // integration was not handled correctly after the code refactor. Added
// HandleOOBSL(). // HandleOOBSL().
// //
// Dave Pugmire, Fri Feb 6 08:43:00 EST 2009 // Dave Pugmire, Fri Feb 6 08:43:00 EST 2009
// Change numTerminated to numSLChange. // Change numTerminated to numSLChange.
//