I am trying to convert .webm file that we get from google's screencastify to .mp4 file. I need it to be playable using Windows Media Player. I need it the file to be playing with all the WMP versions from last 3 years and on Windows XP and Win 7.
I am using a Ubuntu 14.04 container for the same.
I am using the following command:
ffmpeg -i in.webm -c:v libx264 -crf 20 -c:a aac -strict experimental out.mp4
Following are my observations:
The out.mp4 sometimes plays with the windows media player. At the time when it plays the time for conversion is less and file size is also normal.
Sometimes it just plays a black video. At that time it takes a lot of time for conversion.The file size in that case is also very high.
Longer videos do not play, shorter ones do. (Longer > 25 mins)
Console output:
ffmpeg version 1.2.6-7:1.2.6-1~trusty1 Copyright (c) 2000-2014 the FFmpeg developers
built on Apr 26 2014 18:52:58 with gcc 4.8 (Ubuntu 4.8.2-19ubuntu1)
configuration: --arch=amd64 --disable-stripping --enable-avresample --enable-pthreads --enable-runtime-cpudetect --extra-version='7:1.2.6-1~trusty1' --libdir=/usr/lib/x86_64-linux-gnu --prefix=/usr --enable-bzlib --enable-libdc1394 --enable-libfreetype --enable-frei0r --enable-gnutls --enable-libgsm --enable-libmp3lame --enable-librtmp --enable-libopencv --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-libschroedinger --enable-libspeex --enable-libtheora --enable-vaapi --enable-vdpau --enable-libvorbis --enable-libvpx --enable-zlib --enable-gpl --enable-postproc --enable-libcdio --enable-x11grab --enable-libx264 --shlibdir=/usr/lib/x86_64-linux-gnu --enable-shared --disable-static
libavutil 52. 18.100 / 52. 18.100
libavcodec 54. 92.100 / 54. 92.100
libavformat 54. 63.104 / 54. 63.104
libavdevice 53. 5.103 / 53. 5.103
libavfilter 3. 42.103 / 3. 42.103
libswscale 2. 2.100 / 2. 2.100
libswresample 0. 17.102 / 0. 17.102
libpostproc 52. 2.100 / 52. 2.100
Input #0, matroska,webm, from '/tmp/Untitled Screencast.webm':
Duration: 00:11:51.60, start: 0.000000, bitrate: 666 kb/s
Stream #0:0: Video: vp8, yuv420p, 992x736, SAR 1:1 DAR 31:23, 1k fps, 30.25 tbr, 1k tbn, 1k tbc (default)
Stream #0:1: Audio: vorbis, 48000 Hz, stereo, fltp (default)
[libx264 @ 0x1526fe0] using SAR=1/1
[libx264 @ 0x1526fe0] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX
[libx264 @ 0x1526fe0] profile High, level 3.1
[libx264 @ 0x1526fe0] 264 - core 142 r2491 24e4fed - H.264/MPEG-4 AVC codec - Copyleft 2003-2014 - http://www.videolan.org/x264.html - options: cabac=1 ref=3 deblock=1:0:0 analyse=0x3:0x113 me=hex subme=7 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=18 lookahead_threads=3 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=3 b_pyramid=2 b_adapt=1 b_bias=0 direct=1 weightb=1 open_gop=0 weightp=2 keyint=250 keyint_min=10 scenecut=40 intra_refresh=0 rc_lookahead=40 rc=crf mbtree=1 crf=20.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00
Output #0, mp4, to '/tmp/448dfa6f-b118-44b9-a22f-fc763bbcdc5b.mp4':
Metadata:
encoder : Lavf54.63.104
Stream #0:0: Video: h264 ([33][0][0][0] / 0x0021), yuv420p, 992x736 [SAR 1:1 DAR 31:23], q=-1--1, 10240 tbn, 10 tbc (default)
Stream #0:1: Audio: aac ([64][0][0][0] / 0x0040), 48000 Hz, stereo, fltp, 128 kb/s (default)
Stream mapping:
Stream #0:0 -> #0:0 (vp8 -> libx264)
Stream #0:1 -> #0:1 (vorbis -> aac)
Press [q] to stop, [?] for help