[FFmpeg-user] getting latest version of ffmpeg to work with Roku

Larry Roberts mythtv at american-hero.com
Sat Aug 3 23:34:43 CEST 2013


On 8/3/2013 4:37 AM, Reindl Harald wrote:
>
> Am 03.08.2013 03:01, schrieb Larry Roberts:
>> I went from what I believe is 0.4.8 (see below) to the latest distro version.
>>
>> ## Working Version ##
>> ffmpeg version N-48402-gaa86d2d.100
>>
>> ## Latest Distro version ##
>> ffmpeg version 1.2.1
>>
>> While no changes have been made to the script , a once working solution now produces videos that wont work on the
>> Roku. In googling I found some emails that seem to point to anything 5.10 or before as working fine.
>>
>> What I would like to do is see if I can compile the latest version from source and get this to work, or perhaps go
>> back and compile the 5.10 version.  I did what I thought was a successful build of ffmpeg but most of the options
>> that were working are now longer available (presets)
>>
>> So I'm looking for a little guidance
> you need to provide the full command line and uncutted output
>
>
So, in the process of crafting your requested info I discovered 
something that is pointing me to a new direction.

I went from encoding videos that were sourced from a PVR-350, to 
encoding video sourced from an HDHomeRun box.

I just fired up the old box and ran the old ffmpeg against a new 
recording and it DOESN'T work on the Roku.  I then ran the new ffmpeg 
against an old recording from the PVR-350 and it DOES work.

I hadn't bothered to try to convert any older stuff as it was already 
converted.   next step had me thinking about SD vs. HD. What I found is 
that I can convert new SD recordings and so far they work, while new HD 
recordings dont on the ROKU.
I should again point out that I can play either just fine on a pc/iPAD....

HD conversion output

[root at mythbe1 bin]# ffmpeg -i /mythtvstorage/2013_20130802170000.mpg   
-vcodec libx264  -s 640x480 -ss 00:00:00 -t 00:00:15 -preset ultrafast 
-crf 23 -acodec aac -strict -2 -ab 128k /roku/test6.m4v
ffmpeg version 1.2.1 Copyright (c) 2000-2013 the FFmpeg developers
   built on May 10 2013 15:14:14 with gcc 4.4.6 (GCC) 20120305 (Red Hat 
4.4.6-4)
   configuration: --prefix=/usr --libdir=/usr/lib64 
--shlibdir=/usr/lib64 --mandir=/usr/share/man --enable-shared 
--enable-runtime-cpudetect --enable-gpl --enable-version3 
--enable-postproc --enable-avfilter --enable-pthreads --enable-x11grab 
--enable-vdpau --disable-avisynth --enable-frei0r --enable-libopencv 
--enable-libdc1394 --enable-libgsm --enable-libmp3lame --enable-libnut 
--enable-libopencore-amrnb --enable-libopencore-amrwb 
--enable-libopenjpeg --enable-librtmp --enable-libspeex 
--enable-libtheora --enable-libvorbis --enable-libvpx --enable-libx264 
--enable-libxavs --enable-libxvid --extra-cflags='-O2 -g -pipe -Wall 
-Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector 
--param=ssp-buffer-size=4 -m64 -mtune=generic -fPIC' --disable-stripping
   libavutil      52. 18.100 / 52. 18.100
   libavcodec     54. 92.100 / 54. 92.100
   libavformat    54. 63.104 / 54. 63.104
   libavdevice    54.  3.103 / 54.  3.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
[mpegts @ 0x978a40] PES packet size mismatch
Input #0, mpegts, from '/mythtvstorage/2013_20130802170000.mpg':
   Duration: 00:59:59.47, start: 48658.910067, bitrate: 11381 kb/s
   Program 1
     Stream #0:0[0x7c0]: Video: mpeg2video (Main) ([2][0][0][0] / 
0x0002), yuv420p, 1920x1080 [SAR 1:1 DAR 16:9], 29.97 fps, 29.97 tbr, 
90k tbn, 59.94 tbc
     Stream #0:1[0x7c1](eng): Audio: ac3 (AC-3 / 0x332D4341), 48000 Hz, 
5.1(side), fltp, 384 kb/s
     Stream #0:2[0x7c2](spa): Audio: ac3 (AC-3 / 0x332D4341), 48000 Hz, 
mono, fltp, 96 kb/s (visual impaired)
[libx264 @ 0x97f040] using SAR=4/3
[libx264 @ 0x97f040] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2
[libx264 @ 0x97f040] profile Constrained Baseline, level 3.0
[libx264 @ 0x97f040] 264 - core 130 - H.264/MPEG-4 AVC codec - Copyleft 
2003-2013 - http://www.videolan.org/x264.html - options: cabac=0 ref=1 
deblock=0:0:0 analyse=0:0 me=dia subme=0 psy=1 psy_rd=1.00:0.00 
mixed_ref=0 me_range=16 chroma_me=1 trellis=0 8x8dct=0 cqm=0 
deadzone=21,11 fast_pskip=1 chroma_qp_offset=0 threads=1 
lookahead_threads=1 sliced_threads=0 nr=0 decimate=1 interlaced=0 
bluray_compat=0 constrained_intra=0 bframes=0 weightp=0 keyint=250 
keyint_min=25 scenecut=0 intra_refresh=0 rc=crf mbtree=0 crf=23.0 
qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=0
Output #0, ipod, to '/roku/test6.m4v':
   Metadata:
     encoder         : Lavf54.63.104
     Stream #0:0: Video: h264 (avc1 / 0x31637661), yuv420p, 640x480 [SAR 
4:3 DAR 16:9], q=-1--1, 30k tbn, 29.97 tbc
     Stream #0:1(eng): Audio: aac (mp4a / 0x6134706D), 48000 Hz, 
5.1(side), fltp, 128 kb/s
Stream mapping:
   Stream #0:0 -> #0:0 (mpeg2video -> libx264)
   Stream #0:1 -> #0:1 (ac3 -> aac)
Press [q] to stop, [?] for help
[mpeg2video @ 0x97ca40] warning: first frame is no keyframe
frame=  450 fps= 76 q=22.0 Lsize=    3544kB time=00:00:15.01 
bitrate=1933.1kbits/s dup=81 drop=0
video:3400kB audio:130kB subtitle:0 global headers:0kB muxing overhead 
0.398015%
[libx264 @ 0x97f040] frame I:2     Avg QP:20.00  size: 36056
[libx264 @ 0x97f040] frame P:448   Avg QP:22.27  size:  7608
[libx264 @ 0x97f040] mb I  I16..4: 100.0%  0.0%  0.0%
[libx264 @ 0x97f040] mb P  I16..4: 10.6%  0.0%  0.0%  P16..4: 48.2% 
0.0%  0.0%  0.0%  0.0%    skip:41.2%
[libx264 @ 0x97f040] coded y,uvDC,uvAC intra: 30.7% 20.0% 9.4% inter: 
27.2% 12.8% 2.2%
[libx264 @ 0x97f040] i16 v,h,dc,p: 54% 27% 10% 10%
[libx264 @ 0x97f040] i8c dc,h,v,p: 64% 14% 19%  2%
[libx264 @ 0x97f040] kb/s:1854.52

Working SD conversion

[root at mythbe1 bin]# ffmpeg -i /mythtvstorage/1029_20130802093000.mpg   
-vcodec libx264  -s 640x480 -ss 00:00:00 -t 00:00:30 -preset ultrafast 
-crf 23 -acodec aac -strict -2 -ab 128k /roku/test5.m4v
ffmpeg version 1.2.1 Copyright (c) 2000-2013 the FFmpeg developers
   built on May 10 2013 15:14:14 with gcc 4.4.6 (GCC) 20120305 (Red Hat 
4.4.6-4)
   configuration: --prefix=/usr --libdir=/usr/lib64 
--shlibdir=/usr/lib64 --mandir=/usr/share/man --enable-shared 
--enable-runtime-cpudetect --enable-gpl --enable-version3 
--enable-postproc --enable-avfilter --enable-pthreads --enable-x11grab 
--enable-vdpau --disable-avisynth --enable-frei0r --enable-libopencv 
--enable-libdc1394 --enable-libgsm --enable-libmp3lame --enable-libnut 
--enable-libopencore-amrnb --enable-libopencore-amrwb 
--enable-libopenjpeg --enable-librtmp --enable-libspeex 
--enable-libtheora --enable-libvorbis --enable-libvpx --enable-libx264 
--enable-libxavs --enable-libxvid --extra-cflags='-O2 -g -pipe -Wall 
-Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector 
--param=ssp-buffer-size=4 -m64 -mtune=generic -fPIC' --disable-stripping
   libavutil      52. 18.100 / 52. 18.100
   libavcodec     54. 92.100 / 54. 92.100
   libavformat    54. 63.104 / 54. 63.104
   libavdevice    54.  3.103 / 54.  3.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
[mpegts @ 0x1f9ca40] max_analyze_duration 5000000 reached at 5024000 
microseconds
[mpegts @ 0x1f9ca40] Could not find codec parameters for stream 3 
(Unknown: none ([134][0][0][0] / 0x0086)): unknown codec
Consider increasing the value for the 'analyzeduration' and 'probesize' 
options
[NULL @ 0x1fa2840] start time is not set in estimate_timings_from_pts
Input #0, mpegts, from '/mythtvstorage/1029_20130802093000.mpg':
   Duration: 00:29:59.10, start: 55495.128611, bitrate: 2589 kb/s
   Program 1
     Stream #0:0[0x8c0]: Video: mpeg2video (Main) ([2][0][0][0] / 
0x0002), yuv420p, 704x480 [SAR 10:11 DAR 4:3], 29.97 fps, 59.94 tbr, 90k 
tbn, 59.94 tbc
     Stream #0:1[0x8c1](eng): Audio: ac3 ([129][0][0][0] / 0x0081), 
48000 Hz, stereo, fltp, 192 kb/s
     Stream #0:2[0x8c2](spa): Audio: ac3 ([129][0][0][0] / 0x0081), 
48000 Hz, stereo, fltp, 192 kb/s
     Stream #0:3[0x8c3]: Unknown: none ([134][0][0][0] / 0x0086)
File '/roku/test5.m4v' already exists. Overwrite ? [y/N] y
using SAR=1/1
[libx264 @ 0x1fa4300] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2
[libx264 @ 0x1fa4300] profile Constrained Baseline, level 3.0
[libx264 @ 0x1fa4300] 264 - core 130 - H.264/MPEG-4 AVC codec - Copyleft 
2003-2013 - http://www.videolan.org/x264.html - options: cabac=0 ref=1 
deblock=0:0:0 analyse=0:0 me=dia subme=0 psy=1 psy_rd=1.00:0.00 
mixed_ref=0 me_range=16 chroma_me=1 trellis=0 8x8dct=0 cqm=0 
deadzone=21,11 fast_pskip=1 chroma_qp_offset=0 threads=1 
lookahead_threads=1 sliced_threads=0 nr=0 decimate=1 interlaced=0 
bluray_compat=0 constrained_intra=0 bframes=0 weightp=0 keyint=250 
keyint_min=25 scenecut=0 intra_refresh=0 rc=crf mbtree=0 crf=23.0 
qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=0
Output #0, ipod, to '/roku/test5.m4v':
   Metadata:
     encoder         : Lavf54.63.104
     Stream #0:0: Video: h264 (avc1 / 0x31637661), yuv420p, 640x480 [SAR 
1:1 DAR 4:3], q=-1--1, 30k tbn, 29.97 tbc
     Stream #0:1(eng): Audio: aac (mp4a / 0x6134706D), 48000 Hz, stereo, 
fltp, 128 kb/s
Stream mapping:
   Stream #0:0 -> #0:0 (mpeg2video -> libx264)
   Stream #0:1 -> #0:1 (ac3 -> aac)
Press [q] to stop, [?] for help
frame=  900 fps=150 q=20.0 Lsize=    5903kB time=00:00:30.03 
bitrate=1610.2kbits/s dup=153 drop=0
video:5401kB audio:474kB subtitle:0 global headers:0kB muxing overhead 
0.469127%
[libx264 @ 0x1fa4300] frame I:4     Avg QP:15.50  size: 59440
[libx264 @ 0x1fa4300] frame P:896   Avg QP:19.68  size:  5906
[libx264 @ 0x1fa4300] mb I  I16..4: 100.0%  0.0%  0.0%
[libx264 @ 0x1fa4300] mb P  I16..4:  6.7%  0.0%  0.0%  P16..4: 31.2%  
0.0%  0.0%  0.0%  0.0%    skip:62.1%
[libx264 @ 0x1fa4300] coded y,uvDC,uvAC intra: 31.0% 63.9% 28.6% inter: 
15.1% 19.3% 5.4%
[libx264 @ 0x1fa4300] i16 v,h,dc,p: 33% 35% 16% 16%
[libx264 @ 0x1fa4300] i8c dc,h,v,p: 34% 33% 18% 15%
[libx264 @ 0x1fa4300] kb/s:1473.17

What do I need to tweak to get HD conversions working?  I have NO idea 
what I should even be testing at this point...



Thanks!

>
> _______________________________________________
> ffmpeg-user mailing list
> ffmpeg-user at ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-user



More information about the ffmpeg-user mailing list