[OpenSIPS-Users] Modified SDP from RTPEngine

Răzvan Crainea razvan at opensips.org
Thu Mar 15 04:20:14 EDT 2018


Hi, Pat!

Take a look at the sock_pvar parameter of the rtpengine_offer() function[1].

[1] 
http://www.opensips.org/html/docs/modules/2.4.x/rtpengine.html#rtpengine.f.rtpengine_offer

Best regards,
Răzvan

On 03/15/2018 03:39 AM, Pat Burke wrote:
> Hello,
> 
> 
> I am trying to get the IP address of the RTPEngine selected by the 
> rtpengine_offer (we are load balancing across several rtpengines).  In 
> rtpproxy, there was the optional parameter
> 
>         /sock_pvar(optional)/ - pvar used to store the RTPProxy socket
>         chosen for this call. Note that the variable will only be
>         populated in the initial request.
> 
> 
> There is no equivalent in rtpengine.  The following code, gets reads the 
> request sdp line, but not the modified sdp.  Is there a way to get to 
> the modified sdp?
> 
> 
>                     rtpengine_offer("$dlg_val(rtpofferoptions)");
> 
>                      $var(regex) = "/c=IN IP4 //g";
> 
>                      $var(cline) = $(rb{sdp.line,c,0});
> 
>                      $var(ipaddr) = $(var(cline){re.subst,$var(regex)});
> 
>                      xlog("L_INFO", "$tU SCRIPT:RTPPROXY:DEBUG: response 
> = $var(response) - $var(ipaddr) - $rc\n");
> 
> 
> Regards,
> *Pat Burke*
> 
> 
> 
> _______________________________________________
> Users mailing list
> Users at lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
> 

-- 
Răzvan Crainea
OpenSIPS Core Developer
   http://www.opensips-solutions.com
OpenSIPS Summit 2018
   http://www.opensips.org/events/Summit-2018Amsterdam



More information about the Users mailing list