Apple Universal not always producing iphone compatible files

Discuss encoding for devices and presets.
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.
Locked
Ranu
Posts: 2
Joined: Thu Jan 01, 2009 4:36 am

Apple Universal not always producing iphone compatible files

Post by Ranu »

I've been messing around for the last couple of days converting some of my eyeTV recordings to the new Apple Universal format (HB 0.9.3). A few of the converted files won't sync with my iphone (iTunes says the movie "isn't compatible with the iPhone"). They work fine on the Mac and AppleTV.

When I look at the produced files from handbrake, it appears that during the encoding (from the eyeTV mpeg format to apple universal) the size of the movie is being changed from 720x576 to 720x592. I think it's the 592 that stops them working with the iPhone. Interestingly other episodes of the same TV series, recorded on the same eyeTV are encoded by handbrake at 720*576 and work fine on all devices.

Any idea why handbrake is changing the resolution? Is this really what's causing the iphone incompatibility? Any cures?

I've posted the activity log below.

HandBrake Activity Log for /Users/Jonathan/Desktop/The Hollowmen - A Quiet January.m4v: 2009-01-01 09:39:57 +1100
Handbrake Version: 0.9.3 (2008112300)

[09:39:57] macgui: Rip: Pending queue count is 0
[09:39:57] macgui: Rip: No pending jobs, so sending this one to doAddToQueue
[09:39:57] macgui: Rip: Going right to performNewQueueScan
[09:39:57] macgui: scanning specifically for title: 1
[09:39:57] macgui: performNewQueueScan currentQueueEncodeIndex is: 18
[09:39:57] hb_scan: path=/Users/Jonathan/Movies/EyeTV Archive/The Hollowmen - A Quiet January.eyetv/000000000e9cbb6e.mpg, title_index=1
[09:39:57] scan: trying to open with libdvdread
[09:39:57] dvd: not a dvd - trying as a stream/file instead
[09:39:57] file is MPEG Transport Stream with 188 byte packets offset 0 bytes
[09:39:57] hb_ts_stream_find_pids - found the following PIDS
[09:39:57] Video PIDS :
[09:39:57] 0x200 type MPEG2 (0x2)
[09:39:57] Audio PIDS :
[09:39:57] 0x28a type MPEG2 (0x4)
[09:39:57] 0x294 type ISO 13818-1 PES private data (0x6)
[09:39:57] 0x240 type ISO 13818-1 PES private data (0x6)
[09:39:57] 0x17c0 type ISO 13818-1 PES private data (0x6)
[09:39:57] 0x433 type ISO 13818-1 private section (0x5)
[09:39:57] 0x1f2d type ISO 13818-1 private section (0x5)
[09:39:57] 0x1f2e type ISO 13818-1 private section (0x5)
[09:39:57] transport stream pid 0x28a (type 0x4) is MPEG2 audio id 0xc0
[09:39:57] transport stream pid 0x294 (type 0x81) is AC-3 audio id 0x81bd
[09:39:57] transport stream pid 0x240 (type 0x81) is AC-3 audio id 0x82bd
[09:39:57] transport stream pid 0x17c0 (type 0x81) is AC-3 audio id 0x83bd
[09:39:58] transport stream pid 0x433 (type 0x5) isn't audio
[09:39:58] transport stream pid 0x1f2d (type 0x5) isn't audio
[09:39:58] transport stream pid 0x1f2e (type 0x5) isn't audio
[09:39:58] scan: decoding previews for title 1
[09:39:58] stream: error near frame 1: continuity error: got 8 expected 7
[09:39:58] scan: audio 0x81bd: AC-3, rate=48000Hz, bitrate=448000 English (AC3) (2.0 ch)
[09:39:58] scan: audio 0xc0: mp2, rate=48000Hz, bitrate=384000 English (mp2) (2.0 ch)
[09:39:59] scan: 10 previews, 720x576, 25.000 fps, autocrop = 2/2/10/12, aspect 16:9, PAR 64:45
[09:39:59] scan: removing audio 0x82bd because no bitrate found
[09:39:59] scan: removing audio 0x83bd because no bitrate found
[09:39:59] scan: title (0) job->width:704, job->height:400
[09:39:59] stream: 43 good frames, 0 errors (0%)
[09:39:59] libhb: scan thread found 1 valid title(s)
[09:40:00] macgui: ScanDone state received from fQueueEncodeLibhb
[09:40:00] macgui: processNewQueueEncode title list is: 1
[09:40:00] macgui: Preset: Universal
[09:40:00] macgui: processNewQueueEncode number of passes expected is: 1
[09:40:00] macgui: prepareJob audiotrack 2 is: 0
[09:40:00] macgui: prepareJob exiting
[09:40:00] 1 job(s) to process
[09:40:00] starting job
[09:40:00] job configuration:
[09:40:00] * source
[09:40:00] + /Users/Jonathan/Movies/EyeTV Archive/The Hollowmen - A Quiet January.eyetv/000000000e9cbb6e.mpg
[09:40:00] + title 1, chapter(s) 1 to 1
[09:40:00] * destination
[09:40:00] + /Users/Jonathan/Desktop/The Hollowmen - A Quiet January.m4v
[09:40:00] + container: MPEG-4 (.mp4 and .m4v)
[09:40:00] + chapter markers
[09:40:00] * video track
[09:40:00] + decoder: mpeg2
[09:40:00] + bitrate 15000 kbps
[09:40:00] + frame rate: same as source (around 25.000 fps)
[09:40:00] + loose anamorphic
[09:40:00] + storage dimensions: 720 * 576 -> 720 * 592, crop 2/2/10/12
[09:40:00] + pixel aspect ratio: 35 / 24
[09:40:00] + display dimensions: 1050 * 592
[09:40:00] + encoder: x264
[09:40:00] + options: level=30:cabac=0:ref=3:mixed-refs=1:analyse=all:me=umh:no-fast-pskip=1
[09:40:00] + quality: 0.59
[09:40:00] * audio track 0
[09:40:00] + decoder: English (mp2) (2.0 ch) (track 1, id c0)
[09:40:00] + mixdown: Stereo
[09:40:00] + encoder: faac
[09:40:00] + bitrate: 160 kbps, samplerate: 48000 Hz
[09:40:00] * audio track 1
[09:40:00] + decoder: English (mp2) (2.0 ch) (track 1, id c0)
[09:40:00] + mixdown: Stereo
[09:40:00] + encoder: faac
[09:40:00] + bitrate: 128 kbps, samplerate: 48000 Hz
[09:40:00] dvd: not a dvd - trying as a stream/file instead
[09:40:00] reader: first SCR 1986381024
[09:40:00] stream: error near frame 1: continuity error: got 8 expected 7
[09:40:00] mpeg2: "Chapter 1" (1) at frame 0 time 10800
[09:40:00] encx264: encoding with stored aspect 35/24
[09:40:00] encx264: Encoding at constant RF 20.910002
x264 [info]: using SAR=35/24
x264 [warning]: frame MB size (45x37) > level limit (1620)
x264 [warning]: MB rate (41625) > level limit (40500)
x264 [info]: using cpu capabilities: MMX2 Cache64
x264 [info]: profile Baseline, level 3.0
[09:40:01] sync: expecting 40241 video frames
[09:40:01] sync: first pts is 10800
[09:40:02] sync: audio 1 time went backwards 0 ms, dropped 15 frames (next 38880, current 38880)
[09:40:02] sync: video time didn't advance - dropped 11 frames (delta 400 ms, current 50400, next 54000, dur 3600)
[09:40:02] sync: audio 0 time went backwards 0 ms, dropped 15 frames (next 38880, current 38880)
[10:25:31] stream: 69 new errors (4%) up to frame 1902: continuity error: got 4 expected 3
[10:25:31] sync: adding 87 ms of silence to audio 0 start 82069661, next 82061755
[10:25:31] sync: adding 87 ms of silence to audio 1 start 82069661, next 82061755
[10:25:31] sync: audio 0 time went backwards 0 ms, dropped 1 frames (next 82070395, current 82070395)
[10:25:31] sync: audio 1 time went backwards 0 ms, dropped 1 frames (next 82070395, current 82070395)
[10:25:47] sync: audio 1 time went backwards 0 ms, dropped 1 frames (next 82534061, current 82534061)
[10:25:47] sync: audio 0 time went backwards 0 ms, dropped 1 frames (next 82534061, current 82534061)
[11:04:10] hb_ts_stream_decode - eof
[11:04:10] stream: 3350 good frames, 73 errors (2%)
[11:04:10] reader: done. 4 scr changes
[11:04:10] reader: 1 drops because DTS out of range
[11:04:15] sync: got 40166 frames, 40241 expected
[11:04:15] work: average encoding speed for job is 7.948756 fps
[11:04:20] mpeg2 done: 40178 frames
[11:04:20] render: lost time: 0 (0 frames)
[11:04:20] render: gained time: 0 (0 frames) (0 not accounted for)
x264 [info]: slice I:412 Avg QP:19.75 size: 49227 PSNR Mean Y:43.72 U:48.14 V:48.54 Avg:44.78 Global:44.18
x264 [info]: slice P:39754 Avg QP:22.84 size: 9101 PSNR Mean Y:40.67 U:45.61 V:46.13 Avg:41.80 Global:41.21
x264 [info]: mb I I16..4: 12.9% 0.0% 87.1%
x264 [info]: mb P I16..4: 1.3% 0.0% 1.6% P16..4: 61.5% 17.0% 8.2% 0.3% 0.4% skip: 9.7%
x264 [info]: ref P L0 72.3% 16.8% 10.9%
x264 [info]: SSIM Mean Y:0.9769543
x264 [info]: PSNR Mean Y:40.701 U:45.639 V:46.153 Avg:41.827 Global:41.235 kb/s:1902.47
[11:04:20] mp2-decoder done: 0 frames, 0 decoder errors, 0 drops
[11:04:20] mp2-decoder done: 0 frames, 0 decoder errors, 0 drops
[11:04:20] libhb: work result = 0
jbrjake
Veteran User
Posts: 4805
Joined: Wed Dec 13, 2006 1:38 am

Re: Apple Universal not always producing iphone compatible files

Post by jbrjake »

It's a rounding error, will be fixed in the next release.
Ranu
Posts: 2
Joined: Thu Jan 01, 2009 4:36 am

Re: Apple Universal not always producing iphone compatible files

Post by Ranu »

Thanks for the response. Looking forward to the next release in that case... :)
chenks

Re: Apple Universal not always producing iphone compatible files

Post by chenks »

is there a workaround for this in the mean time?
i have the problem when using the AppleTV preset also.
jbrjake
Veteran User
Posts: 4805
Joined: Wed Dec 13, 2006 1:38 am

Re: Apple Universal not always producing iphone compatible files

Post by jbrjake »

Reduce the width until the height becomes 576.
chenks

Re: Apple Universal not always producing iphone compatible files

Post by chenks »

see this is where i am confused.

why is 770x576 loose better than the original source 720x576 ?
jbrjake
Veteran User
Posts: 4805
Joined: Wed Dec 13, 2006 1:38 am

Re: Apple Universal not always producing iphone compatible files

Post by jbrjake »

Well just look at your source. It needs to be cropped. 4 pixels vertically, 22 pixels horizontally.

So it's *not* 720*576 with a storage aspect ratio of 1.25:1. It's actually a visible frame of 698*572 with a storage aspect ratio of 1.22027972:1.

You apply the signaled PAR of 64/45 to that you don't get 1024*576. You get 992.711111 * 572. That's not a display aspect ratio of 16:9, it's 1.73550894:1.

I was wrong with my earlier assessment by the way -- this isn't the same as the aspect rounding issue, I don't think (that would have it up to 580-something for the height, at worst). For some reason you're getting job->width set to 720 for this, when it should be the width after cropping -- 698. Not sure how you're getting this...I just checked 0.9.3 code and when loose ana is selected, it does default the width to the source width minus horizontal cropping. It should only scale to 720 if that value is greater than 720, and in this case it is not.

Anyway because the width is getting set, somehow, to 720, it has to scale up to that while also scaling up the height in such a way that it preserves the storage aspect ratio. 720/1.22 == 590. Then it just adjusts to the nearest number cleanly divisible by 16.
chenks

Re: Apple Universal not always producing iphone compatible files

Post by chenks »

this is 4:3 content i am talking about, not widescreen.
it is a DVD of TV episodes.

when i ripped all 6 episodes from the DVD, handbrake produced 2 different end resolutions. 4 of the episodes had 1 resolution and 2 had another even though all 6 episodes on the DVD had an identical original source or 720x576.
jbrjake
Veteran User
Posts: 4805
Joined: Wed Dec 13, 2006 1:38 am

Re: Apple Universal not always producing iphone compatible files

Post by jbrjake »

chenks wrote:this is 4:3 content i am talking about, not widescreen.
....but you're posting in a thread that's about a widescreen source and you've chosen to neglect your commitment to provide a log. How was I supposed to know? I gave the proper answer for this thread, based on the information in this thread.
chenks

Re: Apple Universal not always producing iphone compatible files

Post by chenks »

sorry but i didn't see widescreen being mentioned in the thread title.
and it also seemed that the OP was also talking about 720x576 which is what i was also talking about.

720x576 isn't a widescreen resolution is it ?
jbrjake
Veteran User
Posts: 4805
Joined: Wed Dec 13, 2006 1:38 am

Re: Apple Universal not always producing iphone compatible files

Post by jbrjake »

...and still no log. It's also clear you've never read the documentation.
tallyho
Posts: 14
Joined: Tue May 06, 2008 7:55 am

Re: Apple Universal not always producing iphone compatible files

Post by tallyho »

Bit harsh. He probably read the helpful wiki:
So, in quick summary, to use a preset to encode with HandBrake. just click on the preset and then click "Rip". Thats it. Simple.
Universal
Description:
HandBrake's universally compatible, full resolution settings for all current Apple devices: iPod, iPhone, AppleTV, and Macs
Thankfully, the answer is available on this forum though, so no need for any more incompatible encodes. Hurrah.
Last edited by tallyho on Sat Feb 28, 2009 6:47 pm, edited 1 time in total.
chenks

Re: Apple Universal not always producing iphone compatible files

Post by chenks »

jbrjake wrote:...and still no log. It's also clear you've never read the documentation.
[Censored] you. i can now see this forum is run by arrogant [Censored]. i'll move on and use another app that works better for me, and is supported by helpful people that aren't stuck so far up their own [Censored] that their forehead is brown.

i didn't see the requirement to post a log as you already said it was something that would be fixed in a future release.
User avatar
s55
HandBrake Team
Posts: 10357
Joined: Sun Dec 24, 2006 1:05 pm

Re: Apple Universal not always producing iphone compatible files

Post by s55 »

Well, I guess were done here.

What an unnecessary overreaction. How rude.

*Locked*
Locked