Remove TMMBRSet class

by cleaning RTCPReceiveInfo class
and following cleaning of RTCPReceiver::BoundingSet function.

BUG=webrtc:5565

Review-Url: https://codereview.webrtc.org/2254703003
Cr-Commit-Position: refs/heads/master@{#13817}
This commit is contained in:
danilchap
2016-08-18 06:17:42 -07:00
committed by Commit bot
parent e1f5b4a7fe
commit 2b616397de
10 changed files with 102 additions and 219 deletions

View File

@ -107,8 +107,8 @@ int64_t RTCPReceiver::LastReceivedReceiverReport() const {
int64_t last_received_rr = -1;
for (ReceivedInfoMap::const_iterator it = _receivedInfoMap.begin();
it != _receivedInfoMap.end(); ++it) {
if (it->second->lastTimeReceived > last_received_rr) {
last_received_rr = it->second->lastTimeReceived;
if (it->second->last_time_received_ms > last_received_rr) {
last_received_rr = it->second->last_time_received_ms;
}
}
return last_received_rr;
@ -445,7 +445,8 @@ RTCPReceiver::HandleSenderReceiverReport(RTCPUtility::RTCPParserV2& rtcpParser,
rtcpPacketInformation.rtcpPacketTypeFlags |= kRtcpRr;
}
UpdateReceiveInformation(*ptrReceiveInfo);
// Update that this remote is alive.
ptrReceiveInfo->last_time_received_ms = _clock->TimeInMilliseconds();
rtcpPacketType = rtcpParser.Iterate();
@ -639,12 +640,6 @@ RTCPReceiver::GetReceiveInformation(uint32_t remoteSSRC) {
return it->second;
}
void RTCPReceiver::UpdateReceiveInformation(
RTCPReceiveInformation& receiveInformation) {
// Update that this remote is alive
receiveInformation.lastTimeReceived = _clock->TimeInMilliseconds();
}
bool RTCPReceiver::RtcpRrTimeout(int64_t rtcp_interval_ms) {
rtc::CritScope lock(&_criticalSectionRTCPReceiver);
if (_lastReceivedRrMs == 0)
@ -691,20 +686,20 @@ bool RTCPReceiver::UpdateRTCPReceiveInformationTimers() {
// time since last received rtcp packet
// when we dont have a lastTimeReceived and the object is marked
// readyForDelete it's removed from the map
if (receiveInfo->lastTimeReceived) {
if (receiveInfo->last_time_received_ms > 0) {
/// use audio define since we don't know what interval the remote peer is
// using
if ((timeNow - receiveInfo->lastTimeReceived) >
if ((timeNow - receiveInfo->last_time_received_ms) >
5 * RTCP_INTERVAL_AUDIO_MS) {
// no rtcp packet for the last five regular intervals, reset limitations
receiveInfo->TmmbrSet.clearSet();
receiveInfo->ClearTmmbr();
// prevent that we call this over and over again
receiveInfo->lastTimeReceived = 0;
receiveInfo->last_time_received_ms = 0;
// send new TMMBN to all channels using the default codec
updateBoundingSet = true;
}
receiveInfoIt++;
} else if (receiveInfo->readyForDelete) {
} else if (receiveInfo->ready_for_delete) {
// store our current receiveInfoItem
std::map<uint32_t, RTCPReceiveInformation*>::iterator
receiveInfoItemToBeErased = receiveInfoIt;
@ -718,35 +713,20 @@ bool RTCPReceiver::UpdateRTCPReceiveInformationTimers() {
return updateBoundingSet;
}
int32_t RTCPReceiver::BoundingSet(bool* tmmbrOwner, TMMBRSet* boundingSetRec) {
std::vector<rtcp::TmmbItem> RTCPReceiver::BoundingSet(bool* tmmbr_owner) {
rtc::CritScope lock(&_criticalSectionRTCPReceiver);
std::map<uint32_t, RTCPReceiveInformation*>::iterator receiveInfoIt =
_receivedInfoMap.find(_remoteSSRC);
if (receiveInfoIt == _receivedInfoMap.end()) {
return -1;
return std::vector<rtcp::TmmbItem>();
}
RTCPReceiveInformation* receiveInfo = receiveInfoIt->second;
if (receiveInfo == NULL) {
return -1;
}
if (receiveInfo->TmmbnBoundingSet.lengthOfSet() > 0) {
boundingSetRec->VerifyAndAllocateSet(
receiveInfo->TmmbnBoundingSet.lengthOfSet() + 1);
for(uint32_t i=0; i< receiveInfo->TmmbnBoundingSet.lengthOfSet();
i++) {
if(receiveInfo->TmmbnBoundingSet.Ssrc(i) == main_ssrc_) {
// owner of bounding set
*tmmbrOwner = true;
}
boundingSetRec->SetEntry(i,
receiveInfo->TmmbnBoundingSet.Tmmbr(i),
receiveInfo->TmmbnBoundingSet.PacketOH(i),
receiveInfo->TmmbnBoundingSet.Ssrc(i));
}
}
return receiveInfo->TmmbnBoundingSet.lengthOfSet();
RTC_DCHECK(receiveInfo);
*tmmbr_owner = TMMBRHelp::IsOwner(receiveInfo->tmmbn, main_ssrc_);
return receiveInfo->tmmbn;
}
void RTCPReceiver::HandleSDES(RTCPUtility::RTCPParserV2& rtcpParser,
@ -838,7 +818,7 @@ void RTCPReceiver::HandleBYE(RTCPUtility::RTCPParserV2& rtcpParser) {
_receivedInfoMap.find(rtcpPacket.BYE.SenderSSRC);
if (receiveInfoIt != _receivedInfoMap.end()) {
receiveInfoIt->second->readyForDelete = true;
receiveInfoIt->second->ready_for_delete = true;
}
std::map<uint32_t, RTCPCnameInformation*>::iterator cnameInfoIt =
@ -1007,7 +987,6 @@ void RTCPReceiver::HandleTMMBR(RTCPUtility::RTCPParserV2& rtcpParser,
rtcpParser.Iterate();
return;
}
ptrReceiveInfo->VerifyAndAllocateTMMBRSet((uint32_t)maxNumOfTMMBRBlocks);
RTCPUtility::RTCPPacketTypes pktType = rtcpParser.Iterate();
while (pktType == RTCPPacketTypes::kRtpfbTmmbrItem) {
@ -1022,7 +1001,11 @@ void RTCPReceiver::HandleTMMBRItem(RTCPReceiveInformation& receiveInfo,
uint32_t senderSSRC) {
if (main_ssrc_ == rtcpPacket.TMMBRItem.SSRC &&
rtcpPacket.TMMBRItem.MaxTotalMediaBitRate > 0) {
receiveInfo.InsertTMMBRItem(senderSSRC, rtcpPacket.TMMBRItem,
receiveInfo.InsertTmmbrItem(
senderSSRC,
rtcp::TmmbItem(rtcpPacket.TMMBRItem.SSRC,
rtcpPacket.TMMBRItem.MaxTotalMediaBitRate * 1000,
rtcpPacket.TMMBRItem.MeasuredOverhead),
_clock->TimeInMilliseconds());
rtcpPacketInformation.rtcpPacketTypeFlags |= kRtcpTmmbr;
}
@ -1050,8 +1033,6 @@ void RTCPReceiver::HandleTMMBN(RTCPUtility::RTCPParserV2& rtcpParser,
return;
}
ptrReceiveInfo->VerifyAndAllocateBoundingSet((uint32_t)maxNumOfTMMBNBlocks);
RTCPUtility::RTCPPacketTypes pktType = rtcpParser.Iterate();
while (pktType == RTCPPacketTypes::kRtpfbTmmbnItem) {
HandleTMMBNItem(*ptrReceiveInfo, rtcpPacket);
@ -1067,10 +1048,10 @@ void RTCPReceiver::HandleSR_REQ(RTCPUtility::RTCPParserV2& rtcpParser,
void RTCPReceiver::HandleTMMBNItem(RTCPReceiveInformation& receiveInfo,
const RTCPUtility::RTCPPacket& rtcpPacket) {
receiveInfo.TmmbnBoundingSet.AddEntry(
rtcpPacket.TMMBNItem.MaxTotalMediaBitRate,
rtcpPacket.TMMBNItem.MeasuredOverhead,
rtcpPacket.TMMBNItem.SSRC);
receiveInfo.tmmbn.emplace_back(
rtcpPacket.TMMBNItem.SSRC,
rtcpPacket.TMMBNItem.MaxTotalMediaBitRate * 1000,
rtcpPacket.TMMBNItem.MeasuredOverhead);
}
void RTCPReceiver::HandleSLI(RTCPUtility::RTCPParserV2& rtcpParser,
@ -1186,12 +1167,12 @@ void RTCPReceiver::HandleFIRItem(RTCPReceiveInformation* receiveInfo,
if (receiveInfo) {
// check if we have reported this FIRSequenceNumber before
if (rtcpPacket.FIRItem.CommandSequenceNumber !=
receiveInfo->lastFIRSequenceNumber) {
receiveInfo->last_fir_sequence_number) {
int64_t now = _clock->TimeInMilliseconds();
// sanity; don't go crazy with the callbacks
if ((now - receiveInfo->lastFIRRequest) > RTCP_MIN_FRAME_LENGTH_MS) {
receiveInfo->lastFIRRequest = now;
receiveInfo->lastFIRSequenceNumber =
if ((now - receiveInfo->last_fir_request_ms) > RTCP_MIN_FRAME_LENGTH_MS) {
receiveInfo->last_fir_request_ms = now;
receiveInfo->last_fir_sequence_number =
rtcpPacket.FIRItem.CommandSequenceNumber;
// received signal that we need to send a new key frame
rtcpPacketInformation.rtcpPacketTypeFlags |= kRtcpFir;
@ -1402,7 +1383,7 @@ std::vector<rtcp::TmmbItem> RTCPReceiver::TMMBRReceived() const {
for (const auto& kv : _receivedInfoMap) {
RTCPReceiveInformation* receive_info = kv.second;
RTC_DCHECK(receive_info);
receive_info->GetTMMBRSet(now_ms, &candidates);
receive_info->GetTmmbrSet(now_ms, &candidates);
}
return candidates;
}

View File

@ -96,7 +96,7 @@ public:
bool UpdateRTCPReceiveInformationTimers();
int32_t BoundingSet(bool* tmmbrOwner, TMMBRSet* boundingSetRec);
std::vector<rtcp::TmmbItem> BoundingSet(bool* tmmbr_owner);
int32_t UpdateTMMBR();
@ -112,9 +112,6 @@ protected:
uint32_t remoteSSRC);
RTCPHelp::RTCPReceiveInformation* GetReceiveInformation(uint32_t remoteSSRC);
void UpdateReceiveInformation(
RTCPHelp::RTCPReceiveInformation& receiveInformation);
void HandleSenderReceiverReport(
RTCPUtility::RTCPParserV2& rtcpParser,
RTCPHelp::RTCPPacketInformation& rtcpPacketInformation)

View File

@ -115,72 +115,38 @@ RTCPReportBlockInformation::~RTCPReportBlockInformation()
{
}
RTCPReceiveInformation::RTCPReceiveInformation()
: lastTimeReceived(0),
lastFIRSequenceNumber(-1),
lastFIRRequest(0),
readyForDelete(false) {
RTCPReceiveInformation::RTCPReceiveInformation() = default;
RTCPReceiveInformation::~RTCPReceiveInformation() = default;
void RTCPReceiveInformation::InsertTmmbrItem(uint32_t sender_ssrc,
const rtcp::TmmbItem& tmmbr_item,
int64_t current_time_ms) {
TimedTmmbrItem* entry = &tmmbr_[sender_ssrc];
entry->tmmbr_item = rtcp::TmmbItem(sender_ssrc,
tmmbr_item.bitrate_bps(),
tmmbr_item.packet_overhead());
entry->last_updated_ms = current_time_ms;
}
RTCPReceiveInformation::~RTCPReceiveInformation() {
}
// Increase size of TMMBRSet if needed, and also take care of
// the _tmmbrSetTimeouts vector.
void RTCPReceiveInformation::VerifyAndAllocateTMMBRSet(
const uint32_t minimumSize) {
if (minimumSize > TmmbrSet.sizeOfSet()) {
TmmbrSet.VerifyAndAllocateSetKeepingData(minimumSize);
// make sure that our buffers are big enough
_tmmbrSetTimeouts.reserve(minimumSize);
}
}
void RTCPReceiveInformation::InsertTMMBRItem(
const uint32_t senderSSRC,
const RTCPUtility::RTCPPacketRTPFBTMMBRItem& TMMBRItem,
const int64_t currentTimeMS) {
// serach to see if we have it in our list
for (uint32_t i = 0; i < TmmbrSet.lengthOfSet(); i++) {
if (TmmbrSet.Ssrc(i) == senderSSRC) {
// we already have this SSRC in our list update it
TmmbrSet.SetEntry(i,
TMMBRItem.MaxTotalMediaBitRate,
TMMBRItem.MeasuredOverhead,
senderSSRC);
_tmmbrSetTimeouts[i] = currentTimeMS;
return;
}
}
VerifyAndAllocateTMMBRSet(TmmbrSet.lengthOfSet() + 1);
TmmbrSet.AddEntry(TMMBRItem.MaxTotalMediaBitRate,
TMMBRItem.MeasuredOverhead,
senderSSRC);
_tmmbrSetTimeouts.push_back(currentTimeMS);
}
void RTCPReceiveInformation::GetTMMBRSet(
void RTCPReceiveInformation::GetTmmbrSet(
int64_t current_time_ms,
std::vector<rtcp::TmmbItem>* candidates) {
// Use audio define since we don't know what interval the remote peer use.
int64_t timeouted_ms = current_time_ms - 5 * RTCP_INTERVAL_AUDIO_MS;
for (auto it = tmmbr_.begin(); it != tmmbr_.end();) {
if (it->second.last_updated_ms < timeouted_ms) {
// Erase timeout entries.
for (size_t source_idx = 0; source_idx < TmmbrSet.size();) {
// Use audio define since we don't know what interval the remote peer is
// using.
if (current_time_ms - _tmmbrSetTimeouts[source_idx] >
5 * RTCP_INTERVAL_AUDIO_MS) {
// Value timed out.
TmmbrSet.erase(TmmbrSet.begin() + source_idx);
_tmmbrSetTimeouts.erase(_tmmbrSetTimeouts.begin() + source_idx);
continue;
it = tmmbr_.erase(it);
} else {
candidates->push_back(it->second.tmmbr_item);
++it;
}
candidates->push_back(TmmbrSet[source_idx]);
++source_idx;
}
}
void RTCPReceiveInformation::VerifyAndAllocateBoundingSet(
const uint32_t minimumSize) {
TmmbnBoundingSet.VerifyAndAllocateSet(minimumSize);
void RTCPReceiveInformation::ClearTmmbr() {
tmmbr_.clear();
}
} // namespace RTCPHelp
} // namespace webrtc

View File

@ -12,12 +12,12 @@
#define WEBRTC_MODULES_RTP_RTCP_SOURCE_RTCP_RECEIVER_HELP_H_
#include <list>
#include <map>
#include <memory>
#include <vector>
#include "webrtc/base/constructormagic.h"
#include "webrtc/modules/rtp_rtcp/include/rtp_rtcp_defines.h" // RTCPReportBlock
#include "webrtc/modules/rtp_rtcp/source/rtcp_utility.h"
#include "webrtc/modules/rtp_rtcp/include/rtp_rtcp_defines.h"
#include "webrtc/modules/rtp_rtcp/source/tmmbr_help.h"
#include "webrtc/typedefs.h"
@ -95,38 +95,36 @@ private:
RTC_DISALLOW_COPY_AND_ASSIGN(RTCPPacketInformation);
};
class RTCPReceiveInformation
{
public:
class RTCPReceiveInformation {
public:
RTCPReceiveInformation();
~RTCPReceiveInformation();
void VerifyAndAllocateBoundingSet(const uint32_t minimumSize);
void VerifyAndAllocateTMMBRSet(const uint32_t minimumSize);
void InsertTmmbrItem(uint32_t sender_ssrc,
const rtcp::TmmbItem& tmmbr_item,
int64_t current_time_ms);
void InsertTMMBRItem(const uint32_t senderSSRC,
const RTCPUtility::RTCPPacketRTPFBTMMBRItem& TMMBRItem,
const int64_t currentTimeMS);
// get
void GetTMMBRSet(int64_t current_time_ms,
void GetTmmbrSet(int64_t current_time_ms,
std::vector<rtcp::TmmbItem>* candidates);
int64_t lastTimeReceived;
void ClearTmmbr();
// FIR
int32_t lastFIRSequenceNumber;
int64_t lastFIRRequest;
int64_t last_time_received_ms = 0;
// TMMBN
TMMBRSet TmmbnBoundingSet;
int32_t last_fir_sequence_number = -1;
int64_t last_fir_request_ms = 0;
// TMMBR
TMMBRSet TmmbrSet;
bool ready_for_delete = false;
bool readyForDelete;
private:
std::vector<int64_t> _tmmbrSetTimeouts;
std::vector<rtcp::TmmbItem> tmmbn;
private:
struct TimedTmmbrItem {
rtcp::TmmbItem tmmbr_item;
int64_t last_updated_ms;
};
std::map<uint32_t, TimedTmmbrItem> tmmbr_;
};
} // end namespace RTCPHelp

View File

@ -172,7 +172,7 @@ RTCPSender::RTCPSender(
remb_bitrate_(0),
tmmbr_send_(0),
tmmbr_send_bps_(0),
packet_oh_send_(0),
max_payload_length_(IP_PACKET_SIZE - 28), // IPv4 + UDP by default.
@ -577,7 +577,7 @@ std::unique_ptr<rtcp::RtcpPacket> RTCPSender::BuildREMB(
void RTCPSender::SetTargetBitrate(unsigned int target_bitrate) {
rtc::CritScope lock(&critical_section_rtcp_sender_);
tmmbr_send_ = target_bitrate / 1000;
tmmbr_send_bps_ = target_bitrate;
}
std::unique_ptr<rtcp::RtcpPacket> RTCPSender::BuildTMMBR(
@ -590,48 +590,46 @@ std::unique_ptr<rtcp::RtcpPacket> RTCPSender::BuildTMMBR(
// * If not an owner but the TMMBR would enter the TMMBN -> send TMMBR
// get current bounding set from RTCP receiver
bool tmmbrOwner = false;
TMMBRSet candidates;
bool tmmbr_owner = false;
// holding critical_section_rtcp_sender_ while calling RTCPreceiver which
// will accuire criticalSectionRTCPReceiver_ is a potental deadlock but
// since RTCPreceiver is not doing the reverse we should be fine
int32_t lengthOfBoundingSet =
ctx.feedback_state_.module->BoundingSet(&tmmbrOwner, &candidates);
std::vector<rtcp::TmmbItem> candidates =
ctx.feedback_state_.module->BoundingSet(&tmmbr_owner);
if (lengthOfBoundingSet > 0) {
for (int32_t i = 0; i < lengthOfBoundingSet; i++) {
if (candidates.Tmmbr(i) == tmmbr_send_ &&
candidates.PacketOH(i) == packet_oh_send_) {
if (!candidates.empty()) {
for (const auto& candidate : candidates) {
if (candidate.bitrate_bps() == tmmbr_send_bps_ &&
candidate.packet_overhead() == packet_oh_send_) {
// Do not send the same tuple.
return nullptr;
}
}
if (!tmmbrOwner) {
// use received bounding set as candidate set
// add current tuple
candidates.SetEntry(lengthOfBoundingSet, tmmbr_send_, packet_oh_send_,
ssrc_);
if (!tmmbr_owner) {
// Use received bounding set as candidate set.
// Add current tuple.
candidates.emplace_back(ssrc_, tmmbr_send_bps_, packet_oh_send_);
// find bounding set
// Find bounding set.
std::vector<rtcp::TmmbItem> bounding =
TMMBRHelp::FindBoundingSet(std::move(candidates));
tmmbrOwner = TMMBRHelp::IsOwner(bounding, ssrc_);
if (!tmmbrOwner) {
tmmbr_owner = TMMBRHelp::IsOwner(bounding, ssrc_);
if (!tmmbr_owner) {
// Did not enter bounding set, no meaning to send this request.
return nullptr;
}
}
}
if (!tmmbr_send_)
if (!tmmbr_send_bps_)
return nullptr;
rtcp::Tmmbr* tmmbr = new rtcp::Tmmbr();
tmmbr->From(ssrc_);
rtcp::TmmbItem request;
request.set_ssrc(remote_ssrc_);
request.set_bitrate_bps(tmmbr_send_ * 1000);
request.set_bitrate_bps(tmmbr_send_bps_);
request.set_packet_overhead(packet_oh_send_);
tmmbr->WithTmmbr(request);

View File

@ -241,7 +241,7 @@ class RTCPSender {
std::vector<rtcp::TmmbItem> tmmbn_to_send_
GUARDED_BY(critical_section_rtcp_sender_);
uint32_t tmmbr_send_ GUARDED_BY(critical_section_rtcp_sender_);
uint32_t tmmbr_send_bps_ GUARDED_BY(critical_section_rtcp_sender_);
uint32_t packet_oh_send_ GUARDED_BY(critical_section_rtcp_sender_);
size_t max_payload_length_;

View File

@ -925,9 +925,8 @@ bool ModuleRtpRtcpImpl::UpdateRTCPReceiveInformationTimers() {
}
// Called from RTCPsender.
int32_t ModuleRtpRtcpImpl::BoundingSet(bool* tmmbr_owner,
TMMBRSet* bounding_set) {
return rtcp_receiver_.BoundingSet(tmmbr_owner, bounding_set);
std::vector<rtcp::TmmbItem> ModuleRtpRtcpImpl::BoundingSet(bool* tmmbr_owner) {
return rtcp_receiver_.BoundingSet(tmmbr_owner);
}
int64_t ModuleRtpRtcpImpl::RtcpReportInterval() {

View File

@ -297,7 +297,7 @@ class ModuleRtpRtcpImpl : public RtpRtcp {
bool LastReceivedXrReferenceTimeInfo(RtcpReceiveTimeInfo* info) const;
int32_t BoundingSet(bool* tmmbr_owner, TMMBRSet* bounding_set_rec);
std::vector<rtcp::TmmbItem> BoundingSet(bool* tmmbr_owner);
void BitrateSent(uint32_t* total_rate,
uint32_t* video_rate,

View File

@ -16,40 +16,6 @@
#include "webrtc/base/checks.h"
namespace webrtc {
void TMMBRSet::VerifyAndAllocateSet(uint32_t minimumSize) {
clear();
reserve(minimumSize);
}
void TMMBRSet::VerifyAndAllocateSetKeepingData(uint32_t minimumSize) {
reserve(minimumSize);
}
void TMMBRSet::SetEntry(unsigned int i,
uint32_t tmmbrSet,
uint32_t packetOHSet,
uint32_t ssrcSet) {
RTC_DCHECK_LT(i, capacity());
if (i >= size()) {
resize(i + 1);
}
(*this)[i].set_bitrate_bps(tmmbrSet * 1000);
(*this)[i].set_packet_overhead(packetOHSet);
(*this)[i].set_ssrc(ssrcSet);
}
void TMMBRSet::AddEntry(uint32_t tmmbrSet,
uint32_t packetOHSet,
uint32_t ssrcSet) {
RTC_DCHECK_LT(size(), capacity());
SetEntry(size(), tmmbrSet, packetOHSet, ssrcSet);
}
void TMMBRSet::RemoveEntry(uint32_t sourceIdx) {
RTC_DCHECK_LT(sourceIdx, size());
erase(begin() + sourceIdx);
}
std::vector<rtcp::TmmbItem> TMMBRHelp::FindBoundingSet(
std::vector<rtcp::TmmbItem> candidates) {
// Filter out candidates with 0 bitrate.

View File

@ -16,28 +16,6 @@
#include "webrtc/typedefs.h"
namespace webrtc {
class TMMBRSet : public std::vector<rtcp::TmmbItem> {
public:
void VerifyAndAllocateSet(uint32_t minimumSize);
void VerifyAndAllocateSetKeepingData(uint32_t minimumSize);
// Number of valid data items in set.
uint32_t lengthOfSet() const { return size(); }
// Presently allocated max size of set.
uint32_t sizeOfSet() const { return capacity(); }
void clearSet() { clear(); }
uint32_t Tmmbr(int i) const { return (*this)[i].bitrate_bps() / 1000; }
uint32_t PacketOH(int i) const { return (*this)[i].packet_overhead(); }
uint32_t Ssrc(int i) const { return (*this)[i].ssrc(); }
void SetEntry(unsigned int i,
uint32_t tmmbrSet,
uint32_t packetOHSet,
uint32_t ssrcSet);
void AddEntry(uint32_t tmmbrSet, uint32_t packetOHSet, uint32_t ssrcSet);
// Remove one entry from table, and move all others down.
void RemoveEntry(uint32_t sourceIdx);
};
class TMMBRHelp {
public: