--- a/ipappsrv_plat/media_control_api/inc/mmcccodecinformation.h Wed Sep 15 12:38:06 2010 +0300
+++ b/ipappsrv_plat/media_control_api/inc/mmcccodecinformation.h Wed Oct 13 14:59:15 2010 +0300
@@ -584,8 +584,8 @@
virtual TInt PriorityPreference( ) const;
/**
- * Get keep alive packets send timer value in seconds.
- * @return keep alive packets send timer value in seconds.
+ * Get keep alive packets send timer value.
+ * @return keep alive packets send timer value.
*/
virtual TUint8 KeepAliveTimer() const;
@@ -742,21 +742,7 @@
*/
virtual TInt GetInterleaving() const;
-public:
-
- /**
- * Set keep alive packets send timer value.
- * @param aTimerValueMicroSecs timer value in microseconds for keep alive packets
- * @return One of the standard system-wide error codes.
- */
- virtual TInt SetKeepAliveTimerMicroSecs( TUint32 aTimerValueMicroSecs );
-
- /**
- * Get keep alive packets send timer value in microseconds.
- * @return keep alive packets send timer value in microseconds.
- */
- virtual TUint32 KeepAliveTimerMicroSecs() const;
-
+
protected: // Data
/**
@@ -950,7 +936,7 @@
TUint iVideoHeight;
/**
- * Timer value for keep alive data, seconds
+ * Timer value for keep alive data
*/
TUint8 iKeepAliveTimer;
@@ -984,12 +970,7 @@
* Encoder/decoder uid
*/
TUid iEncodingDecodingDevice;
-
- /**
- * Timer value for keep alive data, microseconds
- */
- TUint32 iKeepAliveTimerMicroSecs;
-
+
private:
#ifdef TEST_EUNIT
--- a/ipappsrv_plat/media_control_api/inc/mmccevents.h Wed Sep 15 12:38:06 2010 +0300
+++ b/ipappsrv_plat/media_control_api/inc/mmccevents.h Wed Oct 13 14:59:15 2010 +0300
@@ -400,65 +400,6 @@
};
typedef TPckgBuf<TMccDtmfEventData> TMccDtmfEventDataPackage;
-
-
-/**
-* Rtp SourceSink event data, extended version
-*/
-class TMccRtpEventDataExtended : public TMccRtpEventData
- {
- public:
-
- /**
- * Default constructor
- */
- inline TMccRtpEventDataExtended() :
- TMccRtpEventData(),
- iPacketLoss( 0 ),
- iTriggeredPacketLoss( 0 )
- {
- }
-
- /**
- * Copy constructor
- */
- inline TMccRtpEventDataExtended( const TMccRtpEventDataExtended& aEvent ) :
- TMccRtpEventData( aEvent ),
- iPacketLoss( aEvent.iPacketLoss ),
- iTriggeredPacketLoss( aEvent.iTriggeredPacketLoss )
- {
- }
-
-
- /**
- * parametrized constructor
- */
- inline TMccRtpEventDataExtended( TInt64 aEstimate,
- TUint32 aPcksRec,
- TInt64 aPrevTransTime,
- TUint64 aTriggeredJitterLevel,
- TInt aPacketLoss,
- TInt aTriggeredPacketLoss ) :
- TMccRtpEventData( aEstimate,
- aPcksRec,
- aPrevTransTime,
- aTriggeredJitterLevel ),
- iPacketLoss( aPacketLoss ),
- iTriggeredPacketLoss( aTriggeredPacketLoss )
- {
- }
-
- public: // Data
-
- // Current packet loss percentage
- TInt iPacketLoss;
-
- // Triggered packet loss percentage
- TInt iTriggeredPacketLoss;
-
- };
-
-typedef TPckgBuf<TMccRtpEventDataExtended> TMccRtpEventDataExtendedPackage;
#endif // MMCCEVENTS_H
--- a/multimediacommscontroller/mmccfilesourcesink/inc/mccfilesink.h Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccfilesourcesink/inc/mccfilesink.h Wed Oct 13 14:59:15 2010 +0300
@@ -230,8 +230,6 @@
TBool iDecSpecInfoProvided;
TBool iKeyFrameProvided;
-
- TInt64 iCurrAvgTimestampDifference;
#ifdef EUNIT_TEST
friend class UT_CMccFileSink;
--- a/multimediacommscontroller/mmccfilesourcesink/src/mccfilesink.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccfilesourcesink/src/mccfilesink.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -33,8 +33,7 @@
const TInt KMccMaxNumTimestamps = 5;
-// used for Calculate Average Timestamp
-const TInt KMccDefaultAvgTimestampDiff = 66000;
+const TInt KMccTimestampDifferenceMultiplier = 10;
// ============================ MEMBER FUNCTIONS ===============================
@@ -72,8 +71,7 @@
// -----------------------------------------------------------------------------
//
CMccFileSink::CMccFileSink() :
- CMccDataSink( KMccFileSinkUid ),
- iCurrAvgTimestampDifference( KMccDefaultAvgTimestampDiff )
+ CMccDataSink( KMccFileSinkUid )
{
iVideoCodec.iFourCC = TFourCC( KMccFourCCIdH263 );
// FJKI-7J58CB no use case for audio in file, hence removing the audio track capability
@@ -567,10 +565,6 @@
averageTimeStampDifference = averageTimeStampDifference / ( KMccMaxNumTimestamps - 1 );
}
- if ( averageTimeStampDifference > 0 )
- {
- iCurrAvgTimestampDifference = averageTimeStampDifference;
- }
if ( aCurrentTimestamp > iPreviousTimestamp )
{
@@ -580,19 +574,19 @@
}
iTimestamps.AppendL( aCurrentTimestamp.Int64() );
}
- else if ( aCurrentTimestamp < iPreviousTimestamp )
+ else
{
- TInt64 currDifference = iPreviousTimestamp.Int64() - aCurrentTimestamp.Int64();
- iAddToTimestamp += ( currDifference + iCurrAvgTimestampDifference );
- iTimestamps.Reset();
- iPausedDuration = 0;
+ TInt64 currDifference = iPreviousTimestamp.Int64() - aCurrentTimestamp.Int64();
+ if ( averageTimeStampDifference != 0 &&
+ currDifference > ( averageTimeStampDifference * KMccTimestampDifferenceMultiplier ) )
+ {
+ iAddToTimestamp += ( currDifference + averageTimeStampDifference );
+ iTimestamps.Reset();
+ iPausedDuration = 0;
- __FILESINK_CONTROLL_INT1("CMccFileSink::TimeToPlay, iAddToTimestamp=", iAddToTimestamp )
+ __FILESINK_CONTROLL_INT1("CMccFileSink::TimeToPlay, iAddToTimestamp=", iAddToTimestamp )
+ }
}
- else
- {
- // NOP
- }
}
// -----------------------------------------------------------------------------
--- a/multimediacommscontroller/mmccfilesourcesink/tsrc/ut_filesourcesink/Inc/UT_CMccFileSink.h Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccfilesourcesink/tsrc/ut_filesourcesink/Inc/UT_CMccFileSink.h Wed Oct 13 14:59:15 2010 +0300
@@ -141,8 +141,6 @@
void UT_CMccFileSink_UpdateActiveUserL();
- void UT_CMccFileSink_CalculateAverageTimestampDifferenceL();
-
private: // Helpers
CMccTestEventHandler* AddUserL( TBool aIsAvc = EFalse );
--- a/multimediacommscontroller/mmccfilesourcesink/tsrc/ut_filesourcesink/Src/UT_CMccFileSink.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccfilesourcesink/tsrc/ut_filesourcesink/Src/UT_CMccFileSink.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -613,41 +613,6 @@
EUNIT_ASSERT_EQUALS( iFileSink->iActiveUserIndex, 1 );
EUNIT_ASSERT( iFileSink->iAsyncEventHandler == iEventHandler2 );
}
-
-void UT_CMccFileSink::UT_CMccFileSink_CalculateAverageTimestampDifferenceL()
- {
- const TInt KMccMaxNumTimestamps = 5;
- const TInt KMccTimestampDifferenceMultiplier = 10;
- TInt originalTime(1000);
- TInt timeIncrement(1000);
-
- iFileSink->iCurrAvgTimestampDifference = 0;
-
- // Ask so long that average timestamp difference can be calculated
- for (TInt i = 0; i < (KMccTimestampDifferenceMultiplier + 2); i++)
- {
- TTimeIntervalMicroSeconds timeToPlay = iFileSink->TimeToPlayL(
- TTimeIntervalMicroSeconds(originalTime));
-
- EUNIT_ASSERT_EQUALS( timeToPlay.Int64(), originalTime );
-
- originalTime += timeIncrement;
- }
-
- EUNIT_ASSERT_EQUALS( iFileSink->iTimestamps.Count(), KMccMaxNumTimestamps );
- EUNIT_ASSERT_GREATER( iFileSink->iCurrAvgTimestampDifference, 0 );
-
- iFileSink->iTimestamps.Reset();
- iFileSink->iPreviousTimestamp = 500;
- iFileSink->TimeToPlayL( TTimeIntervalMicroSeconds( originalTime ) );
- EUNIT_ASSERT_GREATER( iFileSink->iTimestamps.Count(), 0 );
-
- originalTime = 1000;
- iFileSink->iAddToTimestamp = 0;
- iFileSink->iPreviousTimestamp = 1010;
- iFileSink->TimeToPlayL( TTimeIntervalMicroSeconds( originalTime ) );
- EUNIT_ASSERT_GREATER( iFileSink->iAddToTimestamp, 0 );
- }
// HELPERS
@@ -847,13 +812,6 @@
"UpdateActiveUserL",
"FUNCTIONALITY",
SetupL, UT_CMccFileSink_UpdateActiveUserL, Teardown)
-
-EUNIT_TEST(
- "CalculateAverageTimestampDifferenceL - test ",
- "CMccFileSink",
- "CalculateAverageTimestampDifferenceL",
- "FUNCTIONALITY",
- SetupL, UT_CMccFileSink_CalculateAverageTimestampDifferenceL, Teardown)
EUNIT_END_TEST_TABLE
--- a/multimediacommscontroller/mmccinterface/src/mmcccodecinformation.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccinterface/src/mmcccodecinformation.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -37,7 +37,6 @@
const TUint KDefaultPreference = EMdaPriorityPreferenceNone;
const TUint KDefaultPriority = EMdaPriorityNormal;
const TInt KDefaultModeChangePeriod = 1;
-const TUint KMccSecsToMicroSecs = 1000000;
// MACROS
@@ -137,16 +136,7 @@
iFrameSize = codecInfo.iFrameSize;
iHwFrameTime = codecInfo.iHwFrameTime;
- if( (codecInfo.iKeepaliveInterval / KMccSecsToMicroSecs) > KMaxTUint8 )
- {
- iKeepAliveTimer = KMaxTUint8;
- iKeepAliveTimerMicroSecs = KMaxTUint8 * KMccSecsToMicroSecs;
- }
- else
- {
- iKeepAliveTimer = codecInfo.iKeepaliveInterval / KMccSecsToMicroSecs;
- iKeepAliveTimerMicroSecs = codecInfo.iKeepaliveInterval;
- }
+ iKeepAliveTimer = codecInfo.iKeepaliveInterval;
iKeepAlivePT = codecInfo.iKeepalivePT;
iKeepAliveData = codecInfo.iKeepaliveData;
@@ -198,7 +188,7 @@
codecInfo.iRedundantPayload = iRedundancyPT;
codecInfo.iNeighbor = iNeighbor;
codecInfo.iModeChangePeriod = iModeChangePeriod;
- codecInfo.iKeepaliveInterval = iKeepAliveTimerMicroSecs;
+ codecInfo.iKeepaliveInterval = iKeepAliveTimer;
codecInfo.iKeepalivePT = iKeepAlivePT;
codecInfo.iKeepaliveData = iKeepAliveData;
codecInfo.iMaxRed = iMaxRed;
@@ -934,7 +924,6 @@
TInt CMccCodecInformation::SetKeepAliveTimer( TUint8 aTimerValue )
{
iKeepAliveTimer = aTimerValue;
- iKeepAliveTimerMicroSecs = aTimerValue * KMccSecsToMicroSecs;
return KErrNone;
}
@@ -994,34 +983,3 @@
{
return iKeepAliveData;
}
-
-// -----------------------------------------------------------------------------
-// CMccCodecInformation:SetKeepAliveTimerMicroSecs
-// Default implementation
-// -----------------------------------------------------------------------------
-//
-TInt CMccCodecInformation::SetKeepAliveTimerMicroSecs(
- TUint32 aTimerValueMicroSecs )
- {
- if( (aTimerValueMicroSecs / KMccSecsToMicroSecs) > KMaxTUint8 )
- {
- iKeepAliveTimer = KMaxTUint8;
- iKeepAliveTimerMicroSecs = KMaxTUint8 * KMccSecsToMicroSecs;
- }
- else
- {
- iKeepAliveTimer = aTimerValueMicroSecs / KMccSecsToMicroSecs;
- iKeepAliveTimerMicroSecs = aTimerValueMicroSecs;
- }
- return KErrNone;
- }
-
-// -----------------------------------------------------------------------------
-// CMccCodecInformation:KeepAliveTimerMicroSecs
-// Default implementation
-// -----------------------------------------------------------------------------
-//
-TUint32 CMccCodecInformation::KeepAliveTimerMicroSecs() const
- {
- return iKeepAliveTimerMicroSecs;
- }
--- a/multimediacommscontroller/mmccinterface/tsrc/ut_interface/inc/UT_CMCCCodecInformation.h Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccinterface/tsrc/ut_interface/inc/UT_CMCCCodecInformation.h Wed Oct 13 14:59:15 2010 +0300
@@ -156,9 +156,6 @@
void UT_CMccCodecInformation_SetKeepAliveTimerL();
-
-
- void UT_CMccCodecInformation_SetKeepAliveTimerMicroSecsL();
void UT_CMccCodecInformation_SetKeepAlivePTL();
@@ -255,9 +252,6 @@
void UT_CMccCodecInformation_KeepAliveTimerL();
-
-
- void UT_CMccCodecInformation_KeepAliveTimerMicroSecsL();
void UT_CMccCodecInformation_KeepAlivePTL();
--- a/multimediacommscontroller/mmccinterface/tsrc/ut_interface/src/UT_CMCCCodecInformation.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccinterface/tsrc/ut_interface/src/UT_CMCCCodecInformation.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -809,25 +809,11 @@
void UT_CMccCodecInformation::UT_CMccCodecInformation_SetKeepAliveTimerL( )
{
- const TInt KNum25 = 25;
- const TInt KSecsToMicroSecs = 1000000;
for( TInt k = 0; k < iCount; k++ )
{
- EUNIT_ASSERT_EQUALS( iCodecArray[k]->SetKeepAliveTimer( KNum25 ), KErrNone );
- EUNIT_ASSERT_EQUALS( iCodecArray[k]->KeepAliveTimerMicroSecs(), KNum25 * KSecsToMicroSecs );
+ EUNIT_ASSERT_EQUALS( iCodecArray[k]->SetKeepAliveTimer( 25 ), KErrNone );
}
}
-
-void UT_CMccCodecInformation::UT_CMccCodecInformation_SetKeepAliveTimerMicroSecsL( )
- {
- const TInt KNum2000000 = 2000000;
- const TInt KSecsToMicroSecs = 1000000;
- for( TInt k = 0; k < iCount; k++ )
- {
- EUNIT_ASSERT_EQUALS( iCodecArray[k]->SetKeepAliveTimerMicroSecs( 2000000 ), KErrNone );
- EUNIT_ASSERT_EQUALS( iCodecArray[k]->KeepAliveTimer(), KNum2000000 / KSecsToMicroSecs );
- }
- }
void UT_CMccCodecInformation::UT_CMccCodecInformation_SetKeepAlivePTL( )
{
@@ -1229,15 +1215,6 @@
iCodecArray[k]->iKeepAliveTimer );
}
}
-
-void UT_CMccCodecInformation::UT_CMccCodecInformation_KeepAliveTimerMicroSecsL( )
- {
- for( TInt k = 0; k < iCount; k++ )
- {
- EUNIT_ASSERT_EQUALS( iCodecArray[k]->KeepAliveTimerMicroSecs(),
- iCodecArray[k]->iKeepAliveTimerMicroSecs );
- }
- }
void UT_CMccCodecInformation::UT_CMccCodecInformation_KeepAlivePTL( )
{
@@ -1756,13 +1733,6 @@
"SetKeepAliveTimer",
"FUNCTIONALITY",
SetupL, UT_CMccCodecInformation_SetKeepAliveTimerL, Teardown)
-
-EUNIT_TEST(
- "SetKeepAliveTimerMicroSecs - test ",
- "CMccCodecInformation",
- "SetKeepAliveTimerMicroSecs",
- "FUNCTIONALITY",
- SetupL, UT_CMccCodecInformation_SetKeepAliveTimerMicroSecsL, Teardown)
EUNIT_TEST(
"SetKeepAlivePT - test ",
@@ -1987,13 +1957,6 @@
"KeepAliveTimer",
"FUNCTIONALITY",
SetupL, UT_CMccCodecInformation_KeepAliveTimerL, Teardown)
-
-EUNIT_TEST(
- "KeepAliveTimerMicroSecs - test ",
- "CMccCodecInformation",
- "KeepAliveTimerMicroSecs",
- "FUNCTIONALITY",
- SetupL, UT_CMccCodecInformation_KeepAliveTimerMicroSecsL, Teardown)
EUNIT_TEST(
"KeepAlivePT - test ",
--- a/multimediacommscontroller/mmccjitterbuffer/group/jitterbuffer.mmp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccjitterbuffer/group/jitterbuffer.mmp Wed Oct 13 14:59:15 2010 +0300
@@ -46,6 +46,6 @@
LIBRARY ecom.lib
LIBRARY mmfcontrollerframework.lib
LIBRARY mmfserverbaseclasses.lib
-LIBRARY ErrorConcealmentIntfc.lib
+LIBRARY errorconcealmentintfc.lib
PAGED
--- a/multimediacommscontroller/mmccjitterbuffer/inc/mccjitterbufferimpl.h Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccjitterbuffer/inc/mccjitterbufferimpl.h Wed Oct 13 14:59:15 2010 +0300
@@ -355,9 +355,6 @@
*/
TBool iDropNextFrame;
- // Saved bufLenMultiplier from SetupL()
- TInt iBufLenMultiplier;
-
private:
#ifdef TEST_EUNIT
friend class UT_CMccJitterBufferImpl;
--- a/multimediacommscontroller/mmccjitterbuffer/src/mccjitterbufferimpl.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccjitterbuffer/src/mccjitterbufferimpl.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -116,8 +116,7 @@
iPlayToneInterval( 0 ),
iNotifyUser( ETrue ),
iLatestNotifiedEvent( KMccEventNone ),
- iSampleRate( KDefaultSampleRateInkHz ),
- iBufLenMultiplier( 1 )
+ iSampleRate( KDefaultSampleRateInkHz )
{
iTonePlayTime.UniversalTime();
}
@@ -208,145 +207,135 @@
__ASSERT_ALWAYS( aCInfo.iJitterBufBufferLength, User::Leave( KErrArgument ) );
__ASSERT_ALWAYS( aCInfo.iHwFrameTime, User::Leave( KErrArgument ) );
- if( aCInfo.iJitterBufInactivityTimeOut != iCInfo.iJitterBufInactivityTimeOut
- || aCInfo.iJitterBufBufferLength != iCInfo.iJitterBufBufferLength
- || aCInfo.iHwFrameTime != iCInfo.iHwFrameTime
- || aCInfo.iFourCC != iCInfo.iFourCC
- || aPlayoutThreshold != iOriginalPlayThreshold / iBufLenMultiplier )
- {
- // Save the original HW frame time because we may need it in case of
- // dynamic G.711 adjustment.
- const TUint8 origHwtime = iCInfo.iHwFrameTime;
- iCInfo = aCInfo;
- iEventHandler = aEventHandler;
- iEndpointId = aEndpointId;
-
- __JITTER_BUFFER_INT1( "CMccJitterBufferImpl::SetupL origHwtime:", origHwtime )
-
- if( iCInfo.iJitterBufInactivityTimeOut )
- {
- if( ( iCInfo.iJitterBufPlayToneFrequency > 0 ) &&
- ( iCInfo.iJitterBufPlayToneDuration > 0 ) )
- {
- iPlayToneInterval = iCInfo.iJitterBufPlayToneTimeout;
- iPlay = ETrue;
- }
- }
-
- TInt bufLenMultiplier = 1;
- if ( iCInfo.iFourCC == KMMFFourCCCodeAMR )
- {
- iFrameSize = KAMRNBFrameSize;
- iFrameTime = KAMRNBFrameTime;
- }
- else if ( iCInfo.iFourCC == KMMFFourCCCodeAWB )
- {
- iFrameSize = KAMRWBFrameSize;
- iFrameTime = KAMRNBFrameTime;
- iSampleRate = KWbSampleRateInkHz;
- }
- else if( iCInfo.iFourCC == KMccFourCCIdG711 )
- {
- // G.711 is configured dynamically. Take voip headerlength also in to
- // account. G.711 hwframetime is in milliseconds, so need to multiply.
- iFrameSize = ( iCInfo.iHwFrameTime * KDefaultSampleRateInkHz )
- + KVoIPHeaderLength;
- iFrameTime = 0;
-
- // In case of G.711 codec dynamic configuration, we may need to double
- // the jitterbuffer length if HW frame time is changed from 20ms to
- // 10ms.
- if ( origHwtime )
- {
- bufLenMultiplier = origHwtime / iCInfo.iHwFrameTime;
- if ( !bufLenMultiplier )
- {
- bufLenMultiplier = 1;
- }
- }
- }
- else if( iCInfo.iFourCC == KMccFourCCIdILBC )
- {
- iFrameSize = KILBCFrameSize;
- iFrameTime = 0;
- }
- else if( iCInfo.iFourCC == KMccFourCCIdG729 )
- {
- iFrameSize = KG729FrameSize;
- iFrameTime = 0;
- // Multiply G.729 also by two...
- bufLenMultiplier = 2;
- }
- else
- {
- __JITTER_BUFFER( "CMccJitterBufferImpl::SetupL KErrNotSupported" )
-
- User::Leave( KErrNotSupported );
- }
-
- // Save the bufLenMultiplier value, so we can use it later in comparison
- iBufLenMultiplier = bufLenMultiplier;
-
- // Delete old buffer & reset it
- const TInt elems = iBuffer.Count();
- for( TInt i = 0; i < elems; i++ )
- {
- delete iBuffer[i].iDataFrame;
- iBuffer[i].iDataFrame = NULL;
- }
-
- iBuffer.Reset();
-
- // Calculate needed elements
- TInt bufLen = iCInfo.iJitterBufBufferLength * bufLenMultiplier;
-
- __JITTER_BUFFER_INT1( "CMccJitterBufferImpl::SetupL G.711 bufLenMultiplier ",
- bufLenMultiplier )
- __JITTER_BUFFER_INT1( "CMccJitterBufferImpl::SetupL iBufferLength: ",
- bufLen )
-
- __ASSERT_ALWAYS( aPlayoutThreshold < bufLen, User::Leave( KErrTooBig ) );
-
- // if differences between bufferlength and treshold set by client
- // is less than 10, increase bufferlength so the differences is 10
- // this is to help buffer goes to overflow easily.
- // Also possible G.711/729 multiplier needs to be taken care of.
- CheckThresholdBufferLength( bufLen, aPlayoutThreshold );
- iCurrentPlayThreshold = aPlayoutThreshold * bufLenMultiplier;
- iOriginalPlayThreshold = aPlayoutThreshold * bufLenMultiplier;
-
- if( iCnGenerator )
- {
- delete iCnGenerator;
- iCnGenerator = NULL;
- }
+ // Save the original HW frame time because we may need it in case of
+ // dynamic G.711 adjustment.
+ const TUint8 origHwtime = iCInfo.iHwFrameTime;
+ iCInfo = aCInfo;
+ iEventHandler = aEventHandler;
+ iEndpointId = aEndpointId;
+
+ __JITTER_BUFFER_INT1( "CMccJitterBufferImpl::SetupL origHwtime:", origHwtime )
+
+ if( iCInfo.iJitterBufInactivityTimeOut )
+ {
+ if( ( iCInfo.iJitterBufPlayToneFrequency > 0 ) &&
+ ( iCInfo.iJitterBufPlayToneDuration > 0 ) )
+ {
+ iPlayToneInterval = iCInfo.iJitterBufPlayToneTimeout;
+ iPlay = ETrue;
+ }
+ }
+
+ TInt bufLenMultiplier = 1;
+ if ( iCInfo.iFourCC == KMMFFourCCCodeAMR )
+ {
+ iFrameSize = KAMRNBFrameSize;
+ iFrameTime = KAMRNBFrameTime;
+ }
+ else if ( iCInfo.iFourCC == KMMFFourCCCodeAWB )
+ {
+ iFrameSize = KAMRWBFrameSize;
+ iFrameTime = KAMRNBFrameTime;
+ iSampleRate = KWbSampleRateInkHz;
+ }
+ else if( iCInfo.iFourCC == KMccFourCCIdG711 )
+ {
+ // G.711 is configured dynamically. Take voip headerlength also in to
+ // account. G.711 hwframetime is in milliseconds, so need to multiply.
+ iFrameSize = ( iCInfo.iHwFrameTime * KDefaultSampleRateInkHz )
+ + KVoIPHeaderLength;
+ iFrameTime = 0;
+
+ // In case of G.711 codec dynamic configuration, we may need to double
+ // the jitterbuffer length if HW frame time is changed from 20ms to
+ // 10ms.
+ if ( origHwtime )
+ {
+ bufLenMultiplier = origHwtime / iCInfo.iHwFrameTime;
+ if ( !bufLenMultiplier )
+ {
+ bufLenMultiplier = 1;
+ }
+ }
+ }
+ else if( iCInfo.iFourCC == KMccFourCCIdILBC )
+ {
+ iFrameSize = KILBCFrameSize;
+ iFrameTime = 0;
+ }
+ else if( iCInfo.iFourCC == KMccFourCCIdG729 )
+ {
+ iFrameSize = KG729FrameSize;
+ iFrameTime = 0;
+ // Multiply G.729 also by two...
+ bufLenMultiplier = 2;
+ }
+ else
+ {
+ __JITTER_BUFFER( "CMccJitterBufferImpl::SetupL KErrNotSupported" )
+
+ User::Leave( KErrNotSupported );
+ }
+
+ // Delete old buffer & reset it
+ const TInt elems = iBuffer.Count();
+ for( TInt i = 0; i < elems; i++ )
+ {
+ delete iBuffer[i].iDataFrame;
+ iBuffer[i].iDataFrame = NULL;
+ }
+
+ iBuffer.Reset();
+
+ // Calculate needed elements
+ TInt bufLen = iCInfo.iJitterBufBufferLength * bufLenMultiplier;
+
+ __JITTER_BUFFER_INT1( "CMccJitterBufferImpl::SetupL G.711 bufLenMultiplier ",
+ bufLenMultiplier )
+ __JITTER_BUFFER_INT1( "CMccJitterBufferImpl::SetupL iBufferLength: ",
+ bufLen )
+
+ __ASSERT_ALWAYS( aPlayoutThreshold < bufLen, User::Leave( KErrTooBig ) );
+
+ // if differences between bufferlength and treshold set by client
+ // is less than 10, increase bufferlength so the differences is 10
+ // this is to help buffer goes to overflow easily.
+ // Also possible G.711/729 multiplier needs to be taken care of.
+ CheckThresholdBufferLength( bufLen, aPlayoutThreshold );
+ iCurrentPlayThreshold = aPlayoutThreshold * bufLenMultiplier;
+ iOriginalPlayThreshold = aPlayoutThreshold * bufLenMultiplier;
+
+ if( iCnGenerator )
+ {
+ delete iCnGenerator;
+ iCnGenerator = NULL;
+ }
- iCnGenerator = CMccCnGenerator::NewL( iCInfo.iFourCC, aDevSound );
-
- // Create the elements in the Buffer
- for( TInt k = 0; k < bufLen; k++ )
- {
- CMMFDataBuffer* buf = CMMFDataBuffer::NewL( iFrameSize );
- CleanupStack::PushL( buf );
- TJitterBufferElement newElement;
- newElement.iDataFrame = buf;
- newElement.iSequenceNumber = -1;
- newElement.iStamp = -1;
- iBuffer.AppendL( newElement );
- CleanupStack::Pop( buf );
- }
-
- // Zero the statistic members
- iFramesLost = 0;
- iFramesReceived = 0;
- iNumOfLateFrames = 0;
- iFramesRemoved = 0;
- iFramesPlayed = 0;
- iPacketsInBuffer = 0;
-
- // Calculate the sequence number increment
- iSeqNumIncrement = iSampleRate * iCInfo.iHwFrameTime;
- }
+ iCnGenerator = CMccCnGenerator::NewL( iCInfo.iFourCC, aDevSound );
+
+ // Create the elements in the Buffer
+ for( TInt k = 0; k < bufLen; k++ )
+ {
+ CMMFDataBuffer* buf = CMMFDataBuffer::NewL( iFrameSize );
+ CleanupStack::PushL( buf );
+ TJitterBufferElement newElement;
+ newElement.iDataFrame = buf;
+ newElement.iSequenceNumber = -1;
+ newElement.iStamp = -1;
+ iBuffer.AppendL( newElement );
+ CleanupStack::Pop( buf );
+ }
+
+ // Zero the statistic members
+ iFramesLost = 0;
+ iFramesReceived = 0;
+ iNumOfLateFrames = 0;
+ iFramesRemoved = 0;
+ iFramesPlayed = 0;
+ iPacketsInBuffer = 0;
+
+ // Calculate the sequence number increment
+ iSeqNumIncrement = iSampleRate * iCInfo.iHwFrameTime;
}
// -----------------------------------------------------------------------------
--- a/multimediacommscontroller/mmccjitterbuffer/tsrc/ut_jitterbuffer/src/UT_CMccJitterBufferImpl.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccjitterbuffer/tsrc/ut_jitterbuffer/src/UT_CMccJitterBufferImpl.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -246,57 +246,6 @@
iJBufImpl->SetupL( 5, cInfo, *devSoundDummy, this, 0 );
iJBufImpl->SetupL( 33, cInfo, *devSoundDummy, this, 0 );
EUNIT_ASSERT( iJBufImpl->iSampleRate == 16 );
-
-
- // Check that values are not changed:
-
- // Save original values:
- TMccCodecInfo originalCInfo( cInfo );
-
- // Set dummy values:
- cInfo.iPayloadFormatEncoder = 111;
- cInfo.iPayloadFormatDecoder = 222;
- cInfo.iBitrate = 333;
- cInfo.iSamplingFreq = 444;
- cInfo.iEnableDTX = ETrue;
- cInfo.iCodecMode = 555;
- cInfo.iAlgoUsed = 666;
- cInfo.iPtime = 777;
- cInfo.iMaxPtime = 888;
- cInfo.iPayloadType = 999;
- cInfo.iRedundantPayload = 1111;
- cInfo.iRedundancyCount = 2222;
- cInfo.iFrameSize = 3333;
- cInfo.iCNFrameSize = 4444;
- cInfo.iFmtpLength = 5555;
- cInfo.iJitterSize = 6666;
- cInfo.iNeighbor = ETrue;
- cInfo.iModeChangePeriod = 7777;
- cInfo.iJitterBufPlayToneTimeout = 8888;
- cInfo.iJitterBufPlayToneFrequency = 9999;
- cInfo.iJitterBufPlayToneDuration = 1;
- cInfo.iComfortNoiseGenerationPt = 2;
- cInfo.iBitrateMask = 3;
- cInfo.iAverageBitrate = 4;
- cInfo.iMaxBitrate = 5;
- cInfo.iFramerate = 6;
- cInfo.iVideoWidth = 7;
- cInfo.iVideoHeight = 8;
- cInfo.iMTUSize = 9;
- cInfo.iSessionID = 1;
- cInfo.iLinkID = 2;
- cInfo.iStreamID = 3;
- cInfo.iKeepaliveInterval = 1234;
- cInfo.iKeepalivePT = 2;
- cInfo.iIsUpdate = ETrue;
- cInfo.iMaxRed = 1000;
- cInfo.iSourceDefinedTimeStamps = ETrue;
-
- // Put the same parameter values than in previous function call,
- iJBufImpl->SetupL( 33, cInfo, *devSoundDummy, this, 0 );
- // and check that TMccCodecInfo values were not changed:
- TBool retval = originalCInfo.Compare( originalCInfo, iJBufImpl->iCInfo );
- EUNIT_ASSERT( retval );
}
void UT_CMccJitterBufferImpl::UT_CMccJitterBufferImpl_ResetBufferL()
--- a/multimediacommscontroller/mmccrtpsourcesink/inc/mccjittercalculator.h Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccrtpsourcesink/inc/mccjittercalculator.h Wed Oct 13 14:59:15 2010 +0300
@@ -44,7 +44,7 @@
class MRtpJitterObserver
{
public:
- virtual void SendJitterEvent( TMccRtpEventDataExtended aEvent, TInt aError ) = 0;
+ virtual void SendJitterEvent( TMccRtpEventData aEvent, TInt aError ) = 0;
};
@@ -91,7 +91,7 @@
* RTP header from received packet
* @return void
*/
- void RtpPacketReceived( const TUint32 aTimeStamp, TBool aMarker, TUint16 aSeqNum );
+ void RtpPacketReceived( const TUint32 aTimeStamp, TBool aMarker );
/**
* Set media configurations
@@ -134,44 +134,6 @@
*/
void JitterObserving();
- /**
- * Counts packet loss percentage from iStartingSeqNum, iCurrentSeqNum
- * and iReceivedPacketCounter
- * @return Counted packet loss percentage
- */
- TInt CountPacketLossPercentage();
-
- /**
- * Checks if current jitter level exceeds the jitter level given by the client,
- * and if exceeded, sends the report to client
- * @param "aReportIntervalReached"
- * Changed to ETrue if the report interval was reached
- * @param "aReportSent"
- * Changed to ETrue if the jitter report was sent
- * @return void
- */
- void CheckJitter( TBool& aReportIntervalReached, TBool& aReportSent );
-
- /**
- * Checks if current packet loss level exceeds the packet loss level
- * given by the client, and if exceeded, sends the report to client
- * @param "aReportIntervalReached"
- * Changed to ETrue if the report interval was reached
- * @param "aReportSent"
- * Changed to ETrue if the packet loss report was sent
- * @return void
- */
- void CheckPacketLoss( TBool& aReportIntervalReached, TBool& aReportSent );
-
- /**
- * Calculates a new FER value
- * @param aPrevValue Previous FER value
- * @param aAdd Value to add( ETrue/EFalse)
- * @param aFlag To add (ETrue) or remove (EFalse)
- * @return new FER value
- */
- TUint32 CalculateFer( TUint32 aPrevValue, TBool aAdd, TBool aFlag );
-
private:
// Number of packets received
@@ -229,21 +191,6 @@
*/
MRtpJitterObserver* iObserver;
- // Current packet sequence number
- TUint16 iCurrentSeqNum;
-
- // Packet sequence number where to start counting the packet loss
- TUint16 iStartingSeqNum;
-
- // Holds the previous number of packets expected
- TUint32 iPrevExpectedPackets;
-
- // Holds the previous number of packets received
- TUint32 iPrevPacketsReceived;
-
- // Holds the previous FER value
- TUint32 iPrevFerValue;
-
#ifdef FTD_ENABLED
// Message queue carrying stream statistics
--- a/multimediacommscontroller/mmccrtpsourcesink/inc/mccrtpdatasink.h Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccrtpsourcesink/inc/mccrtpdatasink.h Wed Oct 13 14:59:15 2010 +0300
@@ -85,6 +85,16 @@
}
/**
+ * Sets rtp media clock instance for data sink. Instance is forwarded
+ * to rtp keep alive sender.
+ *
+ * @since Series 60 3.0
+ * @param aRtpMediaClock media clock instance
+ * @return void
+ */
+ virtual void SetMediaClock( CMccRtpMediaClock& aRtpMediaClock );
+
+ /**
* Mutes/Unmutes RTP sink. When mute is enabled, only packets with
* exception payload type are sent.
*
--- a/multimediacommscontroller/mmccrtpsourcesink/inc/mccrtpdatasource.h Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccrtpsourcesink/inc/mccrtpdatasource.h Wed Oct 13 14:59:15 2010 +0300
@@ -301,7 +301,7 @@
* @since Series 60 3.2
* Send jitter event through mcc rtp interface
*/
- void SendJitterEvent( TMccRtpEventDataExtended aEvent, TInt aError );
+ void SendJitterEvent( TMccRtpEventData aEvent, TInt aError );
protected: // Functions from base classes
--- a/multimediacommscontroller/mmccrtpsourcesink/inc/mccrtpinterface.h Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccrtpsourcesink/inc/mccrtpinterface.h Wed Oct 13 14:59:15 2010 +0300
@@ -174,7 +174,7 @@
* @param aConfig Configuration
* @return void
*/
- virtual void ConfigureL( const TDesC8& aConfig, CMccRtpMediaClock* aRtpMediaClock );
+ virtual void ConfigureL( const TDesC8& aConfig );
/**
* Sends RTCP receiver report to uplink if possible.
@@ -264,8 +264,7 @@
iEventHandler( NULL ), iCodecInfo(), iMccStreamId( 0 ),
iMccEvent( TMccEvent() ), iRtpKeepalive( NULL ), iContext( NULL),
iSecSession( NULL ), iSrtpStream( NULL ), iRtpMediaClock( NULL ),
- iContextId( 0 ),
- iRtpKeepaliveUpdatePending( ETrue )
+ iContextId( 0 )
{ }
@@ -309,19 +308,6 @@
void CloseStreams();
- void SendJitterEventToClient( MAsyncEventHandler* aEventHandler,
- TUid aEventOriginator,
- TMccInternalEventType aInternalEventType,
- TMccEventType aEventType,
- TUint32 aEndpointId,
- TInt aError = KErrNone,
- TUint64 aJitterEstimate = 0,
- TUint32 aPacketsReceived = 0,
- TInt64 aPrevTransTime = 0,
- TUint64 aTriggeredJitterLevel = 0,
- TInt aPacketLoss = 0,
- TInt aTriggeredPacketLoss = 0 );
-
void SendInternalRtpEventToClient( MAsyncEventHandler* aEventHandler,
TUid aEventOriginator,
TMccInternalEventType aInternalEventType,
@@ -465,12 +451,7 @@
* Context identifier
*/
TUint32 iContextId;
-
- /*
- * Indicates need for setting media clock for keepalivetimer.
- */
- TBool iRtpKeepaliveUpdatePending;
-
+
private: // Friend classes
#ifdef TEST_EUNIT
--- a/multimediacommscontroller/mmccrtpsourcesink/src/mccjittercalculator.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccrtpsourcesink/src/mccjittercalculator.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -11,7 +11,7 @@
*
* Contributors:
*
-* Description: MccJitterCalculator calculates jitter level and compares given
+* Description: MccJitterCalculator calculates jitter level and compares given
* triggers.
*
*/
@@ -46,13 +46,6 @@
const TInt KNum4( 4 );
const TInt KNum8( 8 );
const TInt KNumZero( 0 );
-const TInt KNumHundred( 100 );
-
-const TUint32 KRtpFractationAccuracy = 5000;
-// Specified period of the moving average
-const TUint32 KDivider = 250;
-// Specified the max calculate count of package loss
-const TUint32 KMaxCalCount = 200;
// ============================ MEMBER FUNCTIONS ===============================
@@ -144,7 +137,7 @@
// -----------------------------------------------------------------------------
//
void CMccJitterCalculator::RtpPacketReceived( const TUint32 aTimeStamp,
- TBool aMarker, TUint16 aSeqNum )
+ TBool aMarker )
{
#ifdef TRACE_JITCALC
RDebug::Print( _L("CMccJitterCalculator::RtpPacketReceived IN") );
@@ -154,33 +147,6 @@
VoipTrace("%x %x %d %d %d", MCC_TRACE, MCC_RECEIVED_RTP_PACKET_INFO,
aHeaderInfo.iSeqNum, aHeaderInfo.iTimestamp, iPacketsReceived );
#endif
-
- TBool calculatePkgLoss = ETrue;
- if ( EMccQualityPacketBased == iReportIntervalType || iFrameLossObsOn )
- {
- // Save current packet sequence number
- // The SeqNum come from RTP package. It maybe start from a random number between
- // 0 to 65535. iStartingSeqNum should be reset
- // while iCurrentSeqNum was reset (by remote packages)
- iCurrentSeqNum = aSeqNum;
- if( iStartingSeqNum == KNumZero ||
- iStartingSeqNum > iCurrentSeqNum )
- {
- iStartingSeqNum = aSeqNum;
- if ( iStartingSeqNum > 0 )
- {
- iStartingSeqNum--;
- }
- else
- {
- #ifdef TRACE_JITCALC
- RDebug::Print( _L("Received SeqNum is 0, don't calculate lost package") );
- #endif
- calculatePkgLoss = EFalse;
- }
- }
- iReceivedPacketCounter++;
- }
// Jitter calculating based on RFC3550 Appendix A.8, see www.ietf.org
if ( aMarker || !iPacketsReceived )
@@ -252,20 +218,15 @@
RDebug::Print( _L("CMccJitterCalculator::RtpPacketReceived SENDING RCV: %d"), iPacketsReceived );
#endif
- TMccRtpEventDataExtended event( ( iCurJitter >> KNum4 ),
+ TMccRtpEventData event( ( iCurJitter >> KNum4 ),
iPacketsReceived,
iPrevPacketTransit,
- KNumZero,
- KNumZero,
KNumZero );
iObserver->SendJitterEvent( event, KErrNone );
}
- if ( calculatePkgLoss )
- {
- JitterObserving();
- }
+ JitterObserving();
}
// ---------------------------------------------------------------------------
@@ -341,7 +302,6 @@
iJitterObsOn = EFalse;
iFrameLossObsOn = EFalse;
iMediaQualityObservingStarted = EFalse;
- iStartingSeqNum = KNumZero;
}
// ---------------------------------------------------------------------------
@@ -396,9 +356,6 @@
iPacketsReceived = KNumZero;
iCurJitter = KNumZero;
iPrevPacketTransit = KNumZero;
- iCurrentSeqNum = KNumZero;
- iStartingSeqNum = KNumZero;
- iReceivedPacketCounter = KNumZero;
}
// -----------------------------------------------------------------------------
@@ -409,13 +366,6 @@
//
void CMccJitterCalculator::JitterObserving()
{
- #ifdef TRACE_JITCALC
- RDebug::Print( _L("CMccJitterCalculator::JitterObserving IN") );
- #endif
-
- TBool resetValuesForNextReport = EFalse;
- TBool cancelObs = EFalse;
-
if ( iJitterObsOn )
{
#ifdef TRACE_JITCALC
@@ -424,32 +374,98 @@
iJitterLevelFromClient, ( iCurJitter / KConversionFactor ) );
#endif
- CheckJitter( resetValuesForNextReport, cancelObs );
- }
-
- if ( iFrameLossObsOn )
- {
- #ifdef TRACE_JITCALC
- RDebug::Print( _L("CMccJitterCalculator::JitterObserving Frame Loss observing ON") );
- #endif
-
- CheckPacketLoss( resetValuesForNextReport, cancelObs );
+ // Normalize iCurJitter
+ TUint64 modJitter = iCurJitter >> KNum4;
+
+ if ( EMccQualityTimeBased == iReportIntervalType )
+ {
+ // change microsecs to millisecs
+ TTimeIntervalMicroSeconds getTime =
+ iCurTime.MicroSecondsFrom( iHomeTime );
+
+ #ifdef TRACE_JITCALC
+ RDebug::Print( _L("CMccJitterCalculator::JitterObserving getTime = %Ld"), getTime.Int64() );
+ #endif
+
+ if ( static_cast<TInt64>( iReportInterval ) <=
+ ( getTime.Int64() / KConversionFactor ) )
+ {
+ // compare clients jitter level to current level
+ if ( static_cast<TUint64>( iJitterLevelFromClient ) <
+ modJitter )
+ {
+ #ifdef TRACE_JITCALC
+ RDebug::Print ( _L("CMccJitterCalculator::JitterObserving jitterlevel %u ms compared to jitter estimate %Lu ms"),
+ iJitterLevelFromClient, modJitter );
+ #endif
+
+ TMccRtpEventData event( ( iCurJitter >> KNum4 ),
+ iPacketsReceived,
+ iPrevPacketTransit,
+ modJitter );
+
+ // Informs client via event and cancels jitter observing
+ iObserver->SendJitterEvent( event, KErrNone );
+ CancelObserving();
+ }
+
+ // Initialize hometime again
+ iHomeTime.HomeTime();
+
+ #ifdef TRACE_JITCALC
+ RDebug::Print ( _L("CMccJitterCalculator::JitterObserving Initialize iHomeTime = %Ld"), iHomeTime.Int64() );
+ #endif
+
+ }
+ }
+ else if ( EMccQualityPacketBased == iReportIntervalType )
+ {
+ iReceivedPacketCounter++;
+
+ #ifdef TRACE_JITCALC
+ RDebug::Print( _L("CMccJitterCalculator::JitterObserving iReceivedPacketCounter: %u"), iReceivedPacketCounter );
+ #endif
+
+ if ( iReportInterval == iReceivedPacketCounter )
+ {
+ // compare clients jitter level to current level
+ if ( iJitterLevelFromClient < modJitter )
+ {
+ #ifdef TRACE_JITCALC
+ RDebug::Print( _L("CMccJitterCalculator::JitterObserving jitterlevel %u ms compared to jitter estimate %Lu ms"),
+ iJitterLevelFromClient, modJitter );
+ #endif
+
+ TMccRtpEventData event( ( iCurJitter >> KNum4 ),
+ iPacketsReceived,
+ iPrevPacketTransit,
+ modJitter );
+
+ // Informs client via event and cancels jitter observing
+ iObserver->SendJitterEvent( event, KErrNone );
+ CancelObserving();
+ }
+
+ iReceivedPacketCounter = KNumZero;
+ }
+ }
+ else
+ {
+ #ifdef TRACE_JITCALC
+ RDebug::Print( _L("CMccJitterCalculator::JitterObserving Report type is not valid!") );
+ #endif
+
+ TMccRtpEventData event( ( iCurJitter >> KNum4 ),
+ iPacketsReceived,
+ iPrevPacketTransit,
+ KNumZero );
+
+ iObserver->SendJitterEvent( event, KErrArgument );
+ CancelObserving();
+ }
}
-
- if( resetValuesForNextReport )
- {
- // Initialize hometime again
- iHomeTime.HomeTime();
- #ifdef TRACE_JITCALC
- RDebug::Print ( _L("CMccJitterCalculator::JitterObserving Initialize iHomeTime = %Ld"), iHomeTime.Int64() );
- #endif
- }
- if( cancelObs )
- {
- CancelObserving();
- }
}
-
+
// ---------------------------------------------------------------------------
// CMccJitterCalculator::IsObserving
// To check if observing is ON
@@ -460,288 +476,4 @@
return iMediaQualityObservingStarted;
}
-// -----------------------------------------------------------------------------
-// CMccJitterCalculator::CountPacketLossPercentage
-// Counts packet loss percentage from iStartingSeqNum, iCurrentSeqNum
-// and iReceivedPacketCounter
-// private method
-// -----------------------------------------------------------------------------
-//
-TInt CMccJitterCalculator::CountPacketLossPercentage()
- {
- TUint32 numberOfPacketsExpected( 0 );
- numberOfPacketsExpected = iCurrentSeqNum - iStartingSeqNum;
-
- if ( ( iPrevExpectedPackets - iPrevPacketsReceived ) ==
- ( numberOfPacketsExpected - iReceivedPacketCounter ) )
- {
- // no packet lost - inorder
- iPrevFerValue = CalculateFer( iPrevFerValue, EFalse, ETrue );
- }
- else if ( ( iPrevPacketsReceived < iReceivedPacketCounter ) &&
- ( iPrevExpectedPackets == numberOfPacketsExpected ) )
- {
- // no packet lost - late packet - remove FER
- iPrevFerValue = CalculateFer( iPrevFerValue, ETrue, EFalse );
- }
- else if ( numberOfPacketsExpected > iPrevExpectedPackets )
- {
-
- // packet lost - add FER by number of packets lost.
- // expected = 5, prev_expected 3 => diff 2 but loss is ONE thats why - 1
- TUint32 maxCalcount =
- numberOfPacketsExpected - iPrevExpectedPackets - 1 < KMaxCalCount ?
- numberOfPacketsExpected - iPrevExpectedPackets - 1 : KMaxCalCount;
- for ( TUint32 i = 0; i < maxCalcount; i++ )
- {
- iPrevFerValue = CalculateFer( iPrevFerValue, ETrue, ETrue );
- }
- }
-
- iPrevExpectedPackets = numberOfPacketsExpected;
- iPrevPacketsReceived = iReceivedPacketCounter;
-
- TInt percentage( iPrevFerValue / KRtpFractationAccuracy );
- return percentage;
- }
-
-// -----------------------------------------------------------------------------
-// CMccJitterCalculator::CheckJitter
-// Checks if current jitter level exceeds the jitter level given by the client,
-// and if exceeded, sends the report to client
-// private method
-// -----------------------------------------------------------------------------
-//
-void CMccJitterCalculator::CheckJitter( TBool& aReportIntervalReached,
- TBool& aReportSent )
- {
- #ifdef TRACE_JITCALC
- RDebug::Print( _L("CMccJitterCalculator::CheckJitter IN") );
- #endif
-
- // Normalize iCurJitter
- TUint64 modJitter = iCurJitter >> KNum4;
-
- if ( EMccQualityTimeBased == iReportIntervalType )
- {
- // change microsecs to millisecs
- TTimeIntervalMicroSeconds getTime =
- iCurTime.MicroSecondsFrom( iHomeTime );
-
- #ifdef TRACE_JITCALC
- RDebug::Print( _L("CMccJitterCalculator::CheckJitter getTime = %Ld"), getTime.Int64() );
- #endif
-
- if ( static_cast<TInt64>( iReportInterval ) <=
- ( getTime.Int64() / KConversionFactor ) )
- {
- // compare clients jitter level to current level
- if ( static_cast<TUint64>( iJitterLevelFromClient ) <
- modJitter )
- {
- #ifdef TRACE_JITCALC
- RDebug::Print ( _L("CMccJitterCalculator::CheckJitter jitterlevel %u ms compared to jitter estimate %Lu ms"),
- iJitterLevelFromClient, modJitter );
- #endif
-
- TMccRtpEventDataExtended event( ( iCurJitter >> KNum4 ),
- iPacketsReceived,
- iPrevPacketTransit,
- modJitter,
- KNumZero,
- KNumZero );
-
- // Informs client via event and cancels jitter observing
- iObserver->SendJitterEvent( event, KErrNone );
- aReportSent = ETrue;
- }
- aReportIntervalReached = ETrue;
- }
- }
- else if ( EMccQualityPacketBased == iReportIntervalType )
- {
- #ifdef TRACE_JITCALC
- RDebug::Print( _L("CMccJitterCalculator::CheckJitter iReceivedPacketCounter: %u"), iReceivedPacketCounter );
- #endif
-
- if ( iReportInterval == iReceivedPacketCounter )
- {
- // compare clients jitter level to current level
- if ( iJitterLevelFromClient < modJitter )
- {
- #ifdef TRACE_JITCALC
- RDebug::Print( _L("CMccJitterCalculator::CheckJitter jitterlevel %u ms compared to jitter estimate %Lu ms"),
- iJitterLevelFromClient, modJitter );
- #endif
-
- TMccRtpEventDataExtended event( ( iCurJitter >> KNum4 ),
- iPacketsReceived,
- iPrevPacketTransit,
- modJitter,
- KNumZero,
- KNumZero );
-
- // Informs client via event and cancels jitter observing
- iObserver->SendJitterEvent( event, KErrNone );
- aReportSent = ETrue;
- }
- aReportIntervalReached = ETrue;
- }
- }
- else
- {
- #ifdef TRACE_JITCALC
- RDebug::Print( _L("CMccJitterCalculator::CheckJitter Report type is not valid!") );
- #endif
-
- TMccRtpEventDataExtended event( ( iCurJitter >> KNum4 ),
- iPacketsReceived,
- iPrevPacketTransit,
- KNumZero,
- KNumZero,
- KNumZero );
-
- iObserver->SendJitterEvent( event, KErrArgument );
- aReportSent = ETrue;
- }
-
- }
-
-// -----------------------------------------------------------------------------
-// CMccJitterCalculator::CheckPacketLoss
-// Checks if current packet loss level exceeds the packet loss level
-// given by the client, and if exceeded, sends the report to client
-// private method
-// -----------------------------------------------------------------------------
-//
-void CMccJitterCalculator::CheckPacketLoss( TBool& aReportIntervalReached,
- TBool& aReportSent )
- {
- #ifdef TRACE_JITCALC
- RDebug::Print( _L("CMccJitterCalculator::CheckPacketLoss IN") );
- #endif
-
- TInt packetLossPercentage = CountPacketLossPercentage();
-
- if ( EMccQualityTimeBased == iReportIntervalType )
- {
- // change microsecs to millisecs
- TTimeIntervalMicroSeconds getTime =
- iCurTime.MicroSecondsFrom( iHomeTime );
-
- #ifdef TRACE_JITCALC
- RDebug::Print( _L("CMccJitterCalculator::CheckPacketLoss getTime = %Ld"), getTime.Int64() );
- #endif
-
- if ( static_cast<TInt64>( iReportInterval ) <=
- ( getTime.Int64() / KConversionFactor ) )
- {
- // If the packet loss percentage was exceeded
- if( iPacketLossFromClient < packetLossPercentage )
- {
- #ifdef TRACE_JITCALC
- RDebug::Print( _L("CMccJitterCalculator::CheckPacketLoss Packet Loss From Client %u compared to Current Packet Loss %u "),
- iPacketLossFromClient, packetLossPercentage );
- #endif
-
- TMccRtpEventDataExtended event( ( iCurJitter >> KNum4 ),
- iPacketsReceived,
- iPrevPacketTransit,
- KNumZero,
- packetLossPercentage,
- packetLossPercentage );
-
- // Informs client via event and cancels jitter observing
- iObserver->SendJitterEvent( event, KErrNone );
- aReportSent = ETrue;
- }
- aReportIntervalReached = ETrue;
- }
- }
- else if ( EMccQualityPacketBased == iReportIntervalType )
- {
-
- #ifdef TRACE_JITCALC
- RDebug::Print( _L("CMccJitterCalculator::CheckPacketLoss EMccQualityPacketBased == iReportIntervalType") );
- RDebug::Print( _L("CMccJitterCalculator::CheckPacketLoss iReceivedPacketCounter: %u"), iReceivedPacketCounter );
- #endif
-
- if ( iReportInterval == iReceivedPacketCounter )
- {
- // If the packet loss percentage was exceeded
- if( iPacketLossFromClient < packetLossPercentage )
- {
- #ifdef TRACE_JITCALC
- RDebug::Print( _L("CMccJitterCalculator::CheckPacketLoss Packet Loss From Client %u compared to Current Packet Loss %u "),
- iPacketLossFromClient, packetLossPercentage );
- #endif
-
- TMccRtpEventDataExtended event( ( iCurJitter >> KNum4 ),
- iPacketsReceived,
- iPrevPacketTransit,
- KNumZero,
- packetLossPercentage,
- packetLossPercentage );
-
- // Informs client via event and cancels jitter observing
- iObserver->SendJitterEvent( event, KErrNone );
- aReportSent = ETrue;
- }
- aReportIntervalReached = ETrue;
- }
- }
- else
- {
- #ifdef TRACE_JITCALC
- RDebug::Print( _L("CMccJitterCalculator::CheckPacketLoss Report type is not valid!") );
- #endif
-
- TMccRtpEventDataExtended event( ( iCurJitter >> KNum4 ),
- iPacketsReceived,
- iPrevPacketTransit,
- KNumZero,
- KNumZero,
- KNumZero );
-
- iObserver->SendJitterEvent( event, KErrArgument );
- aReportSent = ETrue;
- }
- }
-
-// -----------------------------------------------------------------------------
-// CMccJitterCalculator::CalculateFer
-// Calculates a new FER value
-// -----------------------------------------------------------------------------
-//
-TUint32 CMccJitterCalculator::CalculateFer( TUint32 aPrevValue,
- TBool aAdd, TBool aFlag )
- {
- TUint32 ret = 0;
- TInt64 temp_add = 0;
-
- temp_add = aAdd * KNumHundred * KRtpFractationAccuracy;
-
- TInt64 diff = temp_add - (TInt64)aPrevValue;
- TInt32 tempValue = static_cast<TInt32>( diff / KDivider );
-
- if ( aFlag )
- {
- ret = TUint32( aPrevValue + tempValue );
- }
- else
- {
- if ( aPrevValue > tempValue )
- {
- ret = TUint32( aPrevValue - tempValue );
- }
- else
- {
- // removed FER would have gone over thus zero
- ret = 0;
- }
- }
-
- return ret;
- }
-
// End of File
--- a/multimediacommscontroller/mmccrtpsourcesink/src/mccrtpdatasink.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccrtpsourcesink/src/mccrtpdatasink.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -778,6 +778,24 @@
}
// ---------------------------------------------------------------------------
+// CMccRtpDataSink::SetMediaClock
+// ---------------------------------------------------------------------------
+//
+void CMccRtpDataSink::SetMediaClock( CMccRtpMediaClock& aRtpMediaClock )
+ {
+ TRACE_RTP_SINK_PRINT( "CMccRtpDataSink::SetMediaClock" )
+
+ if ( !iRtpMediaClock )
+ {
+ iRtpMediaClock = &aRtpMediaClock;
+ }
+ else
+ {
+ TRACE_RTP_SINK_PRINT( "CMccRtpDataSink::SetMediaClock - Allready set!" )
+ }
+ }
+
+// ---------------------------------------------------------------------------
// FROM SRTP API
// This function is called by SRTP Stream initiated with
// MSRTPReKeyingObserver when a master key is stale and needs
--- a/multimediacommscontroller/mmccrtpsourcesink/src/mccrtpdatasource.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccrtpsourcesink/src/mccrtpdatasource.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -19,7 +19,7 @@
// INCLUDE FILES
-#include <in_sock.h>
+#include <in_sock.h>
#include <mmf/common/mmfcontroller.h>
#include "rtpapi.h"
@@ -254,8 +254,7 @@
if ( iJitCalc->IsObserving() )
{
iJitCalc->RtpPacketReceived( aHeaderInfo.iTimestamp,
- aHeaderInfo.iMarker,
- aHeaderInfo.iSeqNum );
+ aHeaderInfo.iMarker );
}
// First packet after SourcePlayL, notify event handler by sending
@@ -852,22 +851,20 @@
// CMccRtpDataSource::SendJitterEvent()
// -----------------------------------------------------------------------------
//
-void CMccRtpDataSource::SendJitterEvent( TMccRtpEventDataExtended aEvent, TInt aError )
+void CMccRtpDataSource::SendJitterEvent( TMccRtpEventData aEvent, TInt aError )
{
TRACE_RTP_SOURCE_PRINT( "CMccRtpDataSource::SendJitterEvent" )
-
- SendJitterEventToClient( iEventHandler,
- KMccRtpSourceUid,
- EMccInternalJitterEventStatusReport,
- KMccMediaQualityStatus,
- MCC_RTPSOURCE_ENDPOINT_ID,
- aError,
- aEvent.iJitterEstimate,
- aEvent.iPacketsReceived,
- aEvent.iPrevTransTime,
- aEvent.iTriggeredJitterLevel,
- aEvent.iPacketLoss,
- aEvent.iTriggeredPacketLoss );
+
+ SendInternalRtpEventToClient( iEventHandler,
+ KMccRtpSourceUid,
+ EMccInternalJitterEventStatusReport,
+ KMccMediaQualityStatus,
+ MCC_RTPSOURCE_ENDPOINT_ID,
+ aError,
+ aEvent.iJitterEstimate,
+ aEvent.iPacketsReceived,
+ aEvent.iPrevTransTime,
+ aEvent.iTriggeredJitterLevel );
}
// -----------------------------------------------------------------------------
--- a/multimediacommscontroller/mmccrtpsourcesink/src/mccrtpinterface.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccrtpsourcesink/src/mccrtpinterface.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -204,17 +204,11 @@
// Configures the RTP source/sink
// -----------------------------------------------------------------------------
//
-void MMccRtpInterface::ConfigureL( const TDesC8& aConfig,
- CMccRtpMediaClock* aRtpMediaClock )
+void MMccRtpInterface::ConfigureL( const TDesC8& aConfig )
{
TRACE_RTP_INTERFACE_PRINT( "MMccRtpInterface::ConfigureL, Entry" )
__ASSERT_ALWAYS( NULL != iRtpKeepalive, User::Leave( KErrNotReady ) );
- if ( !iRtpMediaClock )
- {
- iRtpMediaClock = aRtpMediaClock;
- }
-
if ( aConfig.Size() == sizeof( TMccCodecInfo ) )
{
TMccCodecInfoBuffer infoBuffer;
@@ -234,28 +228,17 @@
( iCodecInfo.iKeepalivePT != codecInfo.iKeepalivePT ||
iCodecInfo.iKeepaliveInterval != codecInfo.iKeepaliveInterval ||
iCodecInfo.iKeepaliveData != codecInfo.iKeepaliveData ) &&
- 0 != codecInfo.iKeepaliveInterval ||
- iRtpKeepaliveUpdatePending;
+ 0 != codecInfo.iKeepaliveInterval;
if ( updateNeeded )
{
- if ( iRtpMediaClock )
- {
- TRACE_RTP_INTERFACE_PRINT(
- "MMccRtpInterface::ConfigureL - Update" )
-
- iCodecInfo.iKeepalivePT = codecInfo.iKeepalivePT;
- iCodecInfo.iKeepaliveInterval = codecInfo.iKeepaliveInterval;
- iCodecInfo.iKeepaliveData = codecInfo.iKeepaliveData;
- __ASSERT_ALWAYS( NULL != iRtpMediaClock, User::Leave( KErrNotReady ) );
- iRtpKeepalive->UpdateParamsL( *this, codecInfo, *iRtpMediaClock );
-
- iRtpKeepaliveUpdatePending = EFalse;
- }
- else
- {
- iRtpKeepaliveUpdatePending = ETrue;
- }
+ TRACE_RTP_INTERFACE_PRINT(
+ "MMccRtpInterface::ConfigureL - Update" )
+
+ iCodecInfo.iKeepalivePT = codecInfo.iKeepalivePT;
+ iCodecInfo.iKeepaliveInterval = codecInfo.iKeepaliveInterval;
+ iCodecInfo.iKeepaliveData = codecInfo.iKeepaliveData;
+ iRtpKeepalive->UpdateParamsL( *this, codecInfo );
}
}
}
@@ -380,62 +363,6 @@
}
// -----------------------------------------------------------------------------
-// MMccRtpInterface::SendJitterEventToClient
-// -----------------------------------------------------------------------------
-//
-void MMccRtpInterface::SendJitterEventToClient( MAsyncEventHandler* aEventHandler,
- TUid aEventOriginator,
- TMccInternalEventType aInternalEventType,
- TMccEventType aEventType,
- TUint32 aEndpointId,
- TInt aError,
- TUint64 aJitterEstimate,
- TUint32 aPacketsReceived,
- TInt64 aPrevTransTime,
- TUint64 aTriggeredJitterLevel,
- TInt aPacketLoss,
- TInt aTriggeredPacketLoss )
- {
-
- TRACE_RTP_SOURCE_PRINT( "MMccRtpInterface::SendJitterEventToClient" )
-
- if ( aEventHandler )
- {
- ClearMccEvent();
-
- iMccEvent.iEventCategory = KMccEventCategoryRtp;
- iMccEvent.iStreamId = iMccStreamId;
- iMccEvent.iEndpointId = aEndpointId;
- iMccEvent.iEventType = aEventType;
- iMccEvent.iErrorCode = aError;
-
- // Save some stack memory
- {
- TMccRtpEventDataExtended eventData;
- eventData.iJitterEstimate = aJitterEstimate;
- eventData.iPacketsReceived = aPacketsReceived;
- eventData.iPrevTransTime = aPrevTransTime;
- eventData.iTriggeredJitterLevel = aTriggeredJitterLevel;
- eventData.iPacketLoss = aPacketLoss;
- eventData.iTriggeredPacketLoss = aTriggeredPacketLoss;
-
- iMccEvent.iEventData.Copy( TMccRtpEventDataExtendedPackage( eventData ) );
- }
-
- TMccInternalEvent internalEvent( aEventOriginator,
- aInternalEventType,
- iMccEvent );
-
- aEventHandler->SendEventToClient( internalEvent );
- }
- else
- {
- TRACE_RTP_INTERFACE_PRINT("MMccRtpInterface::SendInternalRtpEventToClient, \
-aEventHandler=NULL")
- }
- }
-
-// -----------------------------------------------------------------------------
// MMccRtpInterface::SendInternalRtpEventToClient
// -----------------------------------------------------------------------------
//
--- a/multimediacommscontroller/mmccrtpsourcesink/tsrc/ut_rtpsourcesink/group/UT_MccRtpSourceSink.mmp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccrtpsourcesink/tsrc/ut_rtpsourcesink/group/UT_MccRtpSourceSink.mmp Wed Oct 13 14:59:15 2010 +0300
@@ -53,9 +53,6 @@
SOURCE mmcccryptocontext.cpp
SOURCE mcctimermanager.cpp
-SOURCEPATH ../../../../mmccsubcontroller/src
-SOURCE mccrtpmediaclock.cpp
-
SOURCEPATH ../../../../tsrc/amrpayloadformatstub/src
SOURCE AmrPayloadFormatRead_STUB.cpp
SOURCE AmrPayloadFormatWrite_STUB.cpp
--- a/multimediacommscontroller/mmccrtpsourcesink/tsrc/ut_rtpsourcesink/inc/UT_CMccJitterCalculator.h Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccrtpsourcesink/tsrc/ut_rtpsourcesink/inc/UT_CMccJitterCalculator.h Wed Oct 13 14:59:15 2010 +0300
@@ -58,7 +58,7 @@
public: // From observer interface
- void SendJitterEvent( TMccRtpEventDataExtended aEvent, TInt aError );
+ void SendJitterEvent( TMccRtpEventData aEvent, TInt aError );
public: // Helpers
@@ -73,18 +73,12 @@
void UT_CMccJitterCalculator_JitterObservingL();
void UT_CMccJitterCalculator_RtpPacketReceivedL();
-
- void UT_CMccJitterCalculator_CalculateFerL();
-
- void UT_CMccJitterCalculator_CountPacketLossPercentageL();
-
- void UT_CMccJitterCalculator_ResetCountersL();
private: // Data
CMccJitterCalculator* iCalculator;
- TMccRtpEventDataExtended iLastEvent;
+ TMccRtpEventData iLastEvent;
TInt iLastError;
EUNIT_DECLARE_TEST_TABLE;
--- a/multimediacommscontroller/mmccrtpsourcesink/tsrc/ut_rtpsourcesink/inc/UT_CMccRtpDataSink.h Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccrtpsourcesink/tsrc/ut_rtpsourcesink/inc/UT_CMccRtpDataSink.h Wed Oct 13 14:59:15 2010 +0300
@@ -34,7 +34,6 @@
class CMccRtpDataSink;
class CMccRtpKeepaliveContainer;
class TMccInternalEvent;
-class CMccRtpMediaClock;
// CLASS DEFINITION
/**
*
@@ -204,7 +203,6 @@
CMccRtpKeepaliveContainer* iRtpKeepaliveMechanism;
CSRTPSession* iSecSession;
TUint iEventType;
- CMccRtpMediaClock* iRtpMediaClock;
};
--- a/multimediacommscontroller/mmccrtpsourcesink/tsrc/ut_rtpsourcesink/inc/UT_CMccRtpDataSource.h Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccrtpsourcesink/tsrc/ut_rtpsourcesink/inc/UT_CMccRtpDataSource.h Wed Oct 13 14:59:15 2010 +0300
@@ -36,7 +36,6 @@
class CMccRtpDataSource;
class CMccRtpKeepaliveContainer;
class CMccTestEventHandler;
-class CMccRtpMediaClock;
// CLASS DEFINITION
/**
@@ -187,7 +186,7 @@
CMccRtpKeepaliveContainer* iRtpKeepaliveMechanism;
CMccTestEventHandler* iEventHandler;
CSRTPSession* iSecSession;
- CMccRtpMediaClock* iRtpMediaClock;
+
};
--- a/multimediacommscontroller/mmccrtpsourcesink/tsrc/ut_rtpsourcesink/inc/UT_CMccRtpInterface.h Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccrtpsourcesink/tsrc/ut_rtpsourcesink/inc/UT_CMccRtpInterface.h Wed Oct 13 14:59:15 2010 +0300
@@ -34,7 +34,6 @@
class CRtpAPI;
class MMccRtpInterface;
class CMccRtpKeepaliveContainer;
-class CMccRtpMediaClock;
// CLASS DEFINITION
/**
@@ -98,7 +97,6 @@
CRtpAPI* iRtpApi;
MMccRtpInterface* iInterface;
CMccRtpKeepaliveContainer* iRtpKeepaliveMechanism;
- CMccRtpMediaClock* iRtpMediaClock;
};
#endif // __UT_CMccRTPINTERFACE_H__
--- a/multimediacommscontroller/mmccrtpsourcesink/tsrc/ut_rtpsourcesink/src/UT_CMccJitterCalculator.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccrtpsourcesink/tsrc/ut_rtpsourcesink/src/UT_CMccJitterCalculator.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -66,7 +66,7 @@
}
// Observer impl
-void UT_CMccJitterCalculator::SendJitterEvent( TMccRtpEventDataExtended aEvent, TInt aError )
+void UT_CMccJitterCalculator::SendJitterEvent( TMccRtpEventData aEvent, TInt aError )
{
iLastEvent = aEvent;
iLastError = aError;
@@ -126,15 +126,10 @@
// Not active
iCalculator->JitterObserving();
- iCalculator->iStartingSeqNum = 80;
- iCalculator->iCurrentSeqNum = 100;
- iCalculator->iReceivedPacketCounter = 20; // 100-80=20, no packets lost
-
iCalculator->iPacketsReceived = 5;
iCalculator->iJitterLevelFromClient = 10000;
iCalculator->iCurJitter = 10000;
iCalculator->iJitterObsOn = ETrue;
- iCalculator->iFrameLossObsOn = ETrue;
// Time based reporting
//
@@ -145,264 +140,66 @@
iCalculator->iReportInterval = 100000;
iCalculator->JitterObserving();
EUNIT_ASSERT_EQUALS( iLastEvent.iPacketsReceived, 0 );
- EUNIT_ASSERT_EQUALS( iLastEvent.iPacketLoss, 0 );
// Enough time elapsed but not over jitter level defined by client
iCalculator->iReportInterval = 0;
iCalculator->JitterObserving();
EUNIT_ASSERT_EQUALS( iLastEvent.iPacketsReceived, 0 );
- EUNIT_ASSERT_EQUALS( iLastEvent.iPacketLoss, 0 );
- // Jitter and packet loss level defined by client exceeded
- iCalculator->iStartingSeqNum = 100;
- iCalculator->iCurrentSeqNum = 125;
- iCalculator->iPrevFerValue = 93000; // 9%
-
- iCalculator->iPrevExpectedPackets = 20;
- iCalculator->iReceivedPacketCounter = 20; // 5 packets is lost.
-
+ // Jitter level defined by client exceeded
iCalculator->iJitterLevelFromClient = 10;
- User::After( 5000 );
iCalculator->JitterObserving();
EUNIT_ASSERT_EQUALS( iLastEvent.iPacketsReceived, 5 ); // just making sure that callback was called
- EUNIT_ASSERT_EQUALS( iLastEvent.iPacketLoss, 19 );
// Quality based reporting
//
- EUNIT_ASSERT_EQUALS( iCalculator->iReceivedPacketCounter, 20 ); // counter is not zeroed
-
iCalculator->iReportIntervalType = EMccQualityPacketBased;
- iCalculator->iJitterObsOn = ETrue;
- iCalculator->iFrameLossObsOn = ETrue;
iLastEvent.iPacketsReceived = 0;
- iLastEvent.iPacketLoss = 0;
iCalculator->iReportInterval = 2;
- iCalculator->iPacketsReceived = 2;
-
- iCalculator->iStartingSeqNum = 120;
- iCalculator->iCurrentSeqNum = 121;
- iCalculator->iReceivedPacketCounter = 1;
- iCalculator->iCurJitter = 10000;
- iCalculator->iJitterLevelFromClient = 10000;
-
- iCalculator->JitterObserving();
- //Check that nothing was changed in iLastEvent:
- EUNIT_ASSERT_EQUALS( iLastEvent.iPacketsReceived, 0 );
- EUNIT_ASSERT_EQUALS( iLastEvent.iPacketLoss, 0 );
+ iCalculator->iJitterObsOn = ETrue;
- // One packet more...
- iCalculator->iPrevFerValue = 0; // 0%
- iCalculator->iCurrentSeqNum++;
- iCalculator->iReceivedPacketCounter++;
+ // Not the packet when calculation is done
+ iCalculator->iReceivedPacketCounter = 0;
iCalculator->JitterObserving();
- //Check that nothing was changed in iLastEvent:
- EUNIT_ASSERT_EQUALS( iLastEvent.iPacketsReceived, 0 );
- EUNIT_ASSERT_EQUALS( iLastEvent.iPacketLoss, 0 );
+ EUNIT_ASSERT_EQUALS( iCalculator->iReceivedPacketCounter, 1 );
- //Do the packet loss, with reporting:
- iCalculator->iStartingSeqNum = 122;
- iCalculator->iCurrentSeqNum = 126;
- iCalculator->iPrevFerValue = 98000; // 9%
- iCalculator->iPrevExpectedPackets = 1;
-
- iCalculator->iReceivedPacketCounter = 2;
- iCalculator->iCurJitter = 10000;
- iCalculator->iJitterLevelFromClient = 10;
+ // Now the interval is reached
iCalculator->JitterObserving();
- //Check that values were changed in iLastEvent:
- EUNIT_ASSERT_EQUALS( iLastEvent.iPacketsReceived, 2 );
- EUNIT_ASSERT_EQUALS( iLastEvent.iPacketLoss, 20 );
+ EUNIT_ASSERT_EQUALS( iLastEvent.iPacketsReceived, 5 ); // just making sure that callback was called
+ EUNIT_ASSERT_EQUALS( iCalculator->iReceivedPacketCounter, 0 ); // counter is zeroed
// Other reporting
iCalculator->iReportIntervalType = 998;
iLastEvent.iPacketsReceived = 0;
iCalculator->iJitterObsOn = ETrue;
- iCalculator->iFrameLossObsOn = ETrue;
iCalculator->JitterObserving();
- EUNIT_ASSERT_EQUALS( iLastEvent.iPacketsReceived, 2 ); // just making sure that callback was called
- EUNIT_ASSERT_EQUALS( iLastError, KErrArgument );
+ EUNIT_ASSERT_EQUALS( iLastEvent.iPacketsReceived, 5 ); // just making sure that callback was called
}
void UT_CMccJitterCalculator::UT_CMccJitterCalculator_RtpPacketReceivedL()
{
- iCalculator->iReportIntervalType = EMccQualityPacketBased;
// TBD: real assert for values
const TInt KTestConversion = 8000;
- TUint testSeqNum = 222;
- iCalculator->iCurrentSeqNum = 0;
- iCalculator->iStartingSeqNum = 0;
- iCalculator->iReceivedPacketCounter = 0;
// First packet
- const TInt PacketTimestamp1 = 1000;
- iCalculator->RtpPacketReceived( PacketTimestamp1, EFalse, testSeqNum );
+ const TInt firstPacketTimestamp = 1000;
+ iCalculator->RtpPacketReceived( firstPacketTimestamp, EFalse );
EUNIT_ASSERT( iCalculator->iPrevPacketTransit != 0 );
- EUNIT_ASSERT( iCalculator->iCurrentSeqNum == 222 );
- EUNIT_ASSERT( iCalculator->iStartingSeqNum == 221 );
- EUNIT_ASSERT( iCalculator->iReceivedPacketCounter == 1 );
- testSeqNum++; //Increase seqnum for next packet.
// Second packet (fake that it is the one when reporting)
iCalculator->iPacketsReceived = 15; // ( KJitterReportInterval - 1 )
- const TInt PacketTimestamp2 = 3000;
- iCalculator->RtpPacketReceived( PacketTimestamp2, EFalse, testSeqNum );
+ const TInt secondPacketTimestamp = 3000;
+ iCalculator->RtpPacketReceived( secondPacketTimestamp, EFalse );
EUNIT_ASSERT( iCalculator->iCurJitter != 0 );
EUNIT_ASSERT_EQUALS( (TInt)iLastEvent.iPacketsReceived, 16 ); // just making sure that callback was called
- EUNIT_ASSERT( iCalculator->iCurrentSeqNum == 223 );
- EUNIT_ASSERT( iCalculator->iStartingSeqNum == 221 );
- EUNIT_ASSERT( iCalculator->iReceivedPacketCounter == 2 );
-
-
- iCalculator->iReportIntervalType = EMccQualityTimeBased;
- iCalculator->iFrameLossObsOn = EFalse;
- testSeqNum++; //Increase seqnum for next packet.
-
- const TInt packetTimestamp3 = 4000;
- iCalculator->RtpPacketReceived( packetTimestamp3, EFalse, testSeqNum );
- EUNIT_ASSERT( iCalculator->iCurJitter != 0 );
- EUNIT_ASSERT_EQUALS( (TInt)iLastEvent.iPacketsReceived, 16 ); // just making sure that callback wasn't called
- EUNIT_ASSERT( iCalculator->iCurrentSeqNum == 223 );
- EUNIT_ASSERT( iCalculator->iStartingSeqNum == 221 );
- EUNIT_ASSERT( iCalculator->iReceivedPacketCounter == 2 );
-
- // Sequence number start from 0
- iCalculator->iReportIntervalType = EMccQualityPacketBased;
- iCalculator->iFrameLossObsOn = ETrue;
- testSeqNum = 0;
- const TInt packetTimestamp4 = 5000;
- iCalculator->RtpPacketReceived( packetTimestamp4, EFalse, testSeqNum );
- EUNIT_ASSERT( iCalculator->iCurJitter != 0 );
- EUNIT_ASSERT_EQUALS( (TInt)iLastEvent.iPacketsReceived, 16 ); // just making sure that callback wasn't called
- EUNIT_ASSERT_EQUALS( iCalculator->iCurrentSeqNum, 0);
- EUNIT_ASSERT( iCalculator->iStartingSeqNum == 0 );
- EUNIT_ASSERT( iCalculator->iReceivedPacketCounter == 3 );
-
- // Sequence number start from 1
- testSeqNum = 1;
- const TInt packetTimestamp5 = 6000;
- iCalculator->RtpPacketReceived( packetTimestamp5, EFalse, testSeqNum );
- EUNIT_ASSERT( iCalculator->iCurJitter != 0 );
- EUNIT_ASSERT_EQUALS( (TInt)iLastEvent.iPacketsReceived, 16 ); // just making sure that callback wasn't called
- EUNIT_ASSERT_EQUALS( iCalculator->iCurrentSeqNum, 1);
- EUNIT_ASSERT( iCalculator->iStartingSeqNum == 0 );
- EUNIT_ASSERT( iCalculator->iReceivedPacketCounter == 4 );
-
}
-
-void UT_CMccJitterCalculator::UT_CMccJitterCalculator_CalculateFerL()
- {
- TUint32 returnValue( 0 );
-
- // packet lost
- TUint32 prevValue( 0 );
- TBool valueToadd( ETrue );
- TBool flagToAdd( ETrue );
- returnValue = iCalculator->CalculateFer( prevValue, valueToadd, flagToAdd );
- EUNIT_ASSERT_EQUALS( returnValue, 2000 );
-
- // packet lost
- // returnValue == 2000
- returnValue = iCalculator->CalculateFer( returnValue, valueToadd, flagToAdd );
- EUNIT_ASSERT_EQUALS( returnValue, 3992 );
-
- // no packet lost - late packet - remove FER
- // decrease fer
- flagToAdd = EFalse;
- // returnValue == 3996
- returnValue = iCalculator->CalculateFer( returnValue, valueToadd, flagToAdd );
-
- EUNIT_ASSERT_EQUALS( returnValue, 2008 );
-
- // no packet lost - late packet - remove FER
- // decrease fer
- flagToAdd = EFalse;
- // returnValue == 5
- returnValue = 5;
- returnValue = iCalculator->CalculateFer( returnValue, valueToadd, flagToAdd );
-
- EUNIT_ASSERT_EQUALS( returnValue, 0);
- }
-
-void UT_CMccJitterCalculator::UT_CMccJitterCalculator_CountPacketLossPercentageL()
- {
- TInt percentage( 0 );
-
- iCalculator->iHomeTime.HomeTime();
-
- // Not active
- iCalculator->JitterObserving();
-
- iCalculator->iPrevFerValue = 0;
- iCalculator->iStartingSeqNum = 80;
- iCalculator->iCurrentSeqNum = 100;
-
- // no packets lost
- iCalculator->iPrevExpectedPackets = 20;
- iCalculator->iReceivedPacketCounter = 20;
-
- iCalculator->CountPacketLossPercentage();
-
- EUNIT_ASSERT_EQUALS( iCalculator->iPrevFerValue, 0 );
- EUNIT_ASSERT_EQUALS( iCalculator->iPrevExpectedPackets, 20 );
- EUNIT_ASSERT_EQUALS( iCalculator->iPrevPacketsReceived, 20 );
-
-
- // no packets lost, inorder
- iCalculator->iCurrentSeqNum = 102;
- iCalculator->iPrevExpectedPackets = 22;
-
- iCalculator->CountPacketLossPercentage();
-
- EUNIT_ASSERT_EQUALS( iCalculator->iPrevFerValue, 0 );
- EUNIT_ASSERT_EQUALS( iCalculator->iPrevExpectedPackets, 22 );
- EUNIT_ASSERT_EQUALS( iCalculator->iPrevPacketsReceived, 20 );
-
-
- // packet lost - add FER by number of packets lost.
- // 5 packets lost
- iCalculator->iPrevFerValue = 0;
- iCalculator->iStartingSeqNum = 80;
- iCalculator->iCurrentSeqNum = 105;
-
- iCalculator->iPrevExpectedPackets = 20;
- iCalculator->iReceivedPacketCounter = 20;
-
- percentage = iCalculator->CountPacketLossPercentage();
-
- EUNIT_ASSERT_EQUALS( percentage, 1 );
- EUNIT_ASSERT_EQUALS( iCalculator->iPrevFerValue, 7952 );
- EUNIT_ASSERT_EQUALS( iCalculator->iPrevExpectedPackets, 25 );
- EUNIT_ASSERT_EQUALS( iCalculator->iPrevPacketsReceived, 20 );
- }
-
-void UT_CMccJitterCalculator::UT_CMccJitterCalculator_ResetCountersL()
- {
-
- iCalculator->iPacketsReceived = 20;
- iCalculator->iCurJitter = 200;
- iCalculator->iPrevPacketTransit = 100;
- iCalculator->iCurrentSeqNum = 25;
- iCalculator->iStartingSeqNum = 2;
- iCalculator->iReceivedPacketCounter = 30;
-
- iCalculator->ResetCounters();
-
- EUNIT_ASSERT_EQUALS( iCalculator->iPacketsReceived, 0 );
- EUNIT_ASSERT_EQUALS( iCalculator->iCurJitter, 0 );
- EUNIT_ASSERT_EQUALS( iCalculator->iPrevPacketTransit, 0 );
- EUNIT_ASSERT_EQUALS( iCalculator->iCurrentSeqNum, 0 );
- EUNIT_ASSERT_EQUALS( iCalculator->iStartingSeqNum, 0 );
- EUNIT_ASSERT_EQUALS( iCalculator->iReceivedPacketCounter, 0 );
- }
-
-
// TEST TABLE
EUNIT_BEGIN_TEST_TABLE(
UT_CMccJitterCalculator,
- "CMccJitterCalculator",
+ "Add test suite description here.",
"UNIT" )
EUNIT_TEST(
@@ -426,29 +223,6 @@
"FUNCTIONALITY",
SetupL, UT_CMccJitterCalculator_RtpPacketReceivedL, Teardown)
-
-EUNIT_TEST(
- "CalculateFer - test ",
- "CMccJitterCalculator",
- "CalculateFer",
- "FUNCTIONALITY",
- SetupL, UT_CMccJitterCalculator_CalculateFerL, Teardown)
-
-EUNIT_TEST(
- "CountPacketLossPercentage - test ",
- "CMccJitterCalculator",
- "CountPacketLossPercentage",
- "FUNCTIONALITY",
- SetupL, UT_CMccJitterCalculator_CountPacketLossPercentageL, Teardown)
-
-EUNIT_TEST(
- "ResetCounters - test ",
- "CMccJitterCalculator",
- "ResetCounters",
- "FUNCTIONALITY",
- SetupL, UT_CMccJitterCalculator_ResetCountersL, Teardown)
-
-
EUNIT_END_TEST_TABLE
// END OF FILE
--- a/multimediacommscontroller/mmccrtpsourcesink/tsrc/ut_rtpsourcesink/src/UT_CMccRtpDataSink.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccrtpsourcesink/tsrc/ut_rtpsourcesink/src/UT_CMccRtpDataSink.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -42,7 +42,6 @@
#include <srtpmastersalt.h>
#include <srtpstreamout.h>
#include "mccunittestmacros.h"
-#include "mccrtpmediaclock.h"
#define MCCEVENTDATAPCKG_TO_RTCPEVENTDATAPCKG( event )\
@@ -116,7 +115,6 @@
*iRtpApi,
rtpSessionId );
- iRtpMediaClock = CMccRtpMediaClock::NewL();
}
void UT_CMccRtpDataSink::Teardown()
@@ -138,12 +136,6 @@
delete iRtpApi;
iRtpApi = NULL;
}
-
- if ( iRtpMediaClock )
- {
- delete iRtpMediaClock;
- iRtpMediaClock = NULL;
- }
}
// HELPERS
@@ -164,7 +156,7 @@
TMccCodecInfo cInfo;
TMccCodecInfoBuffer cInfoBuf( cInfo );
- MCC_EUNIT_ASSERT_NO_LEAVE( iSink->ConfigureL( cInfoBuf, iRtpMediaClock ) );
+ MCC_EUNIT_ASSERT_NO_LEAVE( iSink->ConfigureL( cInfoBuf ) );
}
@@ -226,7 +218,7 @@
TMccCodecInfo cInfo;
TMccCodecInfoBuffer cInfoBuf( cInfo );
- MCC_EUNIT_ASSERT_NO_LEAVE( iSink->ConfigureL( cInfoBuf, iRtpMediaClock ) );
+ MCC_EUNIT_ASSERT_NO_LEAVE( iSink->ConfigureL( cInfoBuf ) );
MCC_EUNIT_ASSERT_EQUALS( iSink->SinkThreadLogon( *this ), KErrNone );
iSink->SetCurrentUser( this );
EUNIT_ASSERT_NO_LEAVE( iSink->SinkPrimeL() );
@@ -297,7 +289,7 @@
MCC_EUNIT_ASSERT_EQUALS( iSink->SinkThreadLogon( *this ), KErrNone );
iSink->SetCurrentUser( this );
EUNIT_ASSERT_NO_LEAVE( iSink->SetSessionParamsL( params ) );
- MCC_EUNIT_ASSERT_NO_LEAVE( iSink->ConfigureL( cInfoBuf, iRtpMediaClock ) );
+ MCC_EUNIT_ASSERT_NO_LEAVE( iSink->ConfigureL( cInfoBuf ) );
EUNIT_ASSERT_NO_LEAVE( iSink->SinkPrimeL() );
iSink->SinkThreadLogoff();
}
@@ -374,7 +366,7 @@
TMccCodecInfo cInfo;
TMccCodecInfoBuffer cInfoBuf( cInfo );
- MCC_EUNIT_ASSERT_NO_LEAVE( iSink->ConfigureL( cInfoBuf, iRtpMediaClock ) );
+ MCC_EUNIT_ASSERT_NO_LEAVE( iSink->ConfigureL( cInfoBuf ) );
EUNIT_ASSERT_NO_LEAVE( iSink->SinkPrimeL() );
EUNIT_ASSERT( iRtpKeepaliveMechanism->iStopped == EFalse );
@@ -623,7 +615,7 @@
TMccCodecInfo cInfo;
TMccCodecInfoBuffer cInfoBuf( cInfo );
- MCC_EUNIT_ASSERT_NO_LEAVE( iSink->ConfigureL( cInfoBuf, iRtpMediaClock ) );
+ MCC_EUNIT_ASSERT_NO_LEAVE( iSink->ConfigureL( cInfoBuf ) );
EUNIT_ASSERT_NO_LEAVE( iSink->SinkPrimeL() );
// Create a comfort noise stream
@@ -646,12 +638,12 @@
TMccCodecInfo cInfo;
TMccCodecInfoBuffer cInfoBuf( cInfo );
- MCC_EUNIT_ASSERT_NO_LEAVE( iSink->ConfigureL( cInfoBuf, iRtpMediaClock ) );
+ MCC_EUNIT_ASSERT_NO_LEAVE( iSink->ConfigureL( cInfoBuf ) );
// This should leave because the string is too short
TBuf8<5> dummy;
dummy.Format( _L8( "foo42" ) );
- EUNIT_ASSERT_LEAVE( iSink->ConfigureL( dummy, iRtpMediaClock ) );
+ EUNIT_ASSERT_LEAVE( iSink->ConfigureL( dummy ) );
// Get a new sink
//Teardown();
@@ -698,7 +690,7 @@
cInfo2.iAlgoUsed = EGenRedUsed;
TMccCodecInfoBuffer cInfoBuf2( cInfo2 );
- EUNIT_ASSERT_NO_LEAVE( iSink->ConfigureL( cInfoBuf2, iRtpMediaClock ) );
+ EUNIT_ASSERT_NO_LEAVE( iSink->ConfigureL( cInfoBuf2 ) );
}
void UT_CMccRtpDataSink::UT_CMccRtpDataSink_RemoveStreamLL()
@@ -749,7 +741,7 @@
TMccCodecInfo cInfo;
TMccCodecInfoBuffer cInfoBuf( cInfo );
- MCC_EUNIT_ASSERT_NO_LEAVE( iSink->ConfigureL( cInfoBuf, iRtpMediaClock ) );
+ MCC_EUNIT_ASSERT_NO_LEAVE( iSink->ConfigureL( cInfoBuf ) );
// Wrong state
EUNIT_ASSERT_LEAVE( iSink->SinkPlayL() );
@@ -778,7 +770,7 @@
TMccCodecInfo cInfo;
TMccCodecInfoBuffer cInfoBuf( cInfo );
- MCC_EUNIT_ASSERT_NO_LEAVE( iSink->ConfigureL( cInfoBuf, iRtpMediaClock ) );
+ MCC_EUNIT_ASSERT_NO_LEAVE( iSink->ConfigureL( cInfoBuf ) );
// Wrong state
EUNIT_ASSERT_LEAVE( iSink->SinkPauseL() );
@@ -805,7 +797,7 @@
TMccCodecInfo cInfo;
TMccCodecInfoBuffer cInfoBuf( cInfo );
- MCC_EUNIT_ASSERT_NO_LEAVE( iSink->ConfigureL( cInfoBuf, iRtpMediaClock ) );
+ MCC_EUNIT_ASSERT_NO_LEAVE( iSink->ConfigureL( cInfoBuf ) );
iSink->SinkPrimeL();
iSink->SinkPlayL();
--- a/multimediacommscontroller/mmccrtpsourcesink/tsrc/ut_rtpsourcesink/src/UT_CMccRtpDataSource.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccrtpsourcesink/tsrc/ut_rtpsourcesink/src/UT_CMccRtpDataSource.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -36,7 +36,6 @@
#include <srtpstreamin.h>
#include "UT_CMccRtpInterface.h"
#include "mccunittestmacros.h"
-#include "mccrtpmediaclock.h"
// CONSTANTS
_LIT8(KRFC3711_TestMasterKey128bits, "E1F97A0D3E018BE0D64FA32C06DE4139");
@@ -104,8 +103,7 @@
CMccRtpKeepaliveContainer::NewL( *eventHandler,
*iRtpApi,
rtpSessionId );
-
- iRtpMediaClock = CMccRtpMediaClock::NewL();
+
}
void UT_CMccRtpDataSource::Teardown()
@@ -130,12 +128,6 @@
}
delete iEventHandler;
-
- if ( iRtpMediaClock )
- {
- delete iRtpMediaClock;
- iRtpMediaClock = NULL;
- }
}
@@ -173,7 +165,7 @@
cInfo.iBitrate = 8000;
cInfo.iPayloadType = KDefaultAmrNbPT;
TMccCodecInfoBuffer cInfoBuf( cInfo );
- EUNIT_ASSERT_NO_LEAVE( iSource->ConfigureL( cInfoBuf, iRtpMediaClock ) );
+ EUNIT_ASSERT_NO_LEAVE( iSource->ConfigureL( cInfoBuf ) );
}
// TEST FUNCTIONS
@@ -217,7 +209,7 @@
cInfo.iPayloadType = KDefaultAmrNbPT;
TMccCodecInfoBuffer cInfoBuf( cInfo );
- EUNIT_ASSERT_NO_LEAVE( iSource->ConfigureL( cInfoBuf, iRtpMediaClock ) );
+ EUNIT_ASSERT_NO_LEAVE( iSource->ConfigureL( cInfoBuf ) );
//iSource->NegotiateSourceL( *iEventHandler );
EUNIT_ASSERT_NO_LEAVE( iSource->NegotiateSourceL( *amrPfRead ) );
EUNIT_ASSERT_NO_LEAVE( iSource->SourcePrimeL() );
@@ -383,7 +375,7 @@
cInfo.iPayloadType = KDefaultAmrNbPT;
TMccCodecInfoBuffer cInfoBuf( cInfo );
- EUNIT_ASSERT_NO_LEAVE( iSource->ConfigureL( cInfoBuf, iRtpMediaClock ) );
+ EUNIT_ASSERT_NO_LEAVE( iSource->ConfigureL( cInfoBuf ) );
MCC_EUNIT_ASSERT_EQUALS( iSource->SourceThreadLogon( *iEventHandler ), KErrNone );
EUNIT_ASSERT_NO_LEAVE( iSource->SourcePrimeL() );
@@ -408,7 +400,7 @@
cInfo.iPayloadType = KDefaultAmrNbPT;
TMccCodecInfoBuffer cInfoBuf( cInfo );
- EUNIT_ASSERT_NO_LEAVE( iSource->ConfigureL( cInfoBuf, iRtpMediaClock ) );
+ EUNIT_ASSERT_NO_LEAVE( iSource->ConfigureL( cInfoBuf ) );
MCC_EUNIT_ASSERT_EQUALS( iSource->SourceThreadLogon( *iEventHandler ), KErrNone );
EUNIT_ASSERT_NO_LEAVE( iSource->SourcePrimeL() );
@@ -529,7 +521,7 @@
cInfo.iPayloadType = KDefaultAmrNbPT;
TMccCodecInfoBuffer cInfoBuf( cInfo );
- EUNIT_ASSERT_NO_LEAVE( iSource->ConfigureL( cInfoBuf, iRtpMediaClock ) );
+ EUNIT_ASSERT_NO_LEAVE( iSource->ConfigureL( cInfoBuf ) );
MCC_EUNIT_ASSERT_EQUALS( iSource->SourceThreadLogon( *iEventHandler ), KErrNone );
EUNIT_ASSERT_NO_LEAVE( iSource->SourcePrimeL() );
@@ -615,7 +607,7 @@
cInfo.iFourCC = TFourCC( KMccFourCCIdG711 );
cInfo.iEnableDTX = ETrue;
TMccCodecInfoBuffer cInfoBuf( cInfo );
- EUNIT_ASSERT_NO_LEAVE( iSource->ConfigureL( cInfoBuf, iRtpMediaClock ) );
+ EUNIT_ASSERT_NO_LEAVE( iSource->ConfigureL( cInfoBuf ) );
header.iPayloadType = KPcmuPayloadType;
@@ -647,7 +639,7 @@
TMccCodecInfo cInfo;
TMccCodecInfoBuffer cInfoBuf( cInfo );
- EUNIT_ASSERT_NO_LEAVE( iSource->ConfigureL( cInfoBuf, iRtpMediaClock ) );
+ EUNIT_ASSERT_NO_LEAVE( iSource->ConfigureL( cInfoBuf ) );
// Get a new Source
Teardown();
@@ -657,7 +649,7 @@
TBuf8<5> dummy;
dummy.Format( _L8( "foo42" ) );
EUNIT_ASSERT_NO_LEAVE( iSource->SetSessionParamsL( params ) );
- EUNIT_ASSERT_LEAVE( iSource->ConfigureL( dummy, iRtpMediaClock ) );
+ EUNIT_ASSERT_LEAVE( iSource->ConfigureL( dummy ) );
// Get a new Source
Teardown();
@@ -678,7 +670,7 @@
cInfo2.iAlgoUsed = EGenRedUsed;
TMccCodecInfoBuffer cInfoBuf2( cInfo2 );
- EUNIT_ASSERT_NO_LEAVE( iSource->ConfigureL( cInfoBuf2, iRtpMediaClock ) );
+ EUNIT_ASSERT_NO_LEAVE( iSource->ConfigureL( cInfoBuf2 ) );
}
void UT_CMccRtpDataSource::UT_CMccRtpDataSource_DoCreateSrtpStreamL()
@@ -709,7 +701,7 @@
EUNIT_ASSERT_EQUALS( iEventHandler->iLastEvent.iEventType, KMccStreamResumed );
// Jitter event when no event handler
- TMccRtpEventDataExtended eventData;
+ TMccRtpEventData eventData;
iSource->SendJitterEvent( eventData, KErrNone );
EUNIT_ASSERT_EQUALS( iEventHandler->iLastEvent.iEventType, KMccStreamResumed );
@@ -787,19 +779,6 @@
iSource->SendSecureRtpEventToClient(
iEventHandler, KMccRtpSourceUid, EMccInternalEventNone, KMccStreamPaused, 0 );
EUNIT_ASSERT_EQUALS( iEventHandler->iLastEvent.iEventType, KMccStreamPaused );
-
- // SendJitterEventToClient()
- iSource->SendJitterEventToClient( iEventHandler, KMccRtpSourceUid,
- EMccInternalEventNone, KMccEventNone, 0, 0, 1,2,3,4,5,6 );
- EUNIT_ASSERT_EQUALS( iEventHandler->iLastEvent.iEventType, KMccEventNone );
- const TMccRtpEventDataExtended& rtpEvent =
- (*reinterpret_cast<const TMccRtpEventDataExtendedPackage*>( &iEventHandler->iLastEvent.iEventData ))();
- EUNIT_ASSERT_EQUALS( rtpEvent.iJitterEstimate, 1 );
- EUNIT_ASSERT_EQUALS( rtpEvent.iPacketsReceived, 2 );
- EUNIT_ASSERT_EQUALS( rtpEvent.iPrevTransTime, 3 );
- EUNIT_ASSERT_EQUALS( rtpEvent.iTriggeredJitterLevel, 4 );
- EUNIT_ASSERT_EQUALS( rtpEvent.iPacketLoss, 5 );
- EUNIT_ASSERT_EQUALS( rtpEvent.iTriggeredPacketLoss, 6 );
}
void UT_CMccRtpDataSource::UT_CMccRtpDataSource_DoStandbyDecisionL()
--- a/multimediacommscontroller/mmccrtpsourcesink/tsrc/ut_rtpsourcesink/src/UT_CMccRtpInterface.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccrtpsourcesink/tsrc/ut_rtpsourcesink/src/UT_CMccRtpInterface.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -29,7 +29,6 @@
#include "mccrtpinterface.h"
#include "mccrtpdatasink.h"
#include "mccrtpkeepalivecontainer.h"
-#include "mccrtpmediaclock.h"
// CONSTRUCTION
UT_CMccRtpInterface* UT_CMccRtpInterface::NewL()
@@ -94,8 +93,6 @@
CMccRtpKeepaliveContainer::NewL( *eventHandler,
*iRtpApi,
iRtpSessionId );
-
- iRtpMediaClock = CMccRtpMediaClock::NewL();
}
void UT_CMccRtpInterface::Teardown( )
@@ -108,19 +105,13 @@
delete iRtpApi;
iRtpApi = NULL;
-
- if ( iRtpMediaClock )
- {
- delete iRtpMediaClock;
- iRtpMediaClock = NULL;
- }
}
void UT_CMccRtpInterface::UT_CMccRtpInterface_ConfigureLL()
{
TMccCodecInfo cInfo;
EUNIT_ASSERT_SPECIFIC_LEAVE(
- iInterface->ConfigureL( TMccCodecInfoBuffer( cInfo ), iRtpMediaClock ), KErrNotReady );
+ iInterface->ConfigureL( TMccCodecInfoBuffer( cInfo ) ), KErrNotReady );
TMccRtpSessionParams params;
params.iRtpAPI = iRtpApi;
@@ -130,23 +121,23 @@
iInterface->SetSessionParamsL( params );
TBuf8<1> kaData;
EUNIT_ASSERT_SPECIFIC_LEAVE(
- iInterface->ConfigureL( kaData, iRtpMediaClock ), KErrArgument );
+ iInterface->ConfigureL( kaData ), KErrArgument );
cInfo.iKeepalivePT = 13;
cInfo.iKeepaliveInterval = 0;
cInfo.iKeepaliveData = kaData;
- iInterface->ConfigureL( TMccCodecInfoBuffer( cInfo ), iRtpMediaClock );
+ iInterface->ConfigureL( TMccCodecInfoBuffer( cInfo ) );
EUNIT_ASSERT( TMccCodecInfo::Compare( cInfo, iInterface->iCodecInfo ) );
TMccCodecInfo backup = iInterface->iCodecInfo;
cInfo.iKeepaliveInterval = 28;
- iInterface->ConfigureL( TMccCodecInfoBuffer( cInfo ), iRtpMediaClock );
+ iInterface->ConfigureL( TMccCodecInfoBuffer( cInfo ) );
EUNIT_ASSERT(
cInfo.iKeepaliveInterval == iInterface->iCodecInfo.iKeepaliveInterval );
backup = iInterface->iCodecInfo;
cInfo.iKeepaliveInterval = 0;
- iInterface->ConfigureL( TMccCodecInfoBuffer( cInfo ), iRtpMediaClock );
+ iInterface->ConfigureL( TMccCodecInfoBuffer( cInfo ) );
EUNIT_ASSERT( TMccCodecInfo::Compare( backup, iInterface->iCodecInfo ) );
}
--- a/multimediacommscontroller/mmccshared/inc/mccinternalcodecs.h Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccshared/inc/mccinternalcodecs.h Wed Oct 13 14:59:15 2010 +0300
@@ -563,8 +563,8 @@
// MMF Priority settings
TMMFPrioritySettings iPriority;
- // Rtp keepalive interval (microsecs)
- TUint32 iKeepaliveInterval;
+ // Rtp keepalive interval (secs)
+ TUint8 iKeepaliveInterval;
// Rtp keepalive payload type
TUint8 iKeepalivePT;
--- a/multimediacommscontroller/mmccsubcontroller/group/subcontroller.mmp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccsubcontroller/group/subcontroller.mmp Wed Oct 13 14:59:15 2010 +0300
@@ -82,15 +82,15 @@
LIBRARY insock.lib
LIBRARY 3gpmp4lib.lib
LIBRARY efsrv.lib
-LIBRARY SpeechEncoderConfig.lib
-LIBRARY ErrorConcealmentIntfc.lib
-LIBRARY AudioOutputRouting.lib
-LIBRARY G711DecoderIntfc.lib
-LIBRARY G711EncoderIntfc.lib
-LIBRARY G729DecoderIntfc.lib
-LIBRARY G729EncoderIntfc.lib
-LIBRARY IlbcDecoderIntfc.lib
-LIBRARY IlbcEncoderIntfc.lib
+LIBRARY speechencoderconfig.lib
+LIBRARY errorconcealmentintfc.lib
+LIBRARY audiooutputrouting.lib
+LIBRARY g711decoderintfc.lib
+LIBRARY g711encoderintfc.lib
+LIBRARY g729decoderintfc.lib
+LIBRARY g729encoderintfc.lib
+LIBRARY ilbcdecoderintfc.lib
+LIBRARY ilbcencoderintfc.lib
LIBRARY srtp.lib
// Other MCC libraries
LIBRARY mmccjitterbuffer.lib
--- a/multimediacommscontroller/mmccsubcontroller/inc/mccrtpkeepalive.h Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccsubcontroller/inc/mccrtpkeepalive.h Wed Oct 13 14:59:15 2010 +0300
@@ -67,7 +67,7 @@
CRtpAPI& aRtpAPI,
TRtpId aRtpSessionId,
TUint8 aKeepalivePayloadType,
- TUint32 aKeepaliveInterval,
+ TUint8 aKeepaliveInterval,
const TDesC8& aKeepaliveData,
TBool aRemoteAddressSet );
@@ -139,9 +139,8 @@
* @return void
*/
void UpdateParamsL( TUint8 aKeepalivePT,
- TUint32 aKeepaliveInterval,
- const TDesC8& aKeepaliveData,
- CMccRtpMediaClock* aRtpMediaClock );
+ TUint8 aKeepaliveInterval,
+ const TDesC8& aKeepaliveData );
protected: // New functions
@@ -181,7 +180,7 @@
* By default Symbian 2nd phase constructor is private.
*/
void ConstructL( TUint8 aKeepalivePayloadType,
- TUint32 aKeepaliveInterval,
+ TUint8 aKeepaliveInterval,
const TDesC8& aKeepaliveData );
public: // Data
--- a/multimediacommscontroller/mmccsubcontroller/inc/mccrtpkeepalivecontainer.h Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccsubcontroller/inc/mccrtpkeepalivecontainer.h Wed Oct 13 14:59:15 2010 +0300
@@ -87,12 +87,10 @@
* @since Series 60 3.2
* @param aUser rtp interface instance
* @param aCodecInfo codec info instance
- * @param aRtpMediaClock rtp media clock instance
* @return void
*/
virtual void UpdateParamsL( MMccRtpInterface& aUser,
- const TMccCodecInfo& aCodecInfo,
- CMccRtpMediaClock& aRtpMediaClock ) = 0;
+ const TMccCodecInfo& aCodecInfo ) = 0;
};
NONSHARABLE_CLASS( CMccRtpKeepaliveContainer ) : public CBase,
@@ -151,12 +149,10 @@
* @since Series 60 3.2
* @param aUser rtp interface instance
* @param aConfig Configuration
- * @param aRtpMediaClock rtp media clock instance
* @return void
*/
virtual void UpdateParamsL( MMccRtpInterface& aUser,
- const TMccCodecInfo& aConfig,
- CMccRtpMediaClock& aRtpMediaClock );
+ const TMccCodecInfo& aConfig );
public: // Functions
--- a/multimediacommscontroller/mmccsubcontroller/inc/mccsymdlstream.h Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccsubcontroller/inc/mccsymdlstream.h Wed Oct 13 14:59:15 2010 +0300
@@ -50,8 +50,7 @@
MAsyncEventHandler* aEventhandler,
MMccResources* aMccResources,
CMccRtpManager* aManager,
- TInt aStreamType,
- CMccRtpMediaClock& aClock );
+ TInt aStreamType );
/**
* Destructor.
@@ -201,8 +200,7 @@
MAsyncEventHandler* aEventhandler,
MMccResources* aMccResources,
CMccRtpManager* aManager,
- TInt aStreamType,
- CMccRtpMediaClock& aClock );
+ TInt aStreamType );
/**
* 2nd phase constructor
--- a/multimediacommscontroller/mmccsubcontroller/inc/mccsymsimpledlstream.h Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccsubcontroller/inc/mccsymsimpledlstream.h Wed Oct 13 14:59:15 2010 +0300
@@ -49,8 +49,7 @@
MMccResources* aMccResources,
CMccRtpManager* aManager,
TFourCC aFourCC,
- TInt aStreamType,
- CMccRtpMediaClock& aClock );
+ TInt aStreamType );
/**
* Destructor.
@@ -187,8 +186,7 @@
MMccResources* aMccResources,
CMccRtpManager* aManager,
TFourCC aFourCC,
- TInt aStreamType,
- CMccRtpMediaClock& aClock );
+ TInt aStreamType );
/**
* 2nd phase constructor
--- a/multimediacommscontroller/mmccsubcontroller/src/mccdtmfulstream.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccsubcontroller/src/mccdtmfulstream.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -187,6 +187,9 @@
CreatePayloadFormatEncoderL();
+ CMccRtpDataSink* dataSink = static_cast<CMccRtpDataSink*>( iDatasink );
+ dataSink->SetMediaClock( *iRtpMediaClock );
+
SetCodecState( EStateCodecNegotiated );
}
else if ( CurrentCodecState() == EStateCodecNegotiated )
--- a/multimediacommscontroller/mmccsubcontroller/src/mccrtpkeepalive.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccsubcontroller/src/mccrtpkeepalive.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -62,7 +62,7 @@
CRtpAPI& aRtpAPI,
TRtpId aRtpSessionId,
TUint8 aKeepalivePayloadType,
- TUint32 aKeepaliveInterval,
+ TUint8 aKeepaliveInterval,
const TDesC8& aKeepaliveData,
TBool aRemoteAddressSet )
{
@@ -220,7 +220,7 @@
// ---------------------------------------------------------------------------
//
void CMccRtpKeepalive::UpdateParamsL( TUint8 aKeepalivePT,
- TUint32 aKeepaliveInterval, const TDesC8& aKeepaliveData, CMccRtpMediaClock* aRtpMediaClock )
+ TUint8 aKeepaliveInterval, const TDesC8& aKeepaliveData )
{
__SUBCONTROLLER_INT1(
"CMccRtpKeepalive::UpdateParamsL(), PT:", aKeepalivePT )
@@ -236,8 +236,8 @@
delete iKeepaliveData;
iKeepaliveData = tmp;
- iKeepaliveInterval = aKeepaliveInterval;
- iRtpMediaClock = aRtpMediaClock;
+ const TUint KMccSecsToMicroSecs = 1000000;
+ iKeepaliveInterval = aKeepaliveInterval * KMccSecsToMicroSecs;
}
// ---------------------------------------------------------------------------
@@ -412,7 +412,7 @@
if ( !IsActive() && ( 0 < iKeepaliveInterval ) )
{
- if ( iRemoteAddressSet && iRtpMediaClock )
+ if ( iRemoteAddressSet )
{
__SUBCONTROLLER( "CMccRtpKeepalive::StartSending(), issue send timer" )
@@ -548,7 +548,7 @@
//
void CMccRtpKeepalive::ConstructL(
TUint8 aKeepalivePayloadType,
- TUint32 aKeepaliveInterval,
+ TUint8 aKeepaliveInterval,
const TDesC8& aKeepaliveData )
{
__SUBCONTROLLER( "CMccRtpKeepalive::ConstructL()" )
@@ -561,7 +561,7 @@
iRtpHeaderInfo.iMarker = 0;
UpdateParamsL( aKeepalivePayloadType, aKeepaliveInterval,
- aKeepaliveData, NULL );
+ aKeepaliveData );
iSequenceNum = Random();
--- a/multimediacommscontroller/mmccsubcontroller/src/mccrtpkeepalivecontainer.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccsubcontroller/src/mccrtpkeepalivecontainer.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -178,7 +178,7 @@
// ---------------------------------------------------------------------------
//
void CMccRtpKeepaliveContainer::UpdateParamsL( MMccRtpInterface& aUser,
- const TMccCodecInfo& aCodecInfo, CMccRtpMediaClock& aRtpMediaClock )
+ const TMccCodecInfo& aCodecInfo )
{
__SUBCONTROLLER( "CMccRtpKeepaliveContainer::UpdateParamsL(), Entry" )
@@ -191,18 +191,13 @@
// previous keep-alive data.
handler->Cancel();
handler->UpdateParamsL( aCodecInfo.iKeepalivePT,
- aCodecInfo.iKeepaliveInterval, aCodecInfo.iKeepaliveData, &aRtpMediaClock );
+ aCodecInfo.iKeepaliveInterval, aCodecInfo.iKeepaliveData );
if ( aCodecInfo.iKeepaliveInterval > 0 && !handler->IsActive() )
{
handler->ResetKeepaliveTimer();
}
}
- else
- {
- TMccCodecInfo cInfo = aCodecInfo;
- StartKeepaliveL( aUser, cInfo, aRtpMediaClock );
- }
__SUBCONTROLLER( "CMccRtpKeepaliveContainer::UpdateParamsL(), exit" )
}
--- a/multimediacommscontroller/mmccsubcontroller/src/mccrtpmanager.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccsubcontroller/src/mccrtpmanager.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -516,7 +516,7 @@
dSink.SetSessionParamsL( sessParams );
TMccCodecInfoBuffer infoBuffer( aCodecInfo );
- dSink.ConfigureL( infoBuffer, NULL );
+ dSink.ConfigureL( infoBuffer );
UpdateL( &aCodecInfo );
}
@@ -549,7 +549,7 @@
dSource.SetSessionParamsL( sessParams );
TMccCodecInfoBuffer infoBuffer( aCodecInfo );
- dSource.ConfigureL( infoBuffer, NULL );
+ dSource.ConfigureL( infoBuffer );
UpdateL( &aCodecInfo );
}
--- a/multimediacommscontroller/mmccsubcontroller/src/mccsymdlstream.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccsubcontroller/src/mccsymdlstream.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -49,8 +49,7 @@
MAsyncEventHandler* aEventhandler,
MMccResources* aMccResources,
CMccRtpManager* aManager,
- TInt aStreamType,
- CMccRtpMediaClock& aClock ) :
+ TInt aStreamType ) :
CMccSymStreamBase( aMccStreamId,
aEventhandler,
aMccResources,
@@ -59,7 +58,6 @@
iJitterBuffer( NULL ),
iFormatDecode( NULL )
{
- iRtpMediaClock = &aClock;
}
// -----------------------------------------------------------------------------
@@ -72,16 +70,14 @@
MAsyncEventHandler* aEventhandler,
MMccResources* aMccResources,
CMccRtpManager* aManager,
- TInt aStreamType,
- CMccRtpMediaClock& aClock )
+ TInt aStreamType )
{
CMccSymDlStream* s =
new ( ELeave ) CMccSymDlStream( aMccStreamId,
aEventhandler,
aMccResources,
aManager,
- aStreamType,
- aClock );
+ aStreamType );
CleanupStack::PushL( s );
s->ConstructL();
return s;
@@ -265,10 +261,6 @@
else if ( CurrentCodecState() == EStateCodecLoaded ||
CurrentCodecState() == EStateCodecLoadedAndUpdating )
{
- iJitterBuffer->SetupL( iCodecInfo.iMaxPtime,
- iCodecInfo.iJitterBufThreshold,
- iCodecInfo );
-
// Update codec info
if ( iDatasource->DataSourceType() == KMccRtpSourceUid )
{
@@ -277,7 +269,7 @@
// For updating keep alive parameters
TMccCodecInfoBuffer infoBuffer( iCodecInfo );
- dataSource->ConfigureL( infoBuffer, iRtpMediaClock );
+ dataSource->ConfigureL( infoBuffer );
}
SetCodecState( EStateCodecLoadedAndUpdating );
UpdateCodecInformationL( orig, iCodecInfo );
--- a/multimediacommscontroller/mmccsubcontroller/src/mccsymsimpledlstream.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccsubcontroller/src/mccsymsimpledlstream.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -50,8 +50,7 @@
MMccResources* aMccResources,
CMccRtpManager* aManager,
TFourCC aFourCC,
- TInt aStreamType,
- CMccRtpMediaClock& aClock ) :
+ TInt aStreamType ) :
CMccSymStreamBase( aMccStreamId,
aEventhandler,
aMccResources,
@@ -59,7 +58,6 @@
aStreamType )
{
iFourCC = aFourCC;
- iRtpMediaClock = &aClock;
}
// -----------------------------------------------------------------------------
@@ -73,8 +71,7 @@
MMccResources* aMccResources,
CMccRtpManager* aManager,
TFourCC aFourCC,
- TInt aStreamType,
- CMccRtpMediaClock& aClock )
+ TInt aStreamType )
{
CMccSymSimpleDlStream* s =
new ( ELeave ) CMccSymSimpleDlStream( aMccStreamId,
@@ -82,8 +79,7 @@
aMccResources,
aManager,
aFourCC,
- aStreamType,
- aClock );
+ aStreamType );
CleanupStack::PushL( s );
s->ConstructL();
@@ -238,7 +234,7 @@
// For updating keep alive parameters
TMccCodecInfoBuffer infoBuffer( iCodecInfo );
- dataSource->ConfigureL( infoBuffer, iRtpMediaClock );
+ dataSource->ConfigureL( infoBuffer );
}
SetCodecState( EStateCodecLoadedAndUpdating );
UpdateCodecInformationL( iCodecInfo );
--- a/multimediacommscontroller/mmccsubcontroller/src/mccsymsubthreadclient.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccsubcontroller/src/mccsymsubthreadclient.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -304,8 +304,7 @@
this,
iMccResources,
iRtpmanager,
- aStreamType,
- *iRtpMediaClock );
+ aStreamType );
}
else if( ( sourceType == KMccRtpSourceUid && sinkType == KMccVideoSinkUid ) ||
( aStreamType == KMccAudioLocalStream || aStreamType == KMccVideoLocalStream ) )
@@ -316,8 +315,7 @@
iMccResources,
iRtpmanager,
aFourCC,
- aStreamType,
- *iRtpMediaClock );
+ aStreamType );
}
else
--- a/multimediacommscontroller/mmccsubcontroller/src/mccsymulstream.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccsubcontroller/src/mccsymulstream.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -253,6 +253,12 @@
CreatePayloadFormatEncoderL();
+ if ( iDatasink->DataSinkType() == KMccRtpSinkUid )
+ {
+ CMccRtpDataSink* dataSink = static_cast<CMccRtpDataSink*>( iDatasink );
+ dataSink->SetMediaClock( *iRtpMediaClock );
+ }
+
// Just negotiate the codec, load it later
static_cast<CMccUlDataPath*>( iDatapath )->NegotiateL( *iFormatEncode );
@@ -272,15 +278,6 @@
}
else if ( CurrentCodecState() == EStateCodecPrepared )
{
- if ( iDatasink->DataSinkType() == KMccRtpSinkUid )
- {
- CMccRtpDataSink* dataSink =
- static_cast<CMccRtpDataSink*>( iDatasink );
-
- // For updating keep alive parameters
- TMccCodecInfoBuffer infoBuffer( iCodecInfo );
- dataSink->ConfigureL( infoBuffer, iRtpMediaClock );
- }
if ( CodecLoadingAllowed() )
{
// Load the codec
@@ -291,6 +288,15 @@
UpdateCodecInformationL( iCodecInfo );
}
+ else if ( iDatasink->DataSinkType() == KMccRtpSinkUid )
+ {
+ CMccRtpDataSink* dataSink =
+ static_cast<CMccRtpDataSink*>( iDatasink );
+
+ // For updating keep alive parameters
+ TMccCodecInfoBuffer infoBuffer( iCodecInfo );
+ dataSink->ConfigureL( infoBuffer );
+ }
}
else if ( CurrentCodecState() == EStateCodecLoaded ||
CurrentCodecState() == EStateCodecLoadedAndUpdating )
@@ -302,7 +308,7 @@
// For updating keep alive parameters
TMccCodecInfoBuffer infoBuffer( iCodecInfo );
- dataSink->ConfigureL( infoBuffer, iRtpMediaClock );
+ dataSink->ConfigureL( infoBuffer );
}
// Update codec info
SetCodecState( EStateCodecLoadedAndUpdating );
--- a/multimediacommscontroller/mmccsubcontroller/tsrc/ut_subcontroller/Inc/UT_CMCCSymSimpleDlStream.h Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccsubcontroller/tsrc/ut_subcontroller/Inc/UT_CMCCSymSimpleDlStream.h Wed Oct 13 14:59:15 2010 +0300
@@ -160,8 +160,6 @@
CMccTestEventHandler* iEventHandler;
CMccResourcePoolStub* iResources;
-
- CMccRtpMediaClock* iRtpMediaClock;
TUint32 iMccSessionId;
--- a/multimediacommscontroller/mmccsubcontroller/tsrc/ut_subcontroller/Inc/UT_CMccSymDlStream.h Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccsubcontroller/tsrc/ut_subcontroller/Inc/UT_CMccSymDlStream.h Wed Oct 13 14:59:15 2010 +0300
@@ -142,7 +142,6 @@
CMccResourcePoolStub* iResources;
CMccMultiplexer* iMultiPlexer;
- CMccRtpMediaClock* iRtpMediaClock;
TUint32 iMccSessionId;
--- a/multimediacommscontroller/mmccsubcontroller/tsrc/ut_subcontroller/Src/UT_CMCCSymSimpleDlStream.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccsubcontroller/tsrc/ut_subcontroller/Src/UT_CMCCSymSimpleDlStream.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -86,15 +86,13 @@
void UT_CMccSymSimpleDlStream::SetupL( )
{
- iRtpMediaClock = CMccRtpMediaClock::NewL();
-
iResources = CMccResourcePoolStub::NewL();
iEventHandler = CMccTestEventHandler::NewL();
iRtpManager = CMccRtpManager::NewL(*iEventHandler, *iResources, iMccSessionId );
iStreamId = 1;
CMccSymSimpleDlStream* stream = CMccSymSimpleDlStream::NewLC(
- iStreamId, this, iResources, iRtpManager, TFourCC(), KMccVideoDownlinkStream, *iRtpMediaClock );
+ iStreamId, this, iResources, iRtpManager, TFourCC(), KMccVideoDownlinkStream );
CleanupStack::Pop( stream );
iSimpleDlStream = stream;
stream = NULL;
@@ -133,12 +131,6 @@
delete iEventHandler;
delete iResources;
REComSession::FinalClose();
-
- if ( iRtpMediaClock )
- {
- delete iRtpMediaClock;
- iRtpMediaClock = NULL;
- }
}
void UT_CMccSymSimpleDlStream::UT_CMccSymSimpleDlStream_CreatePayloadFormatDecoderLL( )
--- a/multimediacommscontroller/mmccsubcontroller/tsrc/ut_subcontroller/Src/UT_CMccRtpKeepalive.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccsubcontroller/tsrc/ut_subcontroller/Src/UT_CMccRtpKeepalive.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -83,8 +83,6 @@
void UT_CMccRtpKeepalive::SetupL()
{
- iRtpMediaClock = CMccRtpMediaClock::NewL();
-
iEventHandler = CMccTestEventHandler::NewL();
iRtpApi = CRtpAPI::NewL( *iEventHandler );
TPckgBuf<TInt> params( 30000 );
@@ -94,15 +92,15 @@
TMccCodecInfo codecInfo;
TMccCodecInfoBuffer infoBuffer( codecInfo );
CMccRtpDataSource* dSource = static_cast<CMccRtpDataSource*>( iRtpSource );
- dSource->ConfigureL( infoBuffer, iRtpMediaClock );
+ dSource->ConfigureL( infoBuffer );
CMccRtpDataSink* dSink = static_cast<CMccRtpDataSink*>( iRtpSink );
- dSink->ConfigureL( infoBuffer, iRtpMediaClock );
+ dSink->ConfigureL( infoBuffer );
+
+ iRtpMediaClock = CMccRtpMediaClock::NewL();
}
void UT_CMccRtpKeepalive::Setup2L()
{
- iRtpMediaClock = CMccRtpMediaClock::NewL();
-
iEventHandler = CMccTestEventHandler::NewL();
iRtpApi = CRtpAPI::NewL( *iEventHandler );
TPckgBuf<TInt> params( 30000 );
@@ -112,10 +110,11 @@
TMccCodecInfo codecInfo;
TMccCodecInfoBuffer infoBuffer( codecInfo );
CMccRtpDataSource* dSource = static_cast<CMccRtpDataSource*>( iRtpSource );
- dSource->ConfigureL( infoBuffer, iRtpMediaClock );
+ dSource->ConfigureL( infoBuffer );
CMccRtpDataSink* dSink = static_cast<CMccRtpDataSink*>( iRtpSink );
- dSink->ConfigureL( infoBuffer, iRtpMediaClock );
+ dSink->ConfigureL( infoBuffer );
+ iRtpMediaClock = CMccRtpMediaClock::NewL();
iKeepaliveHandler =
CMccRtpKeepalive::NewL( *iEventHandler, *iRtpApi, TRtpId(), 96, 1000, KNullDesC8, ETrue );
@@ -178,11 +177,11 @@
EUNIT_ASSERT_EQUALS( container->RemoteAddressSet(), KErrNone );
// Update valid case
- MCC_EUNIT_ASSERT_NO_LEAVE( container->UpdateParamsL( *static_cast<CMccRtpDataSink*>( iRtpSink ), codecInfo, *iRtpMediaClock ) );
+ MCC_EUNIT_ASSERT_NO_LEAVE( container->UpdateParamsL( *static_cast<CMccRtpDataSink*>( iRtpSink ), codecInfo ) );
// Update with keealive interval 0
codecInfo.iKeepaliveInterval = 0;
- MCC_EUNIT_ASSERT_NO_LEAVE( container->UpdateParamsL( *static_cast<CMccRtpDataSink*>( iRtpSink ), codecInfo, *iRtpMediaClock ) );
+ MCC_EUNIT_ASSERT_NO_LEAVE( container->UpdateParamsL( *static_cast<CMccRtpDataSink*>( iRtpSink ), codecInfo ) );
// Stop keepalive
//
@@ -227,11 +226,11 @@
EUNIT_ASSERT_EQUALS( container->RemoteAddressSet(), KErrNone );
// Update valid case
- container->UpdateParamsL( *static_cast<CMccRtpDataSink*>( iRtpSink ), codecInfo, *iRtpMediaClock );
+ container->UpdateParamsL( *static_cast<CMccRtpDataSink*>( iRtpSink ), codecInfo );
// Update with keealive interval 0
codecInfo.iKeepaliveInterval = 0;
- container->UpdateParamsL( *static_cast<CMccRtpDataSink*>( iRtpSink ), codecInfo, *iRtpMediaClock );
+ container->UpdateParamsL( *static_cast<CMccRtpDataSink*>( iRtpSink ), codecInfo );
// Stop keepalive
@@ -338,7 +337,7 @@
CleanupStack::PushL( keepaliveHandler );
TUint8 keepalivePT(96);
- TUint32 keepaliveInterval(25000000);
+ TUint8 keepaliveInterval(25);
const TUint8 KAmrKeepAlivePayload[6] =
{
0xF4, 0x00, 0x00, 0x00, 0x00, 0x00
@@ -347,11 +346,11 @@
keepAliveData.Copy( KAmrKeepAlivePayload );
// Valid case
- EUNIT_ASSERT_LEAVE( keepaliveHandler->UpdateParamsL( keepalivePT, keepaliveInterval, keepAliveData, iRtpMediaClock ) );
+ EUNIT_ASSERT_LEAVE( keepaliveHandler->UpdateParamsL( keepalivePT, keepaliveInterval, keepAliveData ) );
// Wrong payload type
keepalivePT = 129;
- EUNIT_ASSERT_LEAVE( keepaliveHandler->UpdateParamsL( keepalivePT, keepaliveInterval, keepAliveData, iRtpMediaClock ) );
+ EUNIT_ASSERT_LEAVE( keepaliveHandler->UpdateParamsL( keepalivePT, keepaliveInterval, keepAliveData ) );
CleanupStack::PopAndDestroy( keepaliveHandler );
}
else
@@ -360,7 +359,7 @@
CMccRtpKeepalive::NewL( *iEventHandler, *iRtpApi, TRtpId(), 96, 1000, KNullDesC8, ETrue );
TUint8 keepalivePT(96);
- TUint32 keepaliveInterval(25000000);
+ TUint8 keepaliveInterval(25);
const TUint8 KAmrKeepAlivePayload[6] =
{
0xF4, 0x00, 0x00, 0x00, 0x00, 0x00
@@ -369,11 +368,11 @@
keepAliveData.Copy( KAmrKeepAlivePayload );
// Valid case
- MCC_EUNIT_ASSERT_NO_LEAVE( iKeepaliveHandler->UpdateParamsL( keepalivePT, keepaliveInterval, keepAliveData, iRtpMediaClock ) );
+ MCC_EUNIT_ASSERT_NO_LEAVE( iKeepaliveHandler->UpdateParamsL( keepalivePT, keepaliveInterval, keepAliveData ) );
// Wrong payload type
keepalivePT = 129;
- MCC_EUNIT_ASSERT_SPECIFIC_LEAVE( iKeepaliveHandler->UpdateParamsL( keepalivePT, keepaliveInterval, keepAliveData, iRtpMediaClock ), KErrArgument );
+ MCC_EUNIT_ASSERT_SPECIFIC_LEAVE( iKeepaliveHandler->UpdateParamsL( keepalivePT, keepaliveInterval, keepAliveData ), KErrArgument );
}
}
@@ -446,8 +445,8 @@
iKeepaliveHandler->iStatus = KErrNone;
iKeepaliveHandler->iCurrentState = CMccRtpKeepalive::ESending;
MCC_EUNIT_ASSERT_NO_LEAVE( iKeepaliveHandler->RunL() );
- EUNIT_ASSERT( iKeepaliveHandler->iCurrentState == CMccRtpKeepalive::ESendingPending );
- EUNIT_ASSERT( !iKeepaliveHandler->IsActive() );
+ EUNIT_ASSERT( iKeepaliveHandler->iCurrentState == CMccRtpKeepalive::EWaitingTimer );
+ EUNIT_ASSERT( iKeepaliveHandler->IsActive() );
// Completed in not supported state
iKeepaliveHandler->iStatus = KErrNone;
@@ -473,14 +472,12 @@
};
TBuf8<6> keepAliveData;
keepAliveData.Copy( KAmrKeepAlivePayload );
- EUNIT_ASSERT_LEAVE( iKeepaliveHandler->UpdateParamsL( keepalivePT, keepaliveInterval, keepAliveData, iRtpMediaClock ) );
+ EUNIT_ASSERT_LEAVE( iKeepaliveHandler->UpdateParamsL( keepalivePT, keepaliveInterval, keepAliveData ) );
// Send completion ok when not active anymore, timer is started
iKeepaliveHandler->Cancel();
iKeepaliveHandler->iStatus = KErrNone;
iKeepaliveHandler->iCurrentState = CMccRtpKeepalive::ESending;
- iKeepaliveHandler->iRtpMediaClock = iRtpMediaClock;
-
MCC_EUNIT_ASSERT_NO_LEAVE( iKeepaliveHandler->RunL() );
EUNIT_ASSERT( iKeepaliveHandler->iCurrentState == CMccRtpKeepalive::EWaitingTimer );
EUNIT_ASSERT( iKeepaliveHandler->IsActive() );
@@ -511,10 +508,10 @@
// Send completion ok when not active anymore, timer is started
iKeepaliveHandler->Cancel();
iKeepaliveHandler->iStatus = KErrNone;
- iKeepaliveHandler->iCurrentState = CMccRtpKeepalive::ESending;
+ iKeepaliveHandler->iCurrentState = CMccRtpKeepalive::ESending;
iKeepaliveHandler->RunL();
- EUNIT_ASSERT( iKeepaliveHandler->iCurrentState == CMccRtpKeepalive::ESendingPending );
- EUNIT_ASSERT( !iKeepaliveHandler->IsActive() );
+ EUNIT_ASSERT( iKeepaliveHandler->iCurrentState == CMccRtpKeepalive::EWaitingTimer );
+ EUNIT_ASSERT( iKeepaliveHandler->IsActive() );
// Completed in not supported state
iKeepaliveHandler->iStatus = KErrNone;
@@ -540,7 +537,7 @@
};
TBuf8<6> keepAliveData;
keepAliveData.Copy( KAmrKeepAlivePayload );
- MCC_EUNIT_ASSERT_NO_LEAVE( iKeepaliveHandler->UpdateParamsL( keepalivePT, keepaliveInterval, keepAliveData, iRtpMediaClock ) );
+ MCC_EUNIT_ASSERT_NO_LEAVE( iKeepaliveHandler->UpdateParamsL( keepalivePT, keepaliveInterval, keepAliveData ) );
// Send completion ok when not active anymore, timer is started
iKeepaliveHandler->Cancel();
--- a/multimediacommscontroller/mmccsubcontroller/tsrc/ut_subcontroller/Src/UT_CMccSymDlStream.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/mmccsubcontroller/tsrc/ut_subcontroller/Src/UT_CMccSymDlStream.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -35,7 +35,6 @@
#include "mccmultiplexer.h"
#include "mmcccryptocontext.h"
#include "mccjitterbuffer.h"
-#include "mccrtpmediaclock.h"
#include "mccunittestmacros.h"
@@ -84,13 +83,11 @@
// METHODS
void UT_CMccSymDlStream::SetupL()
{
- iRtpMediaClock = CMccRtpMediaClock::NewL();
-
iResources = CMccResourcePoolStub::NewL();
iStreamId = 1;
iHandler = CMccTestEventHandler::NewL();
iRtpMan = CMccRtpManager::NewL( *iHandler, *iResources, iMccSessionId );
- iStream = CMccSymDlStream::NewLC( iStreamId, iHandler, iResources, iRtpMan, 201, *iRtpMediaClock );
+ iStream = CMccSymDlStream::NewLC( iStreamId, iHandler, iResources, iRtpMan, 201 );
CleanupStack::Pop( iStream );
TPckgBuf<TInt> params( 30000 );
@@ -121,13 +118,11 @@
void UT_CMccSymDlStream::Setup2L()
{
- iRtpMediaClock = CMccRtpMediaClock::NewL();
-
iResources = CMccResourcePoolStub::NewL();
iStreamId = 1;
iHandler = CMccTestEventHandler::NewL();
iRtpMan = CMccRtpManager::NewL( *iHandler, *iResources, iMccSessionId );
- iStream = CMccSymDlStream::NewLC( iStreamId, iHandler, iResources, iRtpMan, 201, *iRtpMediaClock );
+ iStream = CMccSymDlStream::NewLC( iStreamId, iHandler, iResources, iRtpMan, 201 );
CleanupStack::Pop( iStream );
TPckgBuf<TInt> params( 30000 );
@@ -139,13 +134,11 @@
void UT_CMccSymDlStream::SetupIlbcL()
{
- iRtpMediaClock = CMccRtpMediaClock::NewL();
-
iResources = CMccResourcePoolStub::NewL();
iStreamId = 1;
iHandler = CMccTestEventHandler::NewL();
iRtpMan = CMccRtpManager::NewL( *iHandler, *iResources,iMccSessionId );
- iStream = CMccSymDlStream::NewLC( iStreamId, iHandler, iResources, iRtpMan, 201, *iRtpMediaClock );
+ iStream = CMccSymDlStream::NewLC( iStreamId, iHandler, iResources, iRtpMan, 201 );
CleanupStack::Pop( iStream );
TPckgBuf<TInt> params( 30000 );
@@ -192,12 +185,6 @@
delete iSourceStub;
delete iSinkStub;
delete iResources;
-
- if ( iRtpMediaClock )
- {
- delete iRtpMediaClock;
- iRtpMediaClock = NULL;
- }
}
void UT_CMccSymDlStream::UT_CMccSymDlStream_SetPrioritySettingsLL( )
--- a/multimediacommscontroller/tsrc/rtpsourcesinkstub/inc/mccrtpdatasource.h Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/tsrc/rtpsourcesinkstub/inc/mccrtpdatasource.h Wed Oct 13 14:59:15 2010 +0300
@@ -310,7 +310,7 @@
* @since Series 60 3.2
* Send jitter event through mcc rtp interface
*/
- void SendJitterEvent( TMccRtpEventDataExtended aEvent, TInt aError );
+ void SendJitterEvent( TMccRtpEventData aEvent, TInt aError );
protected: // Functions from base classes
--- a/multimediacommscontroller/tsrc/rtpsourcesinkstub/src/MccRtpDataSource_STUB.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/tsrc/rtpsourcesinkstub/src/MccRtpDataSource_STUB.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -516,7 +516,7 @@
// CMccRtpDataSource::SendJitterEvent()
// -----------------------------------------------------------------------------
//
-void CMccRtpDataSource::SendJitterEvent( TMccRtpEventDataExtended /*aEvent*/, TInt /*aError*/ )
+void CMccRtpDataSource::SendJitterEvent( TMccRtpEventData /*aEvent*/, TInt /*aError*/ )
{
}
--- a/multimediacommscontroller/tsrc/rtpsourcesinkstub/src/mccrtpinterface_stub.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/tsrc/rtpsourcesinkstub/src/mccrtpinterface_stub.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -92,7 +92,7 @@
// Configures the RTP source/sink
// -----------------------------------------------------------------------------
//
-void MMccRtpInterface::ConfigureL( const TDesC8& /*aConfig*/, CMccRtpMediaClock* /*aRtpMediaClock*/ )
+void MMccRtpInterface::ConfigureL( const TDesC8& /*aConfig*/ )
{
if ( KNullId == RtpStreamId() )
{
--- a/multimediacommscontroller/tsrc/stubs/src/mccrtpkeepalivecontainer_STUB.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommscontroller/tsrc/stubs/src/mccrtpkeepalivecontainer_STUB.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -166,7 +166,7 @@
// ---------------------------------------------------------------------------
//
void CMccRtpKeepaliveContainer::UpdateParamsL( MMccRtpInterface& aUser,
- const TMccCodecInfo& aCodecInfo, CMccRtpMediaClock& aRtpMediaClock )
+ const TMccCodecInfo& aCodecInfo )
{
}
--- a/multimediacommsengine/mmcesrv/group/mceserver.mmp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommsengine/mmcesrv/group/mceserver.mmp Wed Oct 13 14:59:15 2010 +0300
@@ -223,7 +223,7 @@
LIBRARY esock.lib
LIBRARY bafl.lib
LIBRARY estor.lib
-LIBRARY CommonEngine.lib
+LIBRARY commonengine.lib
LIBRARY commdb.lib
LIBRARY charconv.lib
LIBRARY sipclient.lib
@@ -240,6 +240,8 @@
LIBRARY platformenv.lib
LIBRARY flogger.lib
LIBRARY efsrv.lib
+LIBRARY extendedconnpref.lib
+LIBRARY netmeta.lib
// MACRO PLAT_SEC_TEST
--- a/multimediacommsengine/mmcesrv/mmceserver/src/mcelocaladdrresolver.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommsengine/mmcesrv/mmceserver/src/mcelocaladdrresolver.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -21,6 +21,7 @@
#include "mcelocaladdrresolver.h"
#include <es_sock.h>
#include <commdbconnpref.h>
+#include <extendedconnpref.h>
// -----------------------------------------------------------------------------
@@ -80,11 +81,11 @@
// as the related SIP profile has been registered using it and
// the synchronous RConnection::Start should return quickly and
// should not hang the whole MCE server process for too long
- TCommDbConnPref prefs;
- prefs.SetDialogPreference( ECommDbDialogPrefDoNotPrompt );
- prefs.SetDirection( ECommDbConnectionDirectionOutgoing );
- prefs.SetIapId( aIapId );
- connection.Start( prefs );
+ TConnPrefList prefList;
+ TExtendedConnPref preferences;
+ preferences.SetIapId( aIapId );
+ prefList.AppendL( &preferences );
+ connection.Start( prefList );
// Fetch the actual IAP ID from the started connection
_LIT( KIapIdSetting, "IAP\\Id" );
--- a/multimediacommsengine/mmcesrv/mmceserver/src/mcesipconnection.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommsengine/mmcesrv/mmceserver/src/mcesipconnection.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -623,8 +623,6 @@
session->Canceled();
}
}
-
- iSessionManager.Cleanup();
MCESRV_DEBUG("CMceSipConnection::ConnectionStateChanged, Exit")
}
--- a/multimediacommsengine/mmcesrv/mmceserver/tsrc/ut_server/group/UT_CMCEServer.mmp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommsengine/mmcesrv/mmceserver/tsrc/ut_server/group/UT_CMCEServer.mmp Wed Oct 13 14:59:15 2010 +0300
@@ -304,6 +304,8 @@
LIBRARY platformenv.lib
LIBRARY flogger.lib
LIBRARY efsrv.lib
+LIBRARY extendedconnpref.lib
+LIBRARY netmeta.lib
//For Qualitykit 4.05 upwards use:
CAPABILITY EUNIT_CAPS
--- a/multimediacommsengine/mmcesrv/mmceserver/tsrc/ut_server/src/UT_CMCESIPConnection.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommsengine/mmcesrv/mmceserver/tsrc/ut_server/src/UT_CMCESIPConnection.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -617,31 +617,7 @@
iConnection->ConnectionStateChanged( CSIPConnection::EUnavailable );
EUNIT_ASSERT( !iSipSession->Body()->iIsConnectionActive );
- //cleanup orphan session test
- CMceSipManager& manager = iServerCore->Manager();
- iIds.iProfileID = 1;
- iIds.iManagerType = KMceCSSIPSession;
- iIds.iDialogType = KMceDlgTypeInvite;
-
- CDesC8ArrayFlat* params = new (ELeave) CDesC8ArrayFlat( KMceArrayGranularity );
- CleanupStack::PushL( params );
- params->AppendL( _L8("User <user2@host>") );
- params->AppendL( _L8("User <user@host>") );
-
- iConnection->Connection().SetState( CSIPConnection::EActive );
- CMceCsSubSession* subsession =
- manager.CreateSubSessionL( *iSession, iIds, *params );
- CleanupStack::PushL( subsession );
-
- manager.AddOrphanSubSessionL(subsession);
- CleanupStack::Pop( subsession );
- EUNIT_ASSERT ( manager.OrphanSubSessionCount() == 1 );
-
- iConnection->Connection().SetState( CSIPConnection::EInactive );
- iConnection->ConnectionStateChanged( CSIPConnection::EInactive );
- EUNIT_ASSERT ( manager.OrphanSubSessionCount() == 0 );
-
- CleanupStack::PopAndDestroy();
+
}
--- a/multimediacommsengine/mmcesrv/mmceserver/tsrc/ut_server/stubs/src/sipprofile.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommsengine/mmcesrv/mmceserver/tsrc/ut_server/stubs/src/sipprofile.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -270,7 +270,7 @@
// -----------------------------------------------------------------------------
//
CSIPProfile::CSIPProfile(CSIPProfileRegistryBase* aRegistry):
- iSIPProfileRegistry(aRegistry), iEnabled(EFalse), iContextId(1)
+ iSIPProfileRegistry(aRegistry), iEnabled(EFalse)
{
}
--- a/multimediacommsengine/tsrc/mccstub/src/MmccCodecInformation.cpp Wed Sep 15 12:38:06 2010 +0300
+++ b/multimediacommsengine/tsrc/mccstub/src/MmccCodecInformation.cpp Wed Oct 13 14:59:15 2010 +0300
@@ -990,13 +990,3 @@
}
-TUint32 CMccCodecInformation::KeepAliveTimerMicroSecs() const
- {
- return iKeepAliveTimerMicroSecs;
- }
-TInt CMccCodecInformation::SetKeepAliveTimerMicroSecs( TUint32 aTimerValueMicroSecs )
- {
- iKeepAliveTimerMicroSecs = aTimerValueMicroSecs;
- return KErrNone;
- }
-
--- a/natplugins/natpcliprovisioningnatfwadapter/group/wpnatfwtraversaladapter.mmp Wed Sep 15 12:38:06 2010 +0300
+++ b/natplugins/natpcliprovisioningnatfwadapter/group/wpnatfwtraversaladapter.mmp Wed Oct 13 14:59:15 2010 +0300
@@ -55,7 +55,7 @@
USERINCLUDE ../loc
LIBRARY euser.lib
-LIBRARY provisioningengine.lib
+LIBRARY ProvisioningEngine.lib
LIBRARY centralrepository.lib
LIBRARY charconv.lib
LIBRARY cmmanager.lib