mpv git-0067d1dbe (C) 2000-2016 mpv/MPlayer/mplayer2 projects
built on Sun Jan 1 11:58:48 CET 2017
ffmpeg library versions:
libavutil 55.43.100
libavcodec 57.70.100
libavformat 57.61.100
libswscale 4.3.101
libavfilter 6.68.100
libswresample 2.4.100
ffmpeg version: N-82927-gc6c888e996
https://0x0.st/pVG.jpg (slighly NSFW but it's the only sample I had)
mpv 1468861116228.jpg --loop=yes
I should see a muscular girl in the JPEG file
I hear industrial music instead
Passing --demuxer-lavf-hacks=no seems to mitigate the issue (as pointed out by tyng on IRC).
mpv 1468861116228.jpg --msg-level=ffmpeg=debug
Playing: 1468861116228.jpg
[ffmpeg] Probing jpeg_pipe score:6 size:2048
[ffmpeg] Probing jpeg_pipe score:6 size:4096
[ffmpeg] Probing jpeg_pipe score:6 size:8192
[ffmpeg] Probing jpeg_pipe score:6 size:16384
[ffmpeg] Probing jpeg_pipe score:6 size:32768
[ffmpeg] Probing jpeg_pipe score:6 size:65536
[ffmpeg] Probing mp3 score:25 size:98304
[ffmpeg] Probing mp3 score:25 size:98304
[ffmpeg/demuxer] mp3: Before avformat_find_stream_info() pos: 0 bytes read:1073905792 seeks:65543 nb_streams:1
[ffmpeg/audio] mp3: Header missing
[ffmpeg/audio] mp3: Header missing
[ffmpeg/audio] mp3: Header missing
[ffmpeg/audio] mp3: Header missing
[ffmpeg/audio] mp3: Header missing
[ffmpeg/audio] mp3: Header missing
[ffmpeg/audio] mp3: Header missing
[ffmpeg/demuxer] mp3: Estimating duration from bitrate, this may be inaccurate
[ffmpeg/demuxer] mp3: stream 0: start_time: 0.000 duration: 3.072
[ffmpeg/demuxer] mp3: format: start_time: 0.000 duration: 3.072 bitrate=256 kb/s
[ffmpeg/demuxer] mp3: After avformat_find_stream_info() pos: 98304 bytes read:1074004096 seeks:65543 frames:34
(+) Audio --aid=1 (mp3)
[ffmpeg/audio] mp3: Header missing
Error decoding audio.
[ffmpeg/audio] mp3: Header missing
Error decoding audio.
[ffmpeg/audio] mp3: Header missing
Error decoding audio.
[ffmpeg/audio] mp3: Header missing
Error decoding audio.
[ffmpeg/audio] mp3: Header missing
Error decoding audio.
[ffmpeg/audio] mp3: Header missing
Error decoding audio.
[ffmpeg/audio] mp3: Header missing
Error decoding audio.
AO: [alsa] 48000Hz stereo 2ch s16
[ffmpeg] SWR: Using s16p internally between filters
[ffmpeg] SWR: Using s16p internally between filters
A: 00:00:00 / 00:00:03 (7%) Cache: 0s+0KB
[ffmpeg/audio] mp3: overread, skip -6 enddists: -5 -5
A: 00:00:00 / 00:00:03 (13%) Cache: 0s+0KB
[ffmpeg/audio] mp3: overread, skip -6 enddists: -5 -5
A: 00:00:00 / 00:00:03 (21%) Cache: 0s+0KB
Exiting... (End of file)
For some reason, that file IS both, a JPEG and MP3.
That could be done in windows with something like this: copy /b someimage.jpg+someaudio.mp3 newimage.jpg and that plays directly in MPV as the MP3.
In linux is something like: cat someimage.jpg someaudio.mp3 > newimage.jpg. (I extracted the audio from that file and merged into another image to test, the same error log in the MPV)
It's rather unusual to discover that kind of files, but it's one way of "hide" files.
I thought the file was created by cutting the beginning of an mp3 containing cover art...
Very unusual file, I don't see the mp3 header anywhere.
If you only want the image, this does the trick:
dd if=/tmp/pVG.jpg of=/tmp/solo.jpg bs=69812 count=1
mp3 has no header, that鈥檚 the joke (and why ffmpeg and other software is so bad at detecting mp3 when there鈥檚 no id3 tag).
The main problem is IMHO that the ffmpeg mp3 prober is of bad quality full of nonsensical heuristics (instead of using heuristics that would hunt for "useful" features). It even detects ELF binaries as mp3.
Am I the only one for who this file gets detected as a JPEG?
That said, using dd if=pVG.jpg of=test.mp3 bs=1 skip=69812, the resulting file does play as an MP3 - although it's only 0.855 seconds in duration. What's more, it sounds like an actual song, and not garbled noise: https://0x0.st/fsH.mp3
I guess all this barely ontopic chatter is from "other" people from reddit.
So I deleted the chatter and locked the thread.
This is a bug tracker, not a forum.
I blame file systems and broken HBAs.
Most helpful comment
mp3 has no header, that鈥檚 the joke (and why ffmpeg and other software is so bad at detecting mp3 when there鈥檚 no id3 tag).