[MPlayer-dev-eng] [PATCH] RTMP seek support

Diego Biurrun diego at biurrun.de
Wed May 26 14:50:08 CEST 2010


On Tue, May 25, 2010 at 06:09:13PM -0700, Howard Chu wrote:
> Reimar Döffinger wrote:
>> On Sun, Mar 28, 2010 at 08:02:16PM -0700, Howard Chu wrote:
>>> As a followon to this patch
>>>   https://lists.mplayerhq.hu/pipermail/ffmpeg-devel/2010-March/086051.html
>>>
>>> this patch is needed for mplayer to support rtmp seek. (The ffmpeg
>>> patch just gets it working for ffplay.)
>>
>> You will have to make sure the stream is actually lavf, and even then
>> I'd like to think some more if this is not too hackish.
>> However, I think first we'd need a configure patch to actually allow
>> building with librtmp (or are you building against external FFmpeg?
>> Even in that case rtmpe etc. should probably be added to the list
>> of stream_ffmpeg formats so rtmpe:// works, not just ffmpeg://rtmpe://).
>
> Here's a patch for configure. It seems to be missing something though; if 
> building against an external FFmpeg then really this switch will have no  
> effect. Unless we decide to add the stream_rtmp.c as well. The code in 
> this email has gone a bit stale
>
> http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/2010-March/063988.html
>
> and would need to be updated.
>
> --- configure	(revision 31217)
> +++ configure	(working copy)
> @@ -252,6 +252,7 @@
>    --enable-nemesi        enable Nemesi Streaming Media [autodetect]
> +  --enable-librtmp       enable RTMPDump librtmp input [autodetect]

RTMPDump librtmp sounds redundant to me.

> @@ -7190,6 +7194,24 @@
>  
> +echocheck "RTMPDump RTMP support (librtmp)"
> +if test "$_librtmp" = auto  && test "$_network" = yes ; then
> +    _librtmp=no
> +    if $_pkg_config --exists librtmp ; then
> +        extra_cflags="$extra_cflags $($_pkg_config --cflags librtmp)"
> +        extra_ldflags="$extra_ldflags $($_pkg_config --libs librtmp)"
> +        _librtmp=yes

Can you make a simple check instead of relying on pkg-config?

> +if test "$_librtmp" = yes && test "$_network" = yes; then

You don't need to test _network again here.

The default indentation in configure is 2 spaces.

> @@ -8716,7 +8738,7 @@
>  
>  $mak_hardcoded_tables
>  $mak_libavcodec_mpegaudio_hp
> -!CONFIG_LIBRTMP = yes
> +CONFIG_LIBRTMP = $_librtmp
>  
>  CONFIG_BZLIB    = $bzlib
>  CONFIG_ENCODERS = yes
> @@ -9054,6 +9076,7 @@
>  $def_inet6
>  $def_inet_aton
>  $def_inet_pton
> +$def_librtmp
>  $def_live
>  $def_nemesi
>  $def_network
> @@ -9202,7 +9225,6 @@
>  #define CONFIG_FFSERVER 0
>  #define CONFIG_GPL 1
>  #define CONFIG_GRAY 0
> -#define CONFIG_LIBRTMP 0
>  #define CONFIG_LIBVORBIS 0
>  #define CONFIG_POWERPC_PERF 0
>  #define CONFIG_SMALL 0

IIUC librtmp is used through FFmpeg, so the def_librtmp variable should
be placed in the FFmpeg section of config.h.

Diego



More information about the MPlayer-dev-eng mailing list