# HG changeset patch # User Chris Cannam # Date 1416406492 0 # Node ID 0042b4d42167344a5d50a2adb6b9b46012ecfed5 # Parent e1a5f3095ba6e227a736bfe5abeb0ea63e04fc53 Remove more friend-classes diff -r e1a5f3095ba6 -r 0042b4d42167 src/MatchFeatureFeeder.cpp --- a/src/MatchFeatureFeeder.cpp Wed Nov 19 12:13:28 2014 +0000 +++ b/src/MatchFeatureFeeder.cpp Wed Nov 19 14:14:52 2014 +0000 @@ -66,16 +66,16 @@ feed2(); } else if (m_q2.empty()) { // ended feed1(); - } else if (m_pm1->m_frameCount < m_pm1->m_blockSize) { // fill initial block + } else if (m_pm1->getFrameCount() < m_pm1->getBlockSize()) { // fill initial block feed1(); feed2(); - } else if (m_pm1->m_runCount >= m_pm1->m_params.maxRunCount) { // slope constraints + } else if (m_pm1->isOverrunning()) { // slope constraints feed2(); - } else if (m_pm2->m_runCount >= m_pm2->m_params.maxRunCount) { + } else if (m_pm2->isOverrunning()) { feed1(); } else { switch (m_finder->getExpandDirection - (m_pm1->m_frameCount-1, m_pm2->m_frameCount-1)) { + (m_pm1->getFrameCount()-1, m_pm2->getFrameCount()-1)) { case Matcher::AdvanceThis: feed1(); break; diff -r e1a5f3095ba6 -r 0042b4d42167 src/Matcher.h --- a/src/Matcher.h Wed Nov 19 12:13:28 2014 +0000 +++ b/src/Matcher.h Wed Nov 19 14:14:52 2014 +0000 @@ -102,6 +102,8 @@ */ Matcher(Parameters parameters, Matcher *p, int featureSize); + /** Destructor for Matcher. + */ ~Matcher(); /** Adds a link to the Matcher object representing the performance @@ -113,6 +115,14 @@ m_otherMatcher = p; } + int getBlockSize() { + return m_blockSize; + } + + bool isOverrunning() { + return m_runCount >= m_params.maxRunCount; + } + int getFrameCount() { return m_frameCount; } @@ -290,10 +300,6 @@ bool m_initialised; DistanceMetric m_metric; - - friend class MatchFeeder; - friend class MatchFeatureFeeder; - -}; // class Matcher +}; #endif