[asterisk-scf-commits] asterisk-scf/integration/media_rtp_pjmedia.git branch "telephony-events" created.

Commits to the Asterisk SCF project code repositories asterisk-scf-commits at lists.digium.com
Wed Jul 20 14:53:52 CDT 2011


branch "telephony-events" has been created
        at  e5b247f0d92bc0801604072720c0aeb596740553 (commit)

- Log -----------------------------------------------------------------
commit e5b247f0d92bc0801604072720c0aeb596740553
Author: Mark Michelson <mmichelson at digium.com>
Date:   Wed Jul 20 14:47:34 2011 -0500

    Initial changes to the RTP component to use Telephony events.
    
    These first changes are mostly geared toward infrastructure changes,
    especially the change to the allocate() method to create RTP sessions.

diff --git a/src/RTPSink.cpp b/src/RTPSink.cpp
index 03556f3..635e0fe 100644
--- a/src/RTPSink.cpp
+++ b/src/RTPSink.cpp
@@ -270,17 +270,27 @@ public:
 TelephonyEventSinkRTPImpl::TelephonyEventSinkRTPImpl()
     : mPriv(new TelephonyEventSinkRTPImplPriv) { }
 
-void TelephonyEventSinkRTPImpl::write(const AsteriskSCF::SessionCommunications::V1::TelephonyEventPtr&, const Ice::Current&)
+void TelephonyEventSinkRTPImpl::write_async(
+        const AsteriskSCF::SessionCommunications::V1::AMD_TelephonyEventSink_writePtr& cb,
+        const AsteriskSCF::SessionCommunications::V1::TelephonyEventPtr&,
+        const Ice::Current&)
 {
     //stub
+    cb->ice_response();
 }
 
-void TelephonyEventSinkRTPImpl::setSource(const AsteriskSCF::SessionCommunications::V1::TelephonyEventSourcePrx& source, const Ice::Current&)
+void TelephonyEventSinkRTPImpl::setSource_async(
+        const AsteriskSCF::SessionCommunications::V1::AMD_TelephonyEventSink_setSourcePtr& cb,
+        const AsteriskSCF::SessionCommunications::V1::TelephonyEventSourcePrx& source,
+        const Ice::Current&)
 {
     mPriv->mSource = source;
+    cb->ice_response();
 }
 
-AsteriskSCF::SessionCommunications::V1::TelephonyEventSourcePrx TelephonyEventSinkRTPImpl::getSource(const Ice::Current&)
+void TelephonyEventSinkRTPImpl::getSource_async(
+        const AsteriskSCF::SessionCommunications::V1::AMD_TelephonyEventSink_getSourcePtr& cb,
+        const Ice::Current&)
 {
-    return mPriv->mSource;
+    cb->ice_response(mPriv->mSource);
 }
diff --git a/src/RTPSink.h b/src/RTPSink.h
index b0ba355..d68e713 100644
--- a/src/RTPSink.h
+++ b/src/RTPSink.h
@@ -46,9 +46,17 @@ class TelephonyEventSinkRTPImpl : public AsteriskSCF::SessionCommunications::V1:
 {
 public:
     TelephonyEventSinkRTPImpl();
-    void write(const AsteriskSCF::SessionCommunications::V1::TelephonyEventPtr&, const Ice::Current&);
-    void setSource(const AsteriskSCF::SessionCommunications::V1::TelephonyEventSourcePrx&, const Ice::Current&);
-    AsteriskSCF::SessionCommunications::V1::TelephonyEventSourcePrx getSource(const Ice::Current&);
+    void write_async(
+            const AsteriskSCF::SessionCommunications::V1::AMD_TelephonyEventSink_writePtr& cb,
+            const AsteriskSCF::SessionCommunications::V1::TelephonyEventPtr&,
+            const Ice::Current&);
+    void setSource_async(
+            const AsteriskSCF::SessionCommunications::V1::AMD_TelephonyEventSink_setSourcePtr& cb,
+            const AsteriskSCF::SessionCommunications::V1::TelephonyEventSourcePrx&,
+            const Ice::Current&);
+    void getSource_async(
+            const AsteriskSCF::SessionCommunications::V1::AMD_TelephonyEventSink_getSourcePtr& cb,
+            const Ice::Current&);
 private:
     boost::shared_ptr<TelephonyEventSinkRTPImplPriv> mPriv;
 };
diff --git a/src/RTPSource.cpp b/src/RTPSource.cpp
index cb7ceb7..ffe8189 100644
--- a/src/RTPSource.cpp
+++ b/src/RTPSource.cpp
@@ -368,13 +368,19 @@ public:
 TelephonyEventSourceRTPImpl::TelephonyEventSourceRTPImpl()
     : mPriv(new TelephonyEventSourceRTPImplPriv) { }
 
-void TelephonyEventSourceRTPImpl::addSink(const AsteriskSCF::SessionCommunications::V1::TelephonyEventSinkPrx& sink, const Ice::Current&)
+void TelephonyEventSourceRTPImpl::addSink_async(
+        const AsteriskSCF::SessionCommunications::V1::AMD_TelephonyEventSource_addSinkPtr& cb,
+        const AsteriskSCF::SessionCommunications::V1::TelephonyEventSinkPrx& sink,
+        const Ice::Current&)
 {
     boost::unique_lock<boost::shared_mutex> lock(mPriv->mLock);
     mPriv->sinks.push_back(sink);
+    cb->ice_response();
 }
 
-AsteriskSCF::SessionCommunications::V1::TelephonyEventSinkSeq TelephonyEventSourceRTPImpl::getSinks(const Ice::Current&)
+void TelephonyEventSourceRTPImpl::getSinks_async(
+        const AsteriskSCF::SessionCommunications::V1::AMD_TelephonyEventSource_getSinksPtr& cb,
+        const Ice::Current&)
 {
-    return mPriv->sinks;
+    cb->ice_response(mPriv->sinks);
 }
diff --git a/src/RTPSource.h b/src/RTPSource.h
index a4db6e7..7549a51 100644
--- a/src/RTPSource.h
+++ b/src/RTPSource.h
@@ -50,8 +50,13 @@ class TelephonyEventSourceRTPImpl : public AsteriskSCF::SessionCommunications::V
 {
 public:
     TelephonyEventSourceRTPImpl();
-    void addSink(const AsteriskSCF::SessionCommunications::V1::TelephonyEventSinkPrx& sink, const Ice::Current&);
-    AsteriskSCF::SessionCommunications::V1::TelephonyEventSinkSeq getSinks(const Ice::Current&);
+    void addSink_async(
+            const AsteriskSCF::SessionCommunications::V1::AMD_TelephonyEventSource_addSinkPtr&,
+            const AsteriskSCF::SessionCommunications::V1::TelephonyEventSinkPrx& sink,
+            const Ice::Current&);
+    void getSinks_async(
+            const AsteriskSCF::SessionCommunications::V1::AMD_TelephonyEventSource_getSinksPtr&,
+            const Ice::Current&);
 private:
     boost::shared_ptr<TelephonyEventSourceRTPImplPriv> mPriv;
 };

commit fcb246d5c750b9e853f57a2daa5cf3082f4e6855
Author: Mark Michelson <mmichelson at digium.com>
Date:   Tue Jul 19 11:13:54 2011 -0500

    Make initial changes to RTP component so that it knows about options and outputs.

diff --git a/src/MediaRTPpjmedia.cpp b/src/MediaRTPpjmedia.cpp
index 6f59f07..9e3ca04 100644
--- a/src/MediaRTPpjmedia.cpp
+++ b/src/MediaRTPpjmedia.cpp
@@ -69,7 +69,7 @@ public:
     RTPMediaServiceImpl(const Ice::ObjectAdapterPtr&, const ReplicaPtr&,
 	const AsteriskSCF::Discovery::SmartProxy<RtpStateReplicatorPrx>&,
 	const ConfigurationServiceImplPtr&);
-    RTPSessionPrx allocate(const RTPServiceLocatorParamsPtr&, const Ice::Current&);
+    RTPSessionPrx allocate(const RTPServiceLocatorParamsPtr&, const RTPOptionsPtr&, RTPAllocationOutputsPtr&,  const Ice::Current&);
     pj_pool_factory *getPoolFactory() { return &mCachingPool.factory; };
 private:
     /**
@@ -436,11 +436,12 @@ RTPMediaServiceImpl::RTPMediaServiceImpl(const Ice::ObjectAdapterPtr& adapter, c
 /**
  * Implementation of the allocate method as defined in MediaRTPIf.ice
  */
-RTPSessionPrx RTPMediaServiceImpl::allocate(const RTPServiceLocatorParamsPtr& params, const Ice::Current&)
+RTPSessionPrx RTPMediaServiceImpl::allocate(const RTPServiceLocatorParamsPtr& params,
+        const RTPOptionsPtr& options, RTPAllocationOutputsPtr& outputs,  const Ice::Current&)
 {
     RTPSessionImplPtr session =
         new RTPSessionImpl(mAdapter, params, &mCachingPool.factory, mReplicaService, mStateReplicator,
-	    mConfigurationService);
+	    mConfigurationService, options, outputs);
     return session->getProxy();
 }
 
diff --git a/src/RTPSession.cpp b/src/RTPSession.cpp
index 05ce690..54e1d8e 100644
--- a/src/RTPSession.cpp
+++ b/src/RTPSession.cpp
@@ -136,7 +136,8 @@ public:
 RTPSessionImpl::RTPSessionImpl(const Ice::ObjectAdapterPtr& adapter, const RTPServiceLocatorParamsPtr& params,
     pj_pool_factory* factory, const ReplicaPtr& replicaService,
     const AsteriskSCF::Discovery::SmartProxy<RtpStateReplicatorPrx>& stateReplicator,
-    const ConfigurationServiceImplPtr& configurationService) : 
+    const ConfigurationServiceImplPtr& configurationService,
+    const RTPOptionsPtr& options, RTPAllocationOutputsPtr& outputs) : 
     mImpl(new RTPSessionImplPriv(adapter, params->formats, replicaService, stateReplicator))
 {
     /* Add ourselves to the ICE ASM so we can be used. */
@@ -182,12 +183,12 @@ RTPSessionImpl::RTPSessionImpl(const Ice::ObjectAdapterPtr& adapter, const RTPSe
     mImpl->mSessionStateItem->mIPv6 = params->ipv6;
 
     /* First up for our own stuff is... a source! Media needs to come from somewhere, you know. */
-    mImpl->mStreamSource = new StreamSourceRTPImpl(this, mImpl->mSessionStateItem->key);
+    mImpl->mStreamSource = new StreamSourceRTPImpl(this, mImpl->mSessionStateItem->key, options, outputs);
     mImpl->mStreamSourceProxy = StreamSourceRTPPrx::uncheckedCast(mImpl->mAdapter->addWithUUID(mImpl->mStreamSource));
     mImpl->mSessionStateItem->mSourceIdentity = mImpl->mStreamSourceProxy->ice_getIdentity();
 
     /* And for my next trick a place for us to send media out. */
-    mImpl->mStreamSink = new StreamSinkRTPImpl(this, mImpl->mSessionStateItem->key);
+    mImpl->mStreamSink = new StreamSinkRTPImpl(this, mImpl->mSessionStateItem->key, options, outputs);
     mImpl->mStreamSinkProxy = StreamSinkRTPPrx::uncheckedCast(mImpl->mAdapter->addWithUUID(mImpl->mStreamSink));
     mImpl->mSessionStateItem->mSinkIdentity = mImpl->mStreamSinkProxy->ice_getIdentity();
 
@@ -229,11 +230,16 @@ RTPSessionImpl::RTPSessionImpl(const Ice::ObjectAdapterPtr& adapter, pj_pool_fac
 	// TODO: This is also bad, something is using the port
     }
 
-    mImpl->mStreamSource = new StreamSourceRTPImpl(this, "");
+    // XXX Come back and figure out what if anything needs to be done here
+    // about the options and outputs.
+
+    RTPOptionsPtr options(new RTPOptions());
+    RTPAllocationOutputsPtr outputs(new RTPAllocationOutputs());
+    mImpl->mStreamSource = new StreamSourceRTPImpl(this, "", options, outputs);
     mImpl->mStreamSourceProxy =
         StreamSourceRTPPrx::uncheckedCast(mImpl->mAdapter->add(mImpl->mStreamSource, sourceIdentity));
 
-    mImpl->mStreamSink = new StreamSinkRTPImpl(this, "");
+    mImpl->mStreamSink = new StreamSinkRTPImpl(this, "", options, outputs);
     mImpl->mStreamSinkProxy = StreamSinkRTPPrx::uncheckedCast(mImpl->mAdapter->add(mImpl->mStreamSink, sinkIdentity));
 }
 
diff --git a/src/RTPSession.h b/src/RTPSession.h
index ed7861e..6f6eb59 100644
--- a/src/RTPSession.h
+++ b/src/RTPSession.h
@@ -47,7 +47,8 @@ public:
     RTPSessionImpl(const Ice::ObjectAdapterPtr&, const AsteriskSCF::Media::RTP::V1::RTPServiceLocatorParamsPtr&,
 	pj_pool_factory*, const AsteriskSCF::System::Component::V1::ReplicaPtr&, 
 	const AsteriskSCF::Discovery::SmartProxy<AsteriskSCF::Replication::MediaRTPPJMedia::V1::RtpStateReplicatorPrx>&,
-	const ConfigurationServiceImplPtr&);
+	const ConfigurationServiceImplPtr&, const AsteriskSCF::Media::RTP::V1::RTPOptionsPtr&,
+	AsteriskSCF::Media::RTP::V1::RTPAllocationOutputsPtr&);
     RTPSessionImpl(const Ice::ObjectAdapterPtr&, pj_pool_factory*, const Ice::Identity&, const Ice::Identity&,
 	const Ice::Identity&, Ice::Int, const AsteriskSCF::Media::V1::FormatSeq&, bool,
 	const ConfigurationServiceImplPtr&);
diff --git a/src/RTPSink.cpp b/src/RTPSink.cpp
index 7c65568..03556f3 100644
--- a/src/RTPSink.cpp
+++ b/src/RTPSink.cpp
@@ -44,8 +44,8 @@ public:
     /**
      * Constructor for our StreamSinkRTPImplPriv class.
      */
-    StreamSinkRTPImplPriv(const RTPSessionImplPtr&, const std::string&);
-
+    StreamSinkRTPImplPriv(const RTPSessionImplPtr&, const std::string&,
+            const RTPOptionsPtr& options, RTPAllocationOutputsPtr& outputs);
     /**
      * A structure containing outgoing pjmedia session data.
      */
@@ -60,25 +60,37 @@ public:
      * Stream sink state item.
      */
     RtpStreamSinkStateItemPtr mSinkStateItem;
+
+    /**
+     * Telephony Event Sink
+     */
+    TelephonyEventSinkRTPImplPtr mTelephonyEventSink;
 };
 
 /**
  * Constructor for the StreamSinkRTPImplPriv class.
  */
-StreamSinkRTPImplPriv::StreamSinkRTPImplPriv(const RTPSessionImplPtr& session, const string& sessionId) :
+StreamSinkRTPImplPriv::StreamSinkRTPImplPriv(const RTPSessionImplPtr& session, const string& sessionId,
+        const RTPOptionsPtr& options, RTPAllocationOutputsPtr& outputs) :
     mSession(session), mSinkStateItem(new RtpStreamSinkStateItem)
 {
     pjmedia_rtp_session_init(&mOutgoingSession, 0, pj_rand());
     mSinkStateItem->mSessionId = sessionId;
     mSinkStateItem->key = IceUtil::generateUUID();
     mSinkStateItem->mRemotePort = 0;
+
+    if (options->handleTelephonyEvents)
+    {
+        mTelephonyEventSink = new TelephonyEventSinkRTPImpl();
+    }
 };
 
 /**
  * Constructor for the StreamSinkRTPImpl class.
  */
-StreamSinkRTPImpl::StreamSinkRTPImpl(const RTPSessionImplPtr& session, const string& sessionId) :
-    mImpl(new StreamSinkRTPImplPriv(session, sessionId))
+StreamSinkRTPImpl::StreamSinkRTPImpl(const RTPSessionImplPtr& session, const string& sessionId,
+        const RTPOptionsPtr& options, RTPAllocationOutputsPtr& outputs) :
+    mImpl(new StreamSinkRTPImplPriv(session, sessionId, options, outputs))
 {
 }
 
@@ -248,3 +260,27 @@ RtpStreamSinkStateItemPtr StreamSinkRTPImpl::getStateItem()
 {
     return mImpl->mSinkStateItem;
 }
+
+class TelephonyEventSinkRTPImplPriv
+{
+public:
+    AsteriskSCF::SessionCommunications::V1::TelephonyEventSourcePrx mSource;
+};
+
+TelephonyEventSinkRTPImpl::TelephonyEventSinkRTPImpl()
+    : mPriv(new TelephonyEventSinkRTPImplPriv) { }
+
+void TelephonyEventSinkRTPImpl::write(const AsteriskSCF::SessionCommunications::V1::TelephonyEventPtr&, const Ice::Current&)
+{
+    //stub
+}
+
+void TelephonyEventSinkRTPImpl::setSource(const AsteriskSCF::SessionCommunications::V1::TelephonyEventSourcePrx& source, const Ice::Current&)
+{
+    mPriv->mSource = source;
+}
+
+AsteriskSCF::SessionCommunications::V1::TelephonyEventSourcePrx TelephonyEventSinkRTPImpl::getSource(const Ice::Current&)
+{
+    return mPriv->mSource;
+}
diff --git a/src/RTPSink.h b/src/RTPSink.h
index 3739362..b0ba355 100644
--- a/src/RTPSink.h
+++ b/src/RTPSink.h
@@ -21,7 +21,9 @@ class StreamSinkRTPImplPriv;
 class StreamSinkRTPImpl : public AsteriskSCF::Media::RTP::V1::StreamSinkRTP
 {
 public:
-    StreamSinkRTPImpl(const RTPSessionImplPtr&, const std::string&);
+    StreamSinkRTPImpl(const RTPSessionImplPtr&, const std::string&,
+            const AsteriskSCF::Media::RTP::V1::RTPOptionsPtr&,
+            AsteriskSCF::Media::RTP::V1::RTPAllocationOutputsPtr&);
     void write(const AsteriskSCF::Media::V1::FrameSeq&, const Ice::Current&);
     void setSource(const AsteriskSCF::Media::V1::StreamSourcePrx&, const Ice::Current&);
     AsteriskSCF::Media::V1::StreamSourcePrx getSource(const Ice::Current&);
@@ -37,3 +39,18 @@ private:
      */
     boost::shared_ptr<StreamSinkRTPImplPriv> mImpl;
 };
+
+class TelephonyEventSinkRTPImplPriv;
+
+class TelephonyEventSinkRTPImpl : public AsteriskSCF::SessionCommunications::V1::TelephonyEventSink
+{
+public:
+    TelephonyEventSinkRTPImpl();
+    void write(const AsteriskSCF::SessionCommunications::V1::TelephonyEventPtr&, const Ice::Current&);
+    void setSource(const AsteriskSCF::SessionCommunications::V1::TelephonyEventSourcePrx&, const Ice::Current&);
+    AsteriskSCF::SessionCommunications::V1::TelephonyEventSourcePrx getSource(const Ice::Current&);
+private:
+    boost::shared_ptr<TelephonyEventSinkRTPImplPriv> mPriv;
+};
+
+typedef IceUtil::Handle<TelephonyEventSinkRTPImpl> TelephonyEventSinkRTPImplPtr;
diff --git a/src/RTPSource.cpp b/src/RTPSource.cpp
index c7c9c58..cb7ceb7 100644
--- a/src/RTPSource.cpp
+++ b/src/RTPSource.cpp
@@ -53,7 +53,8 @@ public:
     /**
      * Constructor for our StreamSourceRTPImplPriv class.
      */
-    StreamSourceRTPImplPriv(const RTPSessionImplPtr&, const string&);
+    StreamSourceRTPImplPriv(const RTPSessionImplPtr&, const string&,
+            const RTPOptionsPtr&, RTPAllocationOutputsPtr&);
 
     /**
      * A structure containing incoming pjmedia session data.
@@ -71,6 +72,11 @@ public:
     RtpStreamSourceStateItemPtr mSourceStateItem;
 
     /**
+     * Telephony Event source
+     */
+    TelephonyEventSourceRTPImplPtr mTelephonyEventSource;
+
+    /**
      * Lock that protects information contained.
      */
     boost::shared_mutex mLock;
@@ -79,19 +85,26 @@ public:
 /**
  * Constructor for the StreamSourceRTPImplPriv class.
  */
-StreamSourceRTPImplPriv::StreamSourceRTPImplPriv(const RTPSessionImplPtr& session, const string& sessionId) :
+StreamSourceRTPImplPriv::StreamSourceRTPImplPriv(const RTPSessionImplPtr& session, const string& sessionId,
+        const RTPOptionsPtr& options, RTPAllocationOutputsPtr&) :
     mSession(session), mSourceStateItem(new RtpStreamSourceStateItem)
 {
     pjmedia_rtp_session_init(&mIncomingSession, 0, 0);
     mSourceStateItem->mSessionId = sessionId;
     mSourceStateItem->key = IceUtil::generateUUID();
+
+    if (options->handleTelephonyEvents)
+    {
+        mTelephonyEventSource = new TelephonyEventSourceRTPImpl();
+    }
 };
 
 /**
  * Constructor for the StreamSourceRTPImpl class.
  */
-StreamSourceRTPImpl::StreamSourceRTPImpl(const RTPSessionImplPtr& session, const string& sessionId) :
-    mImpl(new StreamSourceRTPImplPriv(session, sessionId))
+StreamSourceRTPImpl::StreamSourceRTPImpl(const RTPSessionImplPtr& session, const string& sessionId,
+        const RTPOptionsPtr& options, RTPAllocationOutputsPtr& outputs) :
+    mImpl(new StreamSourceRTPImplPriv(session, sessionId, options, outputs))
 {
 }
 
@@ -344,3 +357,24 @@ void StreamSourceRTPImpl::setSinks(const AsteriskSCF::Media::V1::StreamSinkSeq&
 
     mImpl->mSourceStateItem->mSinks = sinks;
 }
+
+class TelephonyEventSourceRTPImplPriv
+{
+public:
+    AsteriskSCF::SessionCommunications::V1::TelephonyEventSinkSeq sinks;
+    boost::shared_mutex mLock;
+};
+
+TelephonyEventSourceRTPImpl::TelephonyEventSourceRTPImpl()
+    : mPriv(new TelephonyEventSourceRTPImplPriv) { }
+
+void TelephonyEventSourceRTPImpl::addSink(const AsteriskSCF::SessionCommunications::V1::TelephonyEventSinkPrx& sink, const Ice::Current&)
+{
+    boost::unique_lock<boost::shared_mutex> lock(mPriv->mLock);
+    mPriv->sinks.push_back(sink);
+}
+
+AsteriskSCF::SessionCommunications::V1::TelephonyEventSinkSeq TelephonyEventSourceRTPImpl::getSinks(const Ice::Current&)
+{
+    return mPriv->sinks;
+}
diff --git a/src/RTPSource.h b/src/RTPSource.h
index f032f88..a4db6e7 100644
--- a/src/RTPSource.h
+++ b/src/RTPSource.h
@@ -21,7 +21,9 @@ class StreamSourceRTPImplPriv;
 class StreamSourceRTPImpl : public AsteriskSCF::Media::RTP::V1::StreamSourceRTP
 {
 public:
-    StreamSourceRTPImpl(const RTPSessionImplPtr&, const std::string&);
+    StreamSourceRTPImpl(const RTPSessionImplPtr&, const std::string&,
+            const AsteriskSCF::Media::RTP::V1::RTPOptionsPtr&,
+            AsteriskSCF::Media::RTP::V1::RTPAllocationOutputsPtr&);
     void addSink(const AsteriskSCF::Media::V1::StreamSinkPrx&, const Ice::Current&);
     void removeSink(const AsteriskSCF::Media::V1::StreamSinkPrx&, const Ice::Current&);
     AsteriskSCF::Media::V1::StreamSinkSeq getSinks(const Ice::Current&);
@@ -41,3 +43,17 @@ public:
      */
     boost::shared_ptr<StreamSourceRTPImplPriv> mImpl;
 };
+
+class TelephonyEventSourceRTPImplPriv;
+
+class TelephonyEventSourceRTPImpl : public AsteriskSCF::SessionCommunications::V1::TelephonyEventSource
+{
+public:
+    TelephonyEventSourceRTPImpl();
+    void addSink(const AsteriskSCF::SessionCommunications::V1::TelephonyEventSinkPrx& sink, const Ice::Current&);
+    AsteriskSCF::SessionCommunications::V1::TelephonyEventSinkSeq getSinks(const Ice::Current&);
+private:
+    boost::shared_ptr<TelephonyEventSourceRTPImplPriv> mPriv;
+};
+
+typedef IceUtil::Handle<TelephonyEventSourceRTPImpl> TelephonyEventSourceRTPImplPtr;
diff --git a/test/TestRTPpjmedia.cpp b/test/TestRTPpjmedia.cpp
index 212c58e..f057c83 100644
--- a/test/TestRTPpjmedia.cpp
+++ b/test/TestRTPpjmedia.cpp
@@ -434,8 +434,10 @@ BOOST_AUTO_TEST_CASE(AllocateRTPSession)
 
 	// You might think "geez, this should deadlock due to state replication" but no, we use one ways for that
 	boost::mutex::scoped_lock lock(Testbed.mLock);
-
-        Testbed.session = service->allocate(params);
+    
+        RTPOptionsPtr options(new RTPOptions());
+        RTPAllocationOutputsPtr outputs(new RTPAllocationOutputs());
+        Testbed.session = service->allocate(params, options, outputs);
 
 	// Give the RTP component time to replicate this session
 	Testbed.mCondition.wait(lock);
@@ -998,7 +1000,9 @@ BOOST_AUTO_TEST_CASE(ReceiveUnknownRTPPacket)
         FormatSeq formats;
         formats.push_back(format);
 
-        RTPSessionPrx session = service->allocate(params);
+        RTPOptionsPtr options(new RTPOptions());
+        RTPAllocationOutputsPtr outputs(new RTPAllocationOutputs());
+        RTPSessionPrx session = service->allocate(params, options, outputs);
 
         PayloadMap mapping;
         mapping.insert(make_pair(13, format));

-----------------------------------------------------------------------


-- 
asterisk-scf/integration/media_rtp_pjmedia.git



More information about the asterisk-scf-commits mailing list