[MPlayer-users] Playing a file being downloaded until the end

Ilja Sekler ilja_sekler_ at gmx.de
Mon Aug 13 15:58:31 CEST 2012


Am 12.08.2012 20:04, schrieb Reimar Döffinger:

> See my reply in the thread "[PATCH] Fix the handling of growing files"
> from March this year.
> I'll attach the patch for convenience.
> The thing I am lacking is people who will test it thoroughly, because I
> don't really have time for that.

Was it intended to be

+        stream_control(demuxer->stream, STREAM_CTRL_GET_SIZE, &size);

instead of

+        stream_control(muxer->stream, STREAM_CTRL_GET_SIZE, &size)

in the libmpdemux/demux_lavf.c chunk of the attached patch? Otherwise
the MPlayer compilation fails with


cc -MD -MP -Wundef -Wall -Wno-switch -Wno-parentheses -Wpointer-arith
-Wredundant-decls -Wstrict-prototypes -Wmissing-prototypes
-Wdisabled-optimization -Wno-pointer-sign -Wdeclaration-after-statement
-std=gnu99 -Werror-implicit-function-declaration -O4 -march=native
-mtune=native -pipe -ffast-math -fomit-frame-pointer -fno-tree-vectorize
-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE
-Ilibdvdread4 -I. -Iffmpeg  -fpie -DPIC -D_REENTRANT   -D_REENTRANT
-I/usr/include/freetype2 -c -o libmpdemux/demux_lavf.o
libmpdemux/demux_lavf.c
libmpcodecs/vf_screenshot.c: In function 'write_png':
libmpcodecs/vf_screenshot.c:98:5: warning: 'avcodec_encode_video' is
deprecated (declared at ffmpeg/libavcodec/avcodec.h:4226)
[-Wdeprecated-declarations]
libmpcodecs/vf_screenshot.c: In function 'scale_image':
libmpcodecs/vf_screenshot.c:136:5: warning: passing argument 2 of
'sws_scale' from incompatible pointer type [enabled by default]
In file included from libmpcodecs/vf_screenshot.c:40:0:
ffmpeg/libswscale/swscale.h:213:5: note: expected 'const uint8_t *
const*' but argument is of type 'unsigned char **'
libmpcodecs/vf_screenshot.c: In function 'draw_slice':
libmpcodecs/vf_screenshot.c:159:9: warning: passing argument 2 of
'sws_scale' from incompatible pointer type [enabled by default]
In file included from libmpcodecs/vf_screenshot.c:40:0:
ffmpeg/libswscale/swscale.h:213:5: note: expected 'const uint8_t *
const*' but argument is of type 'unsigned char **'
libmpdemux/demux_lavf.c: In function 'mp_seek':
libmpdemux/demux_lavf.c:110:24: error: 'muxer' undeclared (first use in
this function)
libmpdemux/demux_lavf.c:110:24: note: each undeclared identifier is
reported only once for each function it appears in
libmpdemux/demux_lavf.c:111:9: error: expected ';' before 'if'
cc -MD -MP -Wundef -Wall -Wno-switch -Wno-parentheses -Wpointer-arith
-Wredundant-decls -Wstrict-prototypes -Wmissing-prototypes
-Wdisabled-optimization -Wno-pointer-sign -Wdeclaration-after-statement
-std=gnu99 -Werror-implicit-function-declaration -O4 -march=native
-mtune=native -pipe -ffast-math -fomit-frame-pointer -fno-tree-vectorize
-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE
-Ilibdvdread4 -I. -Iffmpeg  -fpie -DPIC -D_REENTRANT   -D_REENTRANT
-I/usr/include/freetype2 -c -o stream/stream_ffmpeg.o stream/stream_ffmpeg.c
make: *** [libmpdemux/demux_lavf.o] Fehler 1


If I make the compiler happy as described above, the resulting patched
MPlayer works at least with growing files from youtube-dl flawlessly,
which unpatched MPlayer does not. Will test more.

Thanks,

-- 
Regards

Ilja


More information about the MPlayer-users mailing list