[MPlayer-dev-eng] [PATCH] - minor RTP fixes

Bertrand Baudet bertrand_baudet at yahoo.com
Thu Jan 10 02:26:25 CET 2002


Applied, thanks.

Bertrand

On Wednesday 09 January 2002 09:37 am, you wrote:
> The streaming RTP feature included in MPlayer-0.60 had
> a few bugs which are fixed by this patch.
>
> Brian
>
> ---------------------
>
> diff -w -r -u MPlayer-0.60/libmpdemux/network.c
> mplayer/main.fixed/libmpdemux/network.c
> --- MPlayer-0.60/libmpdemux/network.c   Tue Dec 25
> 08:35:57 2001
> +++ mplayer/main.fixed/libmpdemux/network.c     Wed
> Jan  9 09:18:37 2002
> @@ -468,7 +468,7 @@
>  int
>  rtp_open_socket( URL_t *url ) {
>         int fd;
> -       int socket_server_fd;
> +       int socket_server_fd, rxsockbufsz;
>         int err, err_len;
>         fd_set set;
>         struct timeval tv;
> @@ -504,6 +504,12 @@
>                         return -1;
>                 }
>         }
> +       /* Increase the socket rx buffer size to
> maximum -- this is UDP */
> +       rxsockbufsz = 240 * 1024;
> +       if( setsockopt( socket_server_fd, SOL_SOCKET,
> SO_RCVBUF, &rxsockbufsz, sizeof(rxsockbufsz))) {
> +               perror("Couldn't set receive socket
> buffer size");
> +       }
> +
>         if((ntohl(server_address.sin_addr.s_addr) >>
> 28) == 0xe) {
>                 mcast.imr_multiaddr.s_addr =
> server_address.sin_addr.s_addr;
>                 //mcast.imr_interface.s_addr =
> inet_addr("10.1.1.2");
> @@ -552,6 +558,7 @@
>         }
>
>         streaming_ctrl->streaming_read =
> rtp_streaming_read;
> +       streaming_ctrl->streaming_seek =
> nop_streaming_seek;
>         streaming_ctrl->prebuffer_size = 180000;
>         streaming_ctrl->buffering = 0; //1;
>         streaming_ctrl->status = streaming_playing_e;
> @@ -575,7 +582,7 @@
>         // For RTP streams, we usually don't know the
> stream type until we open it.
>         if( !strcmp( url->protocol, "rtp"))
>         {
> -               stream->fd = rtp_streaming_start(
> stream );
> +               ret = stream->fd =
> rtp_streaming_start( stream );
>         }
>         // For connection-oriented streams, we can
> usually determine the streaming type.
>         else
>
>
> __________________________________________________
> Do You Yahoo!?
> Send FREE video emails in Yahoo! Mail!
> http://promo.yahoo.com/videomail/
> _______________________________________________
> MPlayer-dev-eng mailing list
> MPlayer-dev-eng at mplayerhq.hu
> http://mplayerhq.hu/mailman/listinfo/mplayer-dev-eng

_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com




More information about the MPlayer-dev-eng mailing list