Converting mp4 for android tablet just stops, to android handy works

Discussion of the HandBrake command line interface (CLI)
Forum rules
An Activity Log is required for support requests. Please read How-to get an activity log? for details on how and why this should be provided.
Post Reply
grl
Posts: 4
Joined: Sat Jun 04, 2016 3:46 pm

Converting mp4 for android tablet just stops, to android handy works

Post by grl » Sat Jun 04, 2016 4:31 pm

Trying to convert some older mp4 for use on a tablet. The convert just stops at some point (always the same point!) and doesn't proceed. No error message, no nothing - just stops. Waited for 24h+ but it doesn't proceed.

Diskspace is not a problem - there is about 1000GB of space, the video itsself has 650MB.

If I change from preset "Android Tablet" to "Android Phone" the convert works as expected. It happens with different files - as all seem to play ok on my pc and the Phone-convert works I'd think the sourcefiles are ok.

I want to use that in a script on a headless server, so I can just drop in some video and it will be automatically converted and then sent to the Android Tablet. As HandBrakeCLI just hangs and doesn't finish or quits fireing an error I can't react to that problem - I have to log on to the server, kill the HandbrakeCLI process till it happens the next time with the next video.

So - any help to get either fixed that problem so the video converts or at least that HandbrakeCLI stops with some exit code<>0 so I can detect the failure?

I use HandbrakeCLI 0.10.5 on debian sid, out of the debian repos.

Using preset "Android Tablet I get:

Code: Select all

# HandBrakeCLI -i oldvid.mp4 -o tabletvid.mp4 --preset="Android Tablet"
[18:00:57] hb_init: starting libhb thread
HandBrake 0.10.5 (2016021200) - Linux x86_64 - https://handbrake.fr
4 CPUs detected
Opening oldvid.mp4...
[18:00:57] CPU: Intel(R) Core(TM) i5-3570T CPU @ 2.30GHz
[18:00:57]  - Intel microarchitecture Ivy Bridge
[18:00:57]  - logical processor count: 4
[18:00:57] OpenCL: library not available
[18:00:57] hb_scan: path=oldvid.mp4, title_index=1
udfread ERROR: ECMA 167 Volume Recognition failed
disc.c:274: failed opening UDF image oldvid.mp4
disc.c:352: error opening file BDMV/index.bdmv
disc.c:352: error opening file BDMV/BACKUP/index.bdmv
[18:00:57] bd: not a bd - trying as a stream/file instead
libdvdnav: Using dvdnav version 5.0.1
libdvdread:DVDOpenFileUDF:UDFFindFile /VIDEO_TS/VIDEO_TS.IFO failed
libdvdread:DVDOpenFileUDF:UDFFindFile /VIDEO_TS/VIDEO_TS.BUP failed
libdvdread: Can't open file VIDEO_TS.IFO.
libdvdnav: vm: failed to read VIDEO_TS.IFO
[18:00:57] dvd: not a dvd - trying as a stream/file instead
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'oldvid.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf57.23.101
  Duration: 01:53:52.48, start: 0.069063, bitrate: 771 kb/s
    Stream #0.0(und): Video: h264 (Main), yuv420p, 640x480 [PAR 1:1 DAR 4:3], 743 kb/s, 27.25 fps, 16k tbn, 60 tbc (default)
    Stream #0.1(und): Audio: mp3, 16000 Hz, 1 channels, s16p, 24 kb/s (default)
[18:00:57] scan: decoding previews for title 1
[18:00:57] scan: audio 0x1: mp3, rate=16000Hz, bitrate=24000 Unknown (MP3) (1.0 ch)
[18:00:57] scan: 10 previews, 640x480, 22.348 fps, autocrop = 0/0/0/0, aspect 4:3, PAR 1:1
[18:00:57] libhb: scan thread found 1 valid title(s)
+ title 1:
  + stream: oldvid.mp4
  + duration: 01:53:52
  + size: 640x480, pixel aspect: 1/1, display aspect: 1.33, 22.348 fps
  + autocrop: 0/0/0/0
  + support opencl: no
  + support hwd: not built-in
  + chapters:
    + 1: cells 0->0, 0 blocks, duration 01:53:52
  + audio tracks:
    + 1, Unknown (MP3) (1.0 ch) (iso639-2: und)
  + subtitle tracks:
+ Using preset: Android Tablet
[18:00:57] 1 job(s) to process
[18:00:57] starting job
[18:00:57] work: sanitizing track 1 mixdown Dolby Pro Logic II to Mono
[18:00:57] work: sanitizing track 1 bitrate 128 to 96 Kbps
[18:00:57] sync: expecting 152692 video frames
[18:00:57] job configuration:
[18:00:57]  * source
[18:00:57]    + oldvid.mp4
[18:00:57]    + title 1, chapter(s) 1 to 1
[18:00:57]    + container: mov,mp4,m4a,3gp,3g2,mj2
[18:00:57]    + data rate: 771 kbps
[18:00:57]  * destination
[18:00:57]    + tabletvid.mp4
[18:00:57]    + container: MPEG-4 (libavformat)
[18:00:57]  * video track
[18:00:57]    + decoder: h264
[18:00:57]      + bitrate 743 kbps
[18:00:57]    + filters
[18:00:57]      + Framerate Shaper (2:27000000:900000)
[18:00:57]        + frame rate: 22.348 fps -> peak rate limited to 30.000 fps
[18:00:57]      + Crop and Scale (640:480:0:0:0:0)
[18:00:57]        + source: 640 * 480, crop (0/0/0/0): 640 * 480, scale: 640 * 480
[18:00:57]    + loose anamorphic
[18:00:57]      + storage dimensions: 640 * 480, mod 2
[18:00:57]      + pixel aspect ratio: 1 / 1
[18:00:57]      + display dimensions: 640 * 480
[18:00:57]    + encoder: H.264 (libx264)
[18:00:57]      + preset:  medium
[18:00:57]      + profile: main
[18:00:57]      + level:   3.1
[18:00:57]      + quality: 22.00 (RF)
[18:00:57]  * audio track 1
[18:00:57]    + decoder: Unknown (MP3) (1.0 ch) (track 1, id 0x1)
[18:00:57]      + bitrate: 24 kbps, samplerate: 16000 Hz
[18:00:57]    + mixdown: Mono
[18:00:57]    + encoder: AAC (libavcodec)
[18:00:57]      + bitrate: 96 kbps, samplerate: 16000 Hz
[18:00:57] reader: first SCR -6215 id 0x1 DTS -6215
[18:00:57] encx264: min-keyint: 22, keyint: 220
[18:00:57] encx264: encoding at constant RF 22.000000
[18:00:57] encx264: unparsed options: level=3.1:8x8dct=0:vbv-bufsize=14000:vbv-maxrate=14000
x264 [info]: using SAR=1/1
x264 [info]: using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX
x264 [info]: profile Main, level 3.1
[18:00:57] sync: first pts is 8645
Encoding: task 1 of 1, 3.22 % (134.08 fps, avg 132.78 fps, ETA 00h18m33s)[18:01:35] sync: audio 0x1 time went backwards 35 ms, dropped 1 frames (start 19841765, next 19845000)
Encoding: task 1 of 1, 7.43 % (138.06 fps, avg 135.29 fps, ETA 00h17m25s)[18:02:21] sync: audio 0x1 time went backwards 39 ms, dropped 1 frames (start 43995605, next 43999200)
Encoding: task 1 of 1, 11.50 % (127.78 fps, avg 135.95 fps, ETA 00h16m34s)[18:03:07] sync: audio 0x1 time went backwards 43 ms, dropped 1 frames (start 68149445, next 68153400)
Encoding: task 1 of 1, 14.12 % (113.34 fps, avg 133.83 fps, ETA 00h16m20s)[18:03:39] sync: audio 0x1 time went backwards 47 ms, dropped 2 frames (start 92303285, next 92307600)
Encoding: task 1 of 1, 17.26 % (113.37 fps, avg 134.86 fps, ETA 00h15m36s)[/quote]
At this point nothing happens again. If I redirect the output to a file it just repeats that last line in an infinite loop.

If I change to preset "Android Phone" it works:

Code: Select all

# HandBrakeCLI -i oldvid.mp4 -o phonevid.mp4 --preset="Android Phone"
[18:18:54] hb_init: starting libhb thread
HandBrake 0.10.5 (2016021200) - Linux x86_64 - https://handbrake.fr
4 CPUs detected
Opening oldvid.mp4...
[18:18:54] CPU: Intel(R) Core(TM) i5-3570T CPU @ 2.30GHz
[18:18:54]  - Intel microarchitecture Ivy Bridge
[18:18:54]  - logical processor count: 4
[18:18:54] OpenCL: library not available
[18:18:54] hb_scan: path=oldvid.mp4, title_index=1
udfread ERROR: ECMA 167 Volume Recognition failed
disc.c:274: failed opening UDF image oldvid.mp4
disc.c:352: error opening file BDMV/index.bdmv
disc.c:352: error opening file BDMV/BACKUP/index.bdmv
[18:18:54] bd: not a bd - trying as a stream/file instead
libdvdnav: Using dvdnav version 5.0.1
libdvdread:DVDOpenFileUDF:UDFFindFile /VIDEO_TS/VIDEO_TS.IFO failed
libdvdread:DVDOpenFileUDF:UDFFindFile /VIDEO_TS/VIDEO_TS.BUP failed
libdvdread: Can't open file VIDEO_TS.IFO.
libdvdnav: vm: failed to read VIDEO_TS.IFO
[18:18:54] dvd: not a dvd - trying as a stream/file instead
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'oldvid.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf57.23.101
  Duration: 01:53:52.48, start: 0.069063, bitrate: 771 kb/s
    Stream #0.0(und): Video: h264 (Main), yuv420p, 640x480 [PAR 1:1 DAR 4:3], 743 kb/s, 27.25 fps, 16k tbn, 60 tbc (default)
    Stream #0.1(und): Audio: mp3, 16000 Hz, 1 channels, s16p, 24 kb/s (default)
[18:18:54] scan: decoding previews for title 1
[18:18:54] scan: audio 0x1: mp3, rate=16000Hz, bitrate=24000 Unknown (MP3) (1.0 ch)
[18:18:54] scan: 10 previews, 640x480, 22.348 fps, autocrop = 0/0/0/0, aspect 4:3, PAR 1:1
[18:18:54] libhb: scan thread found 1 valid title(s)
+ title 1:
  + stream: oldvid.mp4
  + duration: 01:53:52
  + size: 640x480, pixel aspect: 1/1, display aspect: 1.33, 22.348 fps
  + autocrop: 0/0/0/0
  + support opencl: no
  + support hwd: not built-in
  + chapters:
    + 1: cells 0->0, 0 blocks, duration 01:53:52
  + audio tracks:
    + 1, Unknown (MP3) (1.0 ch) (iso639-2: und)
  + subtitle tracks:
+ Using preset: Android Phone
[18:18:54] 1 job(s) to process
[18:18:54] starting job
[18:18:54] work: mixdown not specified, track 1 setting mixdown Mono
[18:18:54] work: bitrate not specified, track 1 setting bitrate 40 Kbps
[18:18:54] sync: expecting 152692 video frames
[18:18:54] job configuration:
[18:18:54]  * source
[18:18:54]    + oldvid.mp4
[18:18:54]    + title 1, chapter(s) 1 to 1
[18:18:54]    + container: mov,mp4,m4a,3gp,3g2,mj2
[18:18:54]    + data rate: 771 kbps
[18:18:54]  * destination
[18:18:54]    + phonevid.mp4
[18:18:54]    + container: MPEG-4 (libavformat)
[18:18:54]  * video track
[18:18:54]    + decoder: h264
[18:18:54]      + bitrate 743 kbps
[18:18:54]    + filters
[18:18:54]      + Framerate Shaper (0:27000000:1208159)
[18:18:54]        + frame rate: same as source (around 22.348 fps)
[18:18:54]      + Crop and Scale (640:480:0:0:0:0)
[18:18:54]        + source: 640 * 480, crop (0/0/0/0): 640 * 480, scale: 640 * 480
[18:18:54]    + dimensions: 640 * 480, mod 0
[18:18:54]    + encoder: MPEG-4 (libavcodec)
[18:18:54]      + bitrate: 1000 kbps, pass: 0
[18:18:54]  * audio track 1
[18:18:54]    + decoder: Unknown (MP3) (1.0 ch) (track 1, id 0x1)
[18:18:54]      + bitrate: 24 kbps, samplerate: 16000 Hz
[18:18:54]    + mixdown: Mono
[18:18:54]    + encoder: AAC (libavcodec)
[18:18:54]      + bitrate: 40 kbps, samplerate: 16000 Hz
[18:18:54] reader: first SCR -6215 id 0x1 DTS -6215
[18:18:54] encavcodecInit: MPEG-4 ASP encoder
[18:18:54] encavcodec: truncating framerate 27000000 / 1208159
[18:18:54] sync: first pts is 8645
Encoding: task 1 of 1, 3.18 % (769.26 fps, avg 771.87 fps, ETA 00h03m11s)[18:19:01] sync: audio 0x1 time went backwards 35 ms, dropped 1 frames (start 19841765, next 19845000)
Encoding: task 1 of 1, 7.32 % (776.20 fps, avg 777.69 fps, ETA 00h03m02s)[18:19:09] sync: audio 0x1 time went backwards 39 ms, dropped 1 frames (start 43995605, next 43999200)
Encoding: task 1 of 1, 11.48 % (778.33 fps, avg 780.33 fps, ETA 00h02m53s)[18:19:17] sync: audio 0x1 time went backwards 43 ms, dropped 1 frames (start 68149445, next 68153400)
Encoding: task 1 of 1, 14.06 % (756.59 fps, avg 778.22 fps, ETA 00h02m48s)[18:19:22] sync: audio 0x1 time went backwards 47 ms, dropped 2 frames (start 92303285, next 92307600)
Encoding: task 1 of 1, 99.89 % (792.28 fps, avg 793.85 fps, ETA 00h00m00s)[18:22:07] reader: done. 1 scr changes
[18:22:07] work: average encoding speed for job is 793.847046 fps
Encoding: task 1 of 1, 100.00 % (792.28 fps, avg 793.85 fps, ETA 00h00m00s)[18:22:07] sync: got 152690 frames, 152692 expected
[18:22:07] render: lost time: 0 (0 frames)
[18:22:07] render: gained time: 0 (0 frames) (0 not accounted for)
[18:22:07] h264-decoder done: 152690 frames, 0 decoder errors, 0 drops
[18:22:07] mp3-decoder done: 0 frames, 0 decoder errors, 0 drops
[18:22:07] mux: track 0, 152690 frames, 854293018 bytes, 1000.28 kbps, fifo 2048
[18:22:07] mux: track 1, 106756 frames, 35841458 bytes, 41.97 kbps, fifo 2048
[18:22:07] libhb: work result = 0

Encode done!

HandBrake has exited.
Any help appreciated!

Lukas

Post Reply