[Asterisk-video] video call work in one side

gergis.rasmy gergis.rasmy at gmail.com
Sun Jul 12 23:27:34 CDT 2009


i found this on google , it may solve the problem , i didn try it yet 

***********************************************************************
I have spent a couple of days with TANDBERG, Polycom & LifeSize video kit experimenting with Asterisk 1.6.1.0. I discovered two problems : 

1. Calls between TANDBERG kit didn't work - one side seemed to connect audio only, but the other end was dropping the call quite quickly. 

2. Calls where audio only (as above!) 

I found the first problem in a SIP ACK packet from the TANDBERG which containg the Session-Expires header. 

Session-Expires: 500; refresher=uac 

This caused a Warning from asterisk that it could not parse session-expires and was promptly follwed by a BYE packet. 

Out of exhasperation after trying many different configs, i looked closely at the actual source code in chan_sip.c and found a possible bug in the function parse_session_expires. As there is a space ater the 500; in the above packet, the back end of the function trying to match the 'refresher=' string was failing owing to a leading space. I inserted the following : 

p_se_hdr = ast_skip_blanks(p_se_hdr); 

ahead of 

ref_idx = strlen("refresher="); 

After a recompile, the TANDBERG's would now connect (still Audio only however). 

The answer to the video problem, i found in the function sip_result add_sdp 

If you look closely at the previous post, you will see a SIP/2.0 200 OK response after Trying. In here, m=video 0 RTP/AVP 34 

The 0 in this capability tels the other codec that video is not available, but it should be, as asterisk has already acknowledged this in the debugs (slighly higher up, two statements : 

Video is at 192.168.2.2 port 16002 
Adding video codec 0x80000 (h263) to SDP 

To fix this, i changed sip_result_add_sdp (about half way down the function) to the following : 

/* Ok, we need video. Let's add what we need for video and set codecs. 
Video is handled differently than audio since we can not transcode. */ 
if (needvideo) { 

/********************** CHANGE STARTS *****************/ 

/************************* 
Comment out the original code - which seems to be referencing the video destination port 
**************************/ 
/* ast_str_append(&m_video, 0, "m=video %d RTP/AVP", ntohs(vdest.sin_port)); */ 

/************************* 
Add This line to reference the video source port 
**************************/ 
ast_str_append(&m_video, 0, "m=video %d RTP/AVP", ntohs(vsin.sin_port)); 

/***************** CHANGE ENDS ******************/ 

/* Build max bitrate string */ 
if (p->maxcallbitrate) 
snprintf(bandwidth, sizeof(bandwidth), "b=CT:%d\r\n", p->maxcallbitrate); 
if (debug) 
ast_verbose("Video is at %s port %d\n", ast_inet_ntoa(p->ourip.sin_addr), ntohs(vsin.sin_port)); 
} 


Video is now working between all systems........ 

Hope this helps. 
************************************************************************************************
  ----- Original Message ----- 
  From: Jamie A. Stapleton 
  To: Development discussion of video media support in Asterisk 
  Sent: Thursday, June 25, 2009 8:49 AM
  Subject: Re: [Asterisk-video] video call work in one side


  Here is an email that I sent to digium yesterday.  Sound familiar?  

   

  I downgraded to Asterisk 1.4.25 in the hopes of getting video working 100%...  Still not there.  It appears that whenever the eyeBeam is the Caller, it cannot receive video AND whenever eyebeam is the Called, it cannot send video.  Hence, the echo Application does not work.  Any ideas?!?

   

        Audio
           
         Caller
        
        Aethra
       eyeBeam
       GXV3000
       
       Aethra
       N/A
       Yes
       Yes
       
        Calling
       eyeBeam
       Yes
       N/A
       Yes
       
       GXV3000
       Yes
       Yes
       N/A
       
           
        Video
           
         Caller
        
        Aethra
       eyeBeam
       GXV3000
       
       Aethra
       N/A
       No
       Yes
       
        Calling
       eyeBeam
       Yes
       No
       Yes
       
       GXV3000
       Yes
       No
       N/A
       

   

   

  From: asterisk-video-bounces at lists.digium.com [mailto:asterisk-video-bounces at lists.digium.com] On Behalf Of gmail
  Sent: Friday, June 26, 2009 9:42 AM
  To: asterisk-video at lists.digium.com
  Subject: [Asterisk-video] video call work in one side

   

  i have a problem in making video call from one X-lite softphone to another , after i dial from 3500 to 3501 extension , and i press start video on extension 3500 (the calling party) the video is recived by 3501, but in the same call when  i press start video on 3501 (the called party) no video is sent to 3500 , when i reverse the call - that is when i dial from 3501 to 3500 the matter is reversed and only 3500 (the called party) recive video , that's we can say that only the called part can recive the video,  here is my sip.conf file :

   

   

   

  [general]
  port = 5060
  bindaddr = 0.0.0.0
  pedantic=yes
  videosupport=yes

   


  [3500]
  type=friend
  secret=3500
  host=dynamic
  canreinvite=no
  context=default
  disallow=all
  allow=ulaw
  allow=alaw
  allow=speex
  allow=gsm
  allow=h261
  allow=h263
  allow=h263p

   

  [3501]
  type=friend
  secret=3501
  canreinvite=no
  host=dynamic
  context=default
  disallow=all
  allow=ulaw
  allow=alaw
  allow=speex
  allow=gsm
  allow=h261
  allow=h263
  allow=h263p



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


  _______________________________________________
  --Bandwidth and Colocation Provided by http://www.api-digital.com--

  asterisk-video mailing list
  To UNSUBSCRIBE or update options visit:
     http://lists.digium.com/mailman/listinfo/asterisk-video
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.digium.com/pipermail/asterisk-video/attachments/20090712/b56e2823/attachment-0001.htm 


More information about the asterisk-video mailing list