// Makes pBuf available to resource connected to the outPortIdx output // port of this resource. // Returns TRUE if there is a resource connected to the specified output // port, FALSE otherwise. UtlBoolean MpResource::pushBufferDownsream(int outPortIdx, const MpBufPtr& pBuf) { MpResource* pDownstreamInput; int downstreamPortIdx; // Not locking mpOutConns here as we only lock for setting/accessing // reservation state (the only thing set in mpOutConns outside media task) if (outPortIdx < 0 || outPortIdx >= mMaxOutputs) // port out of range return FALSE; pDownstreamInput = mpOutConns[outPortIdx].pResource; downstreamPortIdx = mpOutConns[outPortIdx].portIndex; if (pDownstreamInput == NULL) // no connected resource return FALSE; pDownstreamInput->setInputBuffer(downstreamPortIdx, pBuf); return TRUE; }