QuickTime 7.3 breaks anamorphic encoded movies

HandBrake for Mac support
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.
TheMags
Posts: 8
Joined: Tue Aug 28, 2007 5:56 pm

QuickTime 7.3 breaks anamorphic encoded movies

Post by TheMags »

Just discovered after upgrading to QuickTime 7.3 (on a Dual G5 running 10.4.10) that QuickTime player and iTunes no longer will display H.264 mp4s correctly if they are encoded anamorphically.

They are streched much to wide. For example a movie with the format 718 x 576 (1021 x 576) - which QuickTIme player reports correctly - will be displayed as 1452 x 576 as "normal" size.

This is likely a QuickTime bug, but since it affects Handbrake encoded videos I thought I'd mention it here. Note that the movies still plays correctly in VLC or if I install Perian (though Perian seems to suffer from some sound problems).

EDIT: updating to QuckTime 7.4 fixed the display problem in the Finder and QuickTime Player, but the problem is still there in iTunes 7.6 (now on Mac OS X 10.4.11).
Last edited by TheMags on Fri Jan 18, 2008 1:54 pm, edited 1 time in total.
CoolieRanx
Posts: 3
Joined: Tue Nov 06, 2007 4:31 pm

Post by CoolieRanx »

Thank goodness someone else noticed this problem! I've been scouring apple.com's forums for a solution, but haven't found anything.

Any way we can bring this bug to Apple's attention?
User avatar
s55
HandBrake Team
Posts: 10358
Joined: Sun Dec 24, 2006 1:05 pm

Post by s55 »

If this is a problem, I wouldn't expect apple to fix it any time soon. I'm guessing they'll have somewhat more important things to fix.
Bear Hunter
Posts: 47
Joined: Fri Oct 05, 2007 11:13 pm

Post by Bear Hunter »

Damnit... I just upgraded the other day on my laptop....I'll have to check it out. Luckily the iMac still has the previous version.
User avatar
Ritsuka
HandBrake Team
Posts: 1656
Joined: Fri Jan 12, 2007 11:29 am

Post by Ritsuka »

It's not a bug, it's a feature!™ :lol:

The new quicktime reads the SAR directly from the video stream. And then it applies the transformation matrix that handbrake inserts in the mp4.

So video aspect ratio + container aspect ratio = ultra wide video.

For now you can install perian or, if you aren't going to watch your video on the atv, delete the transformation matrix with dumpster.
CS
Posts: 1
Joined: Tue Nov 06, 2007 11:01 pm

Post by CS »

Thank you for the hint about Dumpster.

I had a movie encoded in 710x576 with an intended size of 1010x576. It now played in QT and iTunes (anybody noticed the new look of the chapter selection?) as 1436x576. (1436=1010*1010/710.) With Dumpster I changed moov.trak.tkhd.trackWidth from 710 to 1010 (displays as 0.01010). Now it plays as 1010x576 again.

Note: the preview in Finder (10.4.7) now does not show the movie with the correct aspect ratio. Seems that it is not as anamorphic aware as QT and iTunes.

P.S.: Although I have been successful with this 710 x 576 (1010 x 576) movie, I could not convince QT not to play a 648 x 328 (576 x 328) movie as 512 x 328.

Do not believe me. I tried to reproduce the success with a similar movie, and I couldn't. So maybe I had been doing something completely different earlier. Any help is welcome.
Bear Hunter
Posts: 47
Joined: Fri Oct 05, 2007 11:13 pm

Post by Bear Hunter »

Just checked my movies and they all look good to me
blancoboy
Posts: 1
Joined: Thu Nov 08, 2007 11:01 pm

Post by blancoboy »

Having the problem with quicktime and itunes, but everything seems to work fine in front row. My question is will this problem occur when I purchase Apple TV?
Cavalicious
Moderator
Posts: 1804
Joined: Mon Mar 26, 2007 12:07 am

Post by Cavalicious »

No..all is fine on the AppleTV front.

...Maybe until they they release an update.
stephenthomas0
Posts: 9
Joined: Wed Mar 28, 2007 8:02 am

Post by stephenthomas0 »

So is this an error with Quicktime or Apple? i.e is it a problem with handbrake creating an incorrect transformation matrix or is it quicktime not following the spec?
I've used dumpster for now on my existing videos, changing the transformation matrix to 1's diagonally, rather than the 1.44221 (or whatever it is). It looks better than it did before, but I'm not sure if it looked as good as it did before this whole mess
jbrjake
Veteran User
Posts: 4805
Joined: Wed Dec 13, 2006 1:38 am

Post by jbrjake »

stephenthomas0 wrote:So is this an error with Quicktime or Apple? i.e is it a problem with handbrake creating an incorrect transformation matrix or is it quicktime not following the spec?
Here's how it works.

Up until 7.3, QuickTime had what I consider a bug: it ignored extra information in video tracks. Like, if a video track gave a pixel aspect ratio to use, QuickTime would ignore it.

To work around this, maurj coded in another way to tell QuickTime how to display anamorphic video -- a transformation matrix in the MP4.

Starting with 7.3, QuickTime does listen to pixel aspect ratios in the video track.

But it also still listens to transformation matrices, so it applies both, distorting the image.

Obviously, future releases of HandBrake will not set a transformation matrix any more. For videos encoded with the current release (or even current dev code), you will have to remove the matrix with Dumpster in order for it to look right in QuickTime 7.3. But as a result, it will look wrong in QuickTime 7.2 and earlier.
mattchidester
Posts: 2
Joined: Sat Nov 10, 2007 8:31 pm

Is this a permanent issue with Quicktime or Handbrake

Post by mattchidester »

I have recorded hundreds of my movies on Handbrake, and now none show correctly in Quicktime. Ive read and understand the change was in Quicktime, but does this mean I am going to have to re-record all of my movies when the new version of Handbrake is released? I don't mind watching them in VLC on my computer, but i really hope these movies weren't recorded with a shortcut matrix by handbrake, just to have Quicktime fix their error and all the movies recorded by this shortcut matrix, essentially worthless. As well, this isn't just a Quicktime problem, if this matrix shortcut was just a quicktime error before, now, with quickview, this is a system wide display problem. All of the movies I recorded in handbrake are showing improperly on system functions. Is this a problem quicktime will fix and all will go back to normal, or was this the fix, and now everyone who adjusted to their mistake, is paying the price?
The best part is, all of the movies I recorded in Visualhub displayed correctly before, and still do now. That is not a slam to handbrake (which i wholeheartedly prefer to visualhub for dvd encoding), but I want to be sure this isn't a permanent problem all of my movies recorded in Handbrake experience, regardless of the software fix.
nightstrm
Veteran User
Posts: 1887
Joined: Fri Mar 23, 2007 5:43 am

Re: Is this a permanent issue with Quicktime or Handbrake

Post by nightstrm »

mattchidester wrote:I have recorded hundreds of my movies on Handbrake, and now none show correctly in Quicktime. Ive read and understand the change was in Quicktime, but does this mean I am going to have to re-record all of my movies when the new version of Handbrake is released? I don't mind watching them in VLC on my computer, but i really hope these movies weren't recorded with a shortcut matrix by handbrake, just to have Quicktime fix their error and all the movies recorded by this shortcut matrix, essentially worthless. As well, this isn't just a Quicktime problem, if this matrix shortcut was just a quicktime error before, now, with quickview, this is a system wide display problem. All of the movies I recorded in handbrake are showing improperly on system functions. Is this a problem quicktime will fix and all will go back to normal, or was this the fix, and now everyone who adjusted to their mistake, is paying the price?
The best part is, all of the movies I recorded in Visualhub displayed correctly before, and still do now. That is not a slam to handbrake (which i wholeheartedly prefer to visualhub for dvd encoding), but I want to be sure this isn't a permanent problem all of my movies recorded in Handbrake experience, regardless of the software fix.
Did you bother to read the post right above yours? It answers your question... You can't blame the HB team because the QT team finally got around to implementing proper PAR support.
or videos encoded with the current release (or even current dev code), you will have to remove the matrix with Dumpster in order for it to look right in QuickTime 7.3. But as a result, it will look wrong in QuickTime 7.2 and earlier.
mattchidester
Posts: 2
Joined: Sat Nov 10, 2007 8:31 pm

is this a problem in the future

Post by mattchidester »

Thanks for the reply, but it was worthless. My question is simple, if the handbrake team used a shortcut matrix for quicktime viewing, what's to say another similar problem won't emerge again. If this is just a viewing problem, then that is fixable with dumpster, but if this is a problem with the video's themselves, then they need to be redone. Simply saying fix the string in each video won't be worth the time if these videos are being created improperly in handbrake (though not in other programs like visualhub) hence the real question, why did handbrake use a shortcut that other developers didn't. We're seeing the problem with it now that visual hub's video's looked fine before and after quicktime fixed their mistake, while Handbrake users are stuck fixing their entire movie collections.

This dumpster fix is a great answer for those of us who have a library to fix, but would someone please detail how dumpster works, and how best to make this fix. Is there an automator command string we can utilize to fix all of these?

Next time you want to waste my time and quote me my post and call me an idiot afterward, read the thing and figure out the real issue being addressed.
rhester
Veteran User
Posts: 2888
Joined: Tue Apr 18, 2006 10:24 pm

Post by rhester »

I won't respond to the name-calling, but it's clear you didn't read anything that was said. Apple has caused themselves a problem here, and it's up to them to figure out how they want to address it (details below).

PAR is embedded in the video stream, and was previously ignored by QuickTime through 7.2. As of 7.3, it is read correctly, as every other non-Apple player in the universe did already.

The transformation matrix is an Apple-specific "feature" that is now being applied on top of PAR (thus causing the underlying distortion issue, as the anamorphic stretching is doubled) and is very easily removed via Dumpster.

Apple clearly hasn't given this a great deal of thought, given that the iPod, Apple TV, and MacOS itself still ignores PAR and uses the matrix alone, so Apple is now very obviously incompatible with themselves. As to whether they will ultimately consider the "fix" a bug and go back to ignoring PAR for consistency, or will instead update all of their other playback devices to match the new strategy (and thus causing display issues for literally hundreds of thousands of current titles) is anyone's guess.

You won't have to re-encode anything - run it through Dumpster, and voila, you're done. But be aware that anything you "fix" for QuickTime 7.3 will be distorted in MacOS, the iPod, and Apple TV, so you have to pick your poison (or just ignore QuickTime and play back with VLC or Perian).

If you don't have this problem with VisualHub, it's likely they never supported anamorphic to begin with. If you have a true anamorphic rip from VisualHub, that displays properly in QuickTime 7.2 and 7.3, VLC, and Apple TV, I'd be quite interested in seeing it.

This is absolutely not a HandBrake issue. Apple changed the rules and shot themselves in the foot, and now it's up to them to determine how they want to proceed. HandBrake-encoded content is perfectly safe and easily mangled to support the new QuickTime strategy, though I personally wouldn't dream of wholesale change of all my rips until Apple settles down a bit and figures out what their long-term intentions are. It's up to you if you want to Dumpster all of your content, only to find out QuickTime 7.3.1 goes back to ignoring PAR in the video stream.

Rodney
Cooky
Posts: 1
Joined: Sat Nov 10, 2007 11:37 pm

Post by Cooky »

Try installing the latest version of Perain. This seemed to fix my Quicktime distortion issues.

C.
TylerL
Posts: 3
Joined: Tue Jun 26, 2007 2:58 am

Post by TylerL »

rhester wrote:If you don't have this problem with VisualHub, it's likely they never supported anamorphic to begin with. If you have a true anamorphic rip from VisualHub, that displays properly in QuickTime 7.2 and 7.3, VLC, and Apple TV, I'd be quite interested in seeing it.
http://techspansion.com/visualhub/ed-hires.mp4
nightstrm
Veteran User
Posts: 1887
Joined: Fri Mar 23, 2007 5:43 am

Re: is this a problem in the future

Post by nightstrm »

mattchidester wrote:Thanks for the reply, but it was worthless. My question is simple, if the handbrake team used a shortcut matrix for quicktime viewing, what's to say another similar problem won't emerge again. If this is just a viewing problem, then that is fixable with dumpster, but if this is a problem with the video's themselves, then they need to be redone. Simply saying fix the string in each video won't be worth the time if these videos are being created improperly in handbrake (though not in other programs like visualhub) hence the real question, why did handbrake use a shortcut that other developers didn't. We're seeing the problem with it now that visual hub's video's looked fine before and after quicktime fixed their mistake, while Handbrake users are stuck fixing their entire movie collections.

This dumpster fix is a great answer for those of us who have a library to fix, but would someone please detail how dumpster works, and how best to make this fix. Is there an automator command string we can utilize to fix all of these?

Next time you want to waste my time and quote me my post and call me an idiot afterward, read the thing and figure out the real issue being addressed.
I think I (and others) addressed your problem pretty clearly: Apple changed something, using Dumpster will fix your Handbrake library when playing back on 7.3 machines, but not older ones. The real problem is that you wanted something spelled out word for word to follow. Go use VisualHub for all your encodes if they work for you, I don't think any of the devs will lose any sleep over it.

Now I know how jbrjake feels... :lol:
stephenthomas0
Posts: 9
Joined: Wed Mar 28, 2007 8:02 am

Post by stephenthomas0 »

Come on now guys, lets not bicker over who said what and why. At the end of the day the developers have offered a solution but it can't be a complete solution as we don't know what apple will do next... Can't we all just get along?
Anyway, thanks for the info, but I'm wondering if a new version of handbrake will be released that will give an option to leave out the transformation matrix to work with the new quicktime? I'm guessing that if they've made this update to quicktime, it'll only be a matter of time before it's rolled out to other apple products, iPod, tv etc via software updates...
rhester
Veteran User
Posts: 2888
Joined: Tue Apr 18, 2006 10:24 pm

Post by rhester »

TylerL wrote:
rhester wrote:If you don't have this problem with VisualHub, it's likely they never supported anamorphic to begin with. If you have a true anamorphic rip from VisualHub, that displays properly in QuickTime 7.2 and 7.3, VLC, and Apple TV, I'd be quite interested in seeing it.
http://techspansion.com/visualhub/ed-hires.mp4
Thanks for chiming in, Tyler. VisualHub has exactly the same problem, for exactly the same reason. This clip displays at 853x480 in QT 7.2 and 1133x480 in QT 7.3. How will you be 'fixing' this?

Rodney
Last edited by rhester on Sun Nov 11, 2007 8:06 pm, edited 1 time in total.
User avatar
s55
HandBrake Team
Posts: 10358
Joined: Sun Dec 24, 2006 1:05 pm

Post by s55 »

I can confirm Perian fixes the issue with both VH and HB
TylerL
Posts: 3
Joined: Tue Jun 26, 2007 2:58 am

Post by TylerL »

rhester wrote:Thanks for chiming in, Tyler. VisualHub has exactly the same problem, for exactly the same reason. This clip displays at 853x480 in QT 7.2 and 1133x480 in QT 7.3. How will you be 'fixing' this?
Ah, never tried it without Perian. Sorry.
vedder9
Posts: 1
Joined: Tue Nov 13, 2007 2:55 am

Post by vedder9 »

okay, so i just did the Perian install as well, and yes, the problem has been solved. my question is why? I am assuming it is pretty much undoing whatever "fix" apple came up with for 7.3. Which in theory means I am back to using a broken quicktime, does it not?

anyone have a good technical answer on this?
rhester
Veteran User
Posts: 2888
Joined: Tue Apr 18, 2006 10:24 pm

Post by rhester »

You answered your own question - Perian handles the decoding instead of QuickTime, and Perian does not utilize Apple's transformation matrix.

Rodney
dbendixen
Enlightened
Posts: 149
Joined: Mon Aug 06, 2007 4:41 pm

Post by dbendixen »

I'm sure some of you know this, but the videos are NOT broken when viewed through Front Row. Does this mean that Front Row does not use the same QT engine as QuickTime itself?
Post Reply