[FFmpeg-user] Which videoc codec gives best compression for screen recording?

Tobias Rapp t.rapp at noa-audio.com
Thu Nov 13 12:10:02 CET 2014


On 13.11.2014 11:44, Carl Eugen Hoyos wrote:
> Tobias Rapp writes:
>
>> I want to do screen recording with FFmpeg (on Windows).
>> It works fine with "gdigrab" but the output file size
>> is quite high.
>
> Command line and complete, uncut console output missing /
> which encoders did you already test?

I tested FLV and MP4, see attached log.

>> Maybe anybody has created a nice MP4 profile for it?
>
> I don't think the container has any relevance for the
> file size and the best encoders may not work with mov.

I meant a x264 profile but now I realize that the binary I use doesn't 
include this codec. Will get an updated one.

Regards,
Tobias
-------------- next part --------------
ffmpeg version 2.4.2 Copyright (c) 2000-2014 the FFmpeg developers
  built on Oct 16 2014 12:59:03 with gcc 4.8 (GCC)
  configuration: --disable-static --enable-shared --disable-debug --enable-version3 --disable-w32threads --arch=x86 --target-os=mingw32 --cross-prefix=i686-w64-mingw32- --prefix=/usr/local/win32 --enable-runtime-cpudetect --enable-memalign-hack
  libavutil      54.  7.100 / 54.  7.100
  libavcodec     56.  1.100 / 56.  1.100
  libavformat    56.  4.101 / 56.  4.101
  libavdevice    56.  0.100 / 56.  0.100
  libavfilter     5.  1.100 /  5.  1.100
  libswscale      3.  0.100 /  3.  0.100
  libswresample   1.  1.100 /  1.  1.100
[gdigrab @ 01dda880] Capturing whole desktop as 1920x1080x32 at (0,0)
Input #0, gdigrab, from 'desktop':
  Duration: N/A, start: 1415876568.549668, bitrate: 398133 kb/s
    Stream #0:0: Video: bmp, bgra, 1920x1080, 398133 kb/s, 6 tbr, 1000k tbn, 6 tbc
Output #0, flv, to 'desktop-rec1.flv':
  Metadata:
    encoder         : Lavf56.4.101
    Stream #0:0: Video: flv1 (flv) ([2][0][0][0] / 0x0002), yuv420p, 1920x1080, q=2-31, 200 kb/s, 6 fps, 1k tbn, 6 tbc
    Metadata:
      encoder         : Lavc56.1.100 flv
Stream mapping:
  Stream #0:0 -> #0:0 (bmp (native) -> flv1 (flv))
Press [q] to stop, [?] for help
frame=    4 fps=0.0 q=6.6 size=     893kB time=00:00:00.66 bitrate=10969.8kbits/s    
frame=    7 fps=6.9 q=14.6 size=     896kB time=00:00:01.16 bitrate=6291.4kbits/s    
frame=   10 fps=6.6 q=23.4 size=     899kB time=00:00:01.66 bitrate=4419.4kbits/s    
frame=   13 fps=6.4 q=24.8 size=    1136kB time=00:00:02.16 bitrate=4293.8kbits/s    
frame=   16 fps=6.3 q=31.0 size=    1139kB time=00:00:02.66 bitrate=3499.2kbits/s    
frame=   19 fps=6.3 q=31.0 size=    1142kB time=00:00:03.16 bitrate=2954.7kbits/s    
frame=   22 fps=6.2 q=31.0 size=    1145kB time=00:00:03.66 bitrate=2558.7kbits/s    
frame=   25 fps=6.2 q=24.8 size=    1382kB time=00:00:04.16 bitrate=2716.6kbits/s    
frame=   28 fps=6.2 q=31.0 size=    1385kB time=00:00:04.66 bitrate=2431.5kbits/s    
frame=   31 fps=6.1 q=31.0 size=    1388kB time=00:00:05.16 bitrate=2201.1kbits/s    
frame=   34 fps=6.1 q=31.0 size=    1391kB time=00:00:05.66 bitrate=2011.3kbits/s    
frame=   37 fps=6.1 q=24.8 size=    1628kB time=00:00:06.16 bitrate=2162.4kbits/s    
frame=   40 fps=6.1 q=31.0 size=    1631kB time=00:00:06.66 bitrate=2004.4kbits/s    
frame=   43 fps=6.1 q=31.0 size=    1634kB time=00:00:07.16 bitrate=1868.1kbits/s    
frame=   46 fps=6.1 q=31.0 size=    1637kB time=00:00:07.66 bitrate=1749.5kbits/s    
frame=   49 fps=6.1 q=24.8 size=    1874kB time=00:00:08.16 bitrate=1879.7kbits/s    
frame=   53 fps=6.2 q=31.0 size=    1878kB time=00:00:08.83 bitrate=1742.0kbits/s    
frame=   56 fps=6.2 q=31.0 size=    1881kB time=00:00:09.33 bitrate=1651.4kbits/s    
frame=   59 fps=6.1 q=31.0 size=    1884kB time=00:00:09.83 bitrate=1570.0kbits/s    
frame=   60 fps=6.0 q=31.0 Lsize=    1885kB time=00:00:10.00 bitrate=1544.6kbits/s    

video:1884kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.060688%
-------------- next part --------------
ffmpeg version 2.4.2 Copyright (c) 2000-2014 the FFmpeg developers
  built on Oct 16 2014 12:59:03 with gcc 4.8 (GCC)
  configuration: --disable-static --enable-shared --disable-debug --enable-version3 --disable-w32threads --arch=x86 --target-os=mingw32 --cross-prefix=i686-w64-mingw32- --prefix=/usr/local/win32 --enable-runtime-cpudetect --enable-memalign-hack
  libavutil      54.  7.100 / 54.  7.100
  libavcodec     56.  1.100 / 56.  1.100
  libavformat    56.  4.101 / 56.  4.101
  libavdevice    56.  0.100 / 56.  0.100
  libavfilter     5.  1.100 /  5.  1.100
  libswscale      3.  0.100 /  3.  0.100
  libswresample   1.  1.100 /  1.  1.100
[gdigrab @ 007ea880] Capturing whole desktop as 1920x1080x32 at (0,0)
Input #0, gdigrab, from 'desktop':
  Duration: N/A, start: 1415876597.363668, bitrate: 398133 kb/s
    Stream #0:0: Video: bmp, bgra, 1920x1080, 398133 kb/s, 6 tbr, 1000k tbn, 6 tbc
Output #0, mp4, to 'desktop-rec2.mp4':
  Metadata:
    encoder         : Lavf56.4.101
    Stream #0:0: Video: mpeg4 ( [0][0][0] / 0x0020), yuv420p, 1920x1080, q=2-31, 200 kb/s, 6 fps, 12288 tbn, 6 tbc
    Metadata:
      encoder         : Lavc56.1.100 mpeg4
Stream mapping:
  Stream #0:0 -> #0:0 (bmp (native) -> mpeg4 (native))
Press [q] to stop, [?] for help
frame=    4 fps=0.0 q=6.3 size=     827kB time=00:00:00.66 bitrate=10165.1kbits/s    
frame=    7 fps=6.9 q=14.3 size=     830kB time=00:00:01.16 bitrate=5830.2kbits/s    
frame=   10 fps=6.6 q=23.1 size=     833kB time=00:00:01.66 bitrate=4096.3kbits/s    
frame=   13 fps=6.4 q=24.8 size=    1039kB time=00:00:02.16 bitrate=3928.8kbits/s    
frame=   16 fps=6.3 q=31.0 size=    1043kB time=00:00:02.66 bitrate=3205.6kbits/s    
frame=   19 fps=6.2 q=31.0 size=    1048kB time=00:00:03.16 bitrate=2709.8kbits/s    
frame=   22 fps=6.2 q=31.0 size=    1052kB time=00:00:03.66 bitrate=2349.3kbits/s    
frame=   25 fps=6.2 q=24.8 size=    1258kB time=00:00:04.16 bitrate=2473.1kbits/s    
frame=   28 fps=6.1 q=31.0 size=    1262kB time=00:00:04.66 bitrate=2215.8kbits/s    
frame=   31 fps=6.1 q=31.0 size=    1266kB time=00:00:05.16 bitrate=2007.8kbits/s    
frame=   34 fps=6.1 q=31.0 size=    1270kB time=00:00:05.66 bitrate=1836.4kbits/s    
frame=   37 fps=6.1 q=24.8 size=    1477kB time=00:00:06.16 bitrate=1961.7kbits/s    
frame=   40 fps=6.1 q=31.0 size=    1481kB time=00:00:06.66 bitrate=1819.9kbits/s    
frame=   43 fps=6.1 q=31.0 size=    1485kB time=00:00:07.16 bitrate=1697.5kbits/s    
frame=   46 fps=6.1 q=31.0 size=    1489kB time=00:00:07.66 bitrate=1591.1kbits/s    
frame=   50 fps=6.2 q=31.0 size=    1697kB time=00:00:08.33 bitrate=1668.3kbits/s    
frame=   53 fps=6.2 q=31.0 size=    1701kB time=00:00:08.83 bitrate=1577.6kbits/s    
frame=   56 fps=6.2 q=31.0 size=    1705kB time=00:00:09.33 bitrate=1496.7kbits/s    
frame=   59 fps=6.1 q=31.0 size=    1709kB time=00:00:09.83 bitrate=1423.9kbits/s    
frame=   60 fps=6.0 q=31.0 Lsize=    1712kB time=00:00:10.00 bitrate=1402.2kbits/s    

video:1711kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.064571%


More information about the ffmpeg-user mailing list