Ticket #264 (closed defect: fixed)
Lossless x264 ffpresets fails on 32-bit
| Reported by: | llogan | Owned by: | |
|---|---|---|---|
| Priority: | normal | Component: | undetermined |
| Version: | git-master | Keywords: | |
| Cc: | Blocked By: | ||
| Blocking: | Reproduced by developer: | yes | |
| Analyzed by developer: | no |
Description
Recording x11grab with the below command works on x86_64 Arch Linux and Ubuntu Lucid, but fails with 32-bit Natty.
Looks like a regression:
b4bcd1e2f1d603419ea9d4fdaab400b1ad35e58c bad
7a88617c43ce534d94591dd78d4958333492b939 good
$ ffmpeg -v 9 -loglevel 99 -f x11grab -r 30 -s 320x240 -i :0.0 -vcodec libx264 -vpre lossless_ultrafast -threads 0 -y ~/output.mp4
ffmpeg version git-N-30011-gb4bcd1e, Copyright (c) 2000-2011 the FFmpeg developers
built on Jun 3 2011 13:51:23 with gcc 4.5.2
configuration: --enable-gpl --enable-libx264 --enable-x11grab --disable-doc
libavutil 51. 2. 1 / 51. 2. 1
libavcodec 53. 6. 0 / 53. 6. 0
libavformat 53. 1. 0 / 53. 1. 0
libavdevice 53. 0. 0 / 53. 0. 0
libavfilter 2. 5. 0 / 2. 5. 0
libswscale 0. 14. 0 / 0. 14. 0
libpostproc 51. 2. 0 / 51. 2. 0
[x11grab @ 0x9b0bb40] device: :0.0 -> display: :0.0 x: 0 y: 0 width: 320 height: 240
[x11grab @ 0x9b0bb40] shared memory extension found
[x11grab @ 0x9b0bb40] All info found
[x11grab @ 0x9b0bb40] Estimating duration from bitrate, this may be inaccurate
Input #0, x11grab, from ':0.0':
Duration: N/A, start: 1307138325.849861, bitrate: 73728 kb/s
Stream #0.0, 1, 1/1000000: Video: rawvideo, bgra, 320x240, 1/30, 73728 kb/s, 30 tbr, 1000k tbn, 30 tbc
Incompatible pixel format 'bgra' for codec 'libx264', auto-selecting format 'yuv420p'
[buffer @ 0x9afc880] w:320 h:240 pixfmt:bgra tb:1/1000000 sar:0/1
[ffsink @ 0x9afd940] auto-inserting filter 'auto-inserted scaler 0' between the filter 'src' and the filter 'out'
[scale @ 0x9afdc20] w:320 h:240 fmt:bgra -> w:320 h:240 fmt:yuv420p flags:0xa0000004
[libx264 @ 0x9affba0] --psnr used with psy on: results will be invalid!
[libx264 @ 0x9affba0] --tune psnr should be used if attempting to benchmark psnr!
[libx264 @ 0x9affba0] interlace + weightp is not implemented
[libx264 @ 0x9affba0] using mv_range_thread = 24
[libx264 @ 0x9affba0] using cpu capabilities: MMX2 SSE2Fast SSSE3 FastShuffle Cache64
[libx264 @ 0x9affba0] constant rate-factor is incompatible with 2pass.
Output #0, mp4, to '/home/lou/output.mp4':
Stream #0.0, 0, 1/90000: Video: libx264, yuv420p, 320x240, 1/30, q=0-69, pass 1, pass 2, 200 kb/s, 90k tbn, 30 tbc
Stream mapping:
Stream #0.0 -> #0.0
Error while opening encoder for output stream #0.0 - maybe incorrect parameters such as bit_rate, rate, width or height
However, re-encoding from a file and not x11grab seems to work as expected.
Change History
comment:2 Changed 2 years ago by cehoyos
- Status changed from new to open
Does not using libx264, but an internal encoder work?
Does using another (non-lossless) preset work?
If you believe this is a regression, please find the version
comment:3 Changed 2 years ago by verb3k
Other non-lossless presets and internal encoders have been reported to be working properly with x11grab. It only seems to be an issue with the lossless presets.
comment:5 Changed 2 years ago by llogan
Apparently it is now reproducible without x11grab, although I'm fairly sure I tested for this when I submitted the bug report:
$ ffmpeg -v 9 -loglevel 99 -i vbox/IronMan.mkv -vcodec libx264 -vpre lossless_ultrafast -threads 0 -an -y ~/output.mp4
ffmpeg version git-N-30773-g4ac5dff, Copyright (c) 2000-2011 the FFmpeg developers
built on Jun 14 2011 11:46:57 with gcc 4.5.2
configuration: --enable-gpl --enable-libx264 --enable-x11grab --disable-doc
libavutil 51. 8. 0 / 51. 8. 0
libavcodec 53. 7. 0 / 53. 7. 0
libavformat 53. 3. 1 / 53. 3. 1
libavdevice 53. 1. 1 / 53. 1. 1
libavfilter 2. 18. 0 / 2. 18. 0
libswscale 0. 14. 1 / 0. 14. 1
libpostproc 51. 2. 0 / 51. 2. 0
[NULL @ 0xaca2360] Format matroska,webm probed with size=2048 and score=100
st:0 removing common factor 1000000 from timebase
st:1 removing common factor 1000000 from timebase
[h264 @ 0xaca4fe0] Unsupported bit depth: 0
[h264 @ 0xaca4fe0] no picture
Last message repeated 1 times
[matroska,webm @ 0xaca2360] All info found
[matroska,webm @ 0xaca2360] Estimating duration from bitrate, this may be inaccurate
Seems stream 0 codec frame rate differs from container frame rate: 47.95 (10000000/208541) -> 23.98 (24000/1001)
Input #0, matroska,webm, from 'vbox/IronMan.mkv':
Duration: 00:01:48.50, start: 0.000000, bitrate: N/A
Stream #0.0, 43, 1/1000: Video: h264 (High), yuv420p, 1280x720, 208541/10000000, PAR 115:87 DAR 1840:783, 23.98 fps, 23.98 tbr, 1k tbn, 47.95 tbc (default)
Stream #0.1, 88, 1/1000: Audio: aac, 48000 Hz, stereo, s16 (default)
[buffer @ 0xad54960] w:1280 h:720 pixfmt:yuv420p tb:1/1000000 sar:115/87 sws_param:
[libx264 @ 0xaca1e80] --psnr used with psy on: results will be invalid!
[libx264 @ 0xaca1e80] --tune psnr should be used if attempting to benchmark psnr!
[libx264 @ 0xaca1e80] interlace + weightp is not implemented
[libx264 @ 0xaca1e80] using mv_range_thread = 56
[libx264 @ 0xaca1e80] using SAR=115/87
[libx264 @ 0xaca1e80] using cpu capabilities: MMX2 SSE2Fast SSSE3 FastShuffle Cache64
[libx264 @ 0xaca1e80] constant rate-factor is incompatible with 2pass.
Output #0, mp4, to '/home/lou/output.mp4':
Stream #0.0, 0, 1/90000: Video: libx264, yuv420p, 1280x720 [PAR 115:87 DAR 1840:783], 1001/24000, q=0-69, pass 1, pass 2, 200 kb/s, 90k tbn, 23.98 tbc (default)
Stream mapping:
Stream #0.0 -> #0.0
Error while opening encoder for output stream #0.0 - maybe incorrect parameters such as bit_rate, rate, width or height
comment:7 Changed 2 years ago by llogan
Yes, it still works as expected on 64 bit:
$ uname -a
Linux ubuntu 2.6.35-22-generic #33-Ubuntu SMP Sun Sep 19 20:32:27 UTC 2010 x86_64 GNU/Linux
$ ffmpeg -v 9 -loglevel 99 -i vbox/IronMan.mkv -vcodec libx264 -vpre lossless_ultrafast -threads 0 -t 1 -y ~/output.mp4
ffmpeg version git-N-30773-g4ac5dff, Copyright (c) 2000-2011 the FFmpeg developers
built on Jun 14 2011 15:28:46 with gcc 4.4.5
configuration: --enable-gpl --enable-libx264 --enable-x11grab
libavutil 51. 8. 0 / 51. 8. 0
libavcodec 53. 7. 0 / 53. 7. 0
libavformat 53. 3. 1 / 53. 3. 1
libavdevice 53. 1. 1 / 53. 1. 1
libavfilter 2. 18. 0 / 2. 18. 0
libswscale 0. 14. 1 / 0. 14. 1
libpostproc 51. 2. 0 / 51. 2. 0
[NULL @ 0x2b62440] Format matroska,webm probed with size=2048 and score=100
st:0 removing common factor 1000000 from timebase
st:1 removing common factor 1000000 from timebase
[h264 @ 0x2b659e0] Unsupported bit depth: 0
[h264 @ 0x2b659e0] no picture
Last message repeated 1 times
[matroska,webm @ 0x2b62440] All info found
[matroska,webm @ 0x2b62440] Estimating duration from bitrate, this may be inaccurate
Seems stream 0 codec frame rate differs from container frame rate: 47.95 (10000000/208541) -> 23.98 (24000/1001)
Input #0, matroska,webm, from 'vbox/IronMan.mkv':
Duration: 00:01:48.50, start: 0.000000, bitrate: N/A
Stream #0.0, 43, 1/1000: Video: h264 (High), yuv420p, 1280x720, 208541/10000000, PAR 115:87 DAR 1840:783, 23.98 fps, 23.98 tbr, 1k tbn, 47.95 tbc (default)
Stream #0.1, 88, 1/1000: Audio: aac, 48000 Hz, stereo, s16 (default)
[buffer @ 0x2c2b8e0] w:1280 h:720 pixfmt:yuv420p tb:1/1000000 sar:115/87 sws_param:
[libx264 @ 0x2bfffc0] using mv_range_thread = 56
[libx264 @ 0x2bfffc0] using SAR=115/87
[libx264 @ 0x2bfffc0] using cpu capabilities: MMX2 SSE2Fast SSSE3 FastShuffle Cache64
[libx264 @ 0x2bfffc0] profile High 4:4:4 Predictive, level 3.1, bit depth 8
[libx264 @ 0x2bfffc0] 64 - core 115 r1995 c1e60b9 - H.264/MPEG-4 AVC codec - Copyleft 2003-2011 - http://www.videolan.org/x264.html - options: cabac=0 ref=1 deblock=1:0:0 analyse=0x1:0 me=dia subme=0 psy=0 mixed_ref=0 me_range=16 chroma_me=1 trellis=0 8x8dct=0 cqm=0 deadzone=21,11 fast_pskip=0 chroma_qp_offset=0 threads=6 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=0 weightp=2 keyint=250 keyint_min=25 scenecut=40 intra_refresh=0 rc=cqp mbtree=0 qp=0
Output #0, mp4, to '/home/lou/output.mp4':
Metadata:
encoder : Lavf53.3.1
Stream #0.0, 0, 1/24000: Video: libx264, yuv420p, 1280x720 [PAR 115:87 DAR 1840:783], 1001/24000, q=0-69, 200 kb/s, 24k tbn, 23.98 tbc (default)
Stream #0.1, 0, 1/48000: Audio: aac, 48000 Hz, stereo, s16, 64 kb/s (default)
Stream mapping:
Stream #0.0 -> #0.0
Stream #0.1 -> #0.1
Press [q] to stop, [?] for help
[h264 @ 0x2b659e0] no picture
Last message repeated 1 times
[libx264 @ 0x2bfffc0] using mv_range_thread = 56
[libx264 @ 0x2bfffc0] frame= 0 QP=0.00 NAL=3 Slice:I Poc:0 I:3600 P:0 SKIP:0 size=485200 bytes
[libx264 @ 0x2bfffc0] frame= 1 QP=0.00 NAL=2 Slice:P Poc:2 I:857 P:2686 SKIP:57 size=397297 bytes
[libx264 @ 0x2bfffc0] frame= 2 QP=0.00 NAL=2 Slice:P Poc:4 I:730 P:2764 SKIP:106 size=398113 bytes
[libx264 @ 0x2bfffc0] frame= 3 QP=0.00 NAL=2 Slice:P Poc:6 I:772 P:2715 SKIP:113 size=372923 bytes
[libx264 @ 0x2bfffc0] frame= 4 QP=0.00 NAL=2 Slice:P Poc:8 I:824 P:2653 SKIP:123 size=398441 bytes
[libx264 @ 0x2bfffc0] frame= 5 QP=0.00 NAL=2 Slice:P Poc:10 I:1241 P:2318 SKIP:41 size=409354 bytes
[libx264 @ 0x2bfffc0] frame= 6 QP=0.00 NAL=2 Slice:P Poc:12 I:884 P:2621 SKIP:95 size=391488 bytes
[libx264 @ 0x2bfffc0] frame= 7 QP=0.00 NAL=2 Slice:P Poc:14 I:778 P:2647 SKIP:175 size=389523 bytes
[libx264 @ 0x2bfffc0] frame= 8 QP=0.00 NAL=2 Slice:P Poc:16 I:1351 P:2201 SKIP:48 size=418662 bytes
[libx264 @ 0x2bfffc0] frame= 9 QP=0.00 NAL=2 Slice:P Poc:18 I:2335 P:1234 SKIP:31 size=425439 bytes
[libx264 @ 0x2bfffc0] frame= 10 QP=0.00 NAL=2 Slice:P Poc:20 I:1260 P:2309 SKIP:31 size=393208 bytes
[libx264 @ 0x2bfffc0] frame= 11 QP=0.00 NAL=2 Slice:P Poc:22 I:1310 P:2245 SKIP:45 size=430263 bytes
[libx264 @ 0x2bfffc0] frame= 12 QP=0.00 NAL=2 Slice:P Poc:24 I:1243 P:2295 SKIP:62 size=422418 bytes
[libx264 @ 0x2bfffc0] frame= 13 QP=0.00 NAL=2 Slice:P Poc:26 I:1373 P:2181 SKIP:46 size=428948 bytes
[libx264 @ 0x2bfffc0] frame= 14 QP=0.00 NAL=2 Slice:P Poc:28 I:1874 P:1679 SKIP:47 size=409984 bytes
[libx264 @ 0x2bfffc0] frame= 15 QP=0.00 NAL=2 Slice:P Poc:30 I:1113 P:2469 SKIP:18 size=365771 bytes
[libx264 @ 0x2bfffc0] frame= 16 QP=0.00 NAL=2 Slice:P Poc:32 I:1106 P:2442 SKIP:52 size=384769 bytes
[libx264 @ 0x2bfffc0] frame= 17 QP=0.00 NAL=2 Slice:P Poc:34 I:1275 P:2288 SKIP:37 size=415174 bytes
[libx264 @ 0x2bfffc0] frame= 18 QP=0.00 NAL=2 Slice:P Poc:36 I:995 P:2537 SKIP:68 size=381085 bytes
[libx264 @ 0x2bfffc0] frame= 19 QP=0.00 NAL=2 Slice:P Poc:38 I:1159 P:2412 SKIP:29 size=390871 bytes
[libx264 @ 0x2bfffc0] frame= 20 QP=0.00 NAL=2 Slice:P Poc:40 I:796 P:2772 SKIP:32 size=367818 bytes
[libx264 @ 0x2bfffc0] frame= 21 QP=0.00 NAL=2 Slice:P Poc:42 I:933 P:2618 SKIP:49 size=388417 bytes
[libx264 @ 0x2bfffc0] frame= 22 QP=0.00 NAL=2 Slice:P Poc:44 I:808 P:2757 SKIP:35 size=362554 bytes
frame= 23 fps= 0 q=-1.0 Lsize= 9021kB time=00:00:00.95 bitrate=77036.8kbits/s
video:9012kB audio:7kB global headers:0kB muxing overhead 0.019013%
frame I:1 Avg QP: 0.00 size:485200
[libx264 @ 0x2bfffc0] frame P:22 Avg QP: 0.00 size:397387
[libx264 @ 0x2bfffc0] mb I I16..4: 50.0% 0.0% 50.0%
[libx264 @ 0x2bfffc0] mb P I16..4: 31.6% 0.0% 0.0% P16..4: 66.7% 0.0% 0.0% 0.0% 0.0% skip: 1.7%
[libx264 @ 0x2bfffc0] coded y,uvDC,uvAC intra: 74.9% 66.4% 66.1% inter: 94.1% 90.5% 90.3%
[libx264 @ 0x2bfffc0] i16 v,h,dc,p: 77% 22% 1% 0%
[libx264 @ 0x2bfffc0] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 44% 27% 2% 3% 7% 5% 5% 3% 3%
[libx264 @ 0x2bfffc0] i8c dc,h,v,p: 32% 25% 42% 0%
[libx264 @ 0x2bfffc0] Weighted P-Frames: Y:0.0% UV:0.0%
[libx264 @ 0x2bfffc0] kb/s:76954.45



This bug has been reported and confirmed by several users on ubuntuforums.org. It needs some developer attention as it is still reproducible. Please fix it, and thanks in advance.