コード例 #1
0
// ---------------------------------------------------------------------------
// From class CMccSymStreamBase.
// Starts the stream. DTMF can be now sent and received.
// ---------------------------------------------------------------------------
//
void CMccDtmfUlStream::PlayL( 
    const TUint32 aEndpointId, 
    TBool /*aStreamPaused*/, 
    TBool /*aEnableRtcp*/ )
    {
	__SUBCONTROLLER( "CMccDtmfUlStream::PlayL" )
    __ASSERT_ALWAYS( iFormatEncode && iDatasink && iDatasource, 
                     User::Leave( KErrNotReady ) );
	
    TBool controlNetworkResources = SetStateL( EStateStreaming, aEndpointId );
    
    if ( controlNetworkResources )
        {
        iRtpmanager->StartSessionL();
        }
    
    LoadCodecL( iCodecInfo, KNullDesC8 );
    
    if ( IsControlled( MCC_ENDPOINT_ID( iDatasink ) ) )
        {
        iFormatEncode->SinkPlayL();
        }
    
    if ( IsControlled( MCC_ENDPOINT_ID( iDatasource ) ) )
        {
        iDatasource->SourcePlayL();
        }

    InformStreamStateChange( KMccStreamStarted, aEndpointId );
    
	__SUBCONTROLLER( "CMccDtmfUlStream::PlayL, exit" )
    }
コード例 #2
0
// ---------------------------------------------------------------------------
// From class CMccSymStreamBase.
// Primes the stream ready.
// ---------------------------------------------------------------------------
//
void CMccDtmfUlStream::PrimeL( const TUint32 aEndpointId )
    {
	__SUBCONTROLLER( "CMccDtmfUlStream::PrimeL" )
    __ASSERT_ALWAYS( iFormatEncode && iDatasink && iDatasource, 
                     User::Leave( KErrNotReady ) );
	
    TBool controlNetworkResources = SetStateL( EStatePrepared, aEndpointId );  
    
    if ( controlNetworkResources )
        {
        iRtpmanager->CreateTransmitStreamL( *iDatasink, iCodecInfo );
        }
        
    LoadCodecL( iCodecInfo, KNullDesC8 );
    
    if ( IsControlled( MCC_ENDPOINT_ID( iDatasink ) ) )
        {
        iFormatEncode->SinkPrimeL();
        }
    
    if ( IsControlled( MCC_ENDPOINT_ID( iDatasource ) ) )
        {
        iDatasource->SourcePrimeL();
        }

    InformStreamStateChange( KMccStreamPrepared, aEndpointId );
    
	__SUBCONTROLLER( "CMccDtmfUlStream::PrimeL, exit" )
    }
コード例 #3
0
// ---------------------------------------------------------------------------
// From class CMccSymStreamBase.
// Stops the stream.
// ---------------------------------------------------------------------------
//
void CMccDtmfUlStream::StopL( const TUint32 aEndpointId )
    {
    __SUBCONTROLLER( "CMccDtmfUlStream::StopL" )
    __ASSERT_ALWAYS( iFormatEncode && iDatasink && iDatasource, 
                     User::Leave( KErrNotReady ) );
    
    SetStateL( EStateStopped, aEndpointId );
    
    if ( IsControlled( MCC_ENDPOINT_ID( iDatasink ) ) )
        {
        iFormatEncode->SinkStopL();
        }
    
    if ( IsControlled( MCC_ENDPOINT_ID( iDatasource ) ) )
        {
        iDatasource->SourceStopL();
        }
    
    InformStreamStateChange( KMccStreamStopped, aEndpointId );
    
    __SUBCONTROLLER( "CMccDtmfUlStream::StopL, exit" )
    }
コード例 #4
0
// ---------------------------------------------------------------------------
// From class CMccSymStreamBase.
// Resumes the stream.
// ---------------------------------------------------------------------------
//
void CMccDtmfUlStream::ResumeL( const TUint32 aEndpointId, TBool /*aEnableRtcp*/ )
    {
    __SUBCONTROLLER( "CMccDtmfUlStream::ResumeL" )
    __ASSERT_ALWAYS( iFormatEncode && iDatasink && iDatasource, 
                     User::Leave( KErrNotReady ) );
    
    SetStateL( EStateStreaming, aEndpointId );
    
    if ( IsControlled( MCC_ENDPOINT_ID( iDatasink ) ) )
        {
        iFormatEncode->SinkPlayL();
        }
    
    if ( IsControlled( MCC_ENDPOINT_ID( iDatasource ) ) )
        {
        iDatasource->SourcePlayL();
        }
    
    InformStreamStateChange( KMccStreamResumed, aEndpointId );

    __SUBCONTROLLER( "CMccDtmfUlStream::ResumeL, exit" )
    }
コード例 #5
0
ファイル: ui_h.cpp プロジェクト: dhk-room101/da2ue4
int32 UI_CheckDisplayMask(int32 nMessage, AActor* oTarget)
{
	int32 nDispMask = GetM2DAInt(TABLE_UI_MESSAGES, "DisplayMask", nMessage);


	if (nDispMask != 0)
	{
		int32 bShow = ((nDispMask & UI_DISPLAY_MASK_ALL) == UI_DISPLAY_MASK_ALL);

		if (!bShow)
		{
			int32 bPlayer = IsControlled(oTarget);
			int32 bParty = IsFollower(oTarget);
			int32 bHostile = IsObjectHostile(GetHero(), oTarget);

			bShow = ((nDispMask & UI_DISPLAY_MASK_PLAYER) == UI_DISPLAY_MASK_PLAYER) && bPlayer;
			bShow = bShow || (((nDispMask & UI_DISPLAY_MASK_PARTY) == UI_DISPLAY_MASK_PARTY) && bParty);
			bShow = bShow || (((nDispMask & UI_DISPLAY_MASK_HOSTILE) == UI_DISPLAY_MASK_HOSTILE) && bParty);
		}

		return bShow;
	}
	return FALSE_;
}