Log in

View Full Version : Encoding animation vs. live action


N-Bomb
28th January 2002, 05:35
I'm wondering... from some stuff I've heard, animation doesn't compress well because the codecs don't like the sharp-contrasting lines... something which Doom9 mentioned in the recent codec shoot-out in some of the test clips.

I'm wondering, what IS the big difference between these two mediums which affects compression, and what can be done to optimize your settings for either source?



-Nick

Sharkbyte
29th January 2002, 21:47
That's just the opposite of what I have experienced:

I encoded The Emporer's New Groove @ 2000kbit and 3000kbit.
Result for a 85 minute animated movie: 2000kbit gave 773MB and 3000kbit gave 774MB.
Hmm, with sound, that meens about 880MB. I would like it to fit on 2 CD's, not have two 440MB parts.

My question: How can I get my animated movie bigger, in terms of quality and size ? My goal is 1400MB with sound, so about 1300MB for the video. The sound is about 85MB.

ProfDrMorph
29th January 2002, 22:03
I encoded The Emporer's New Groove @ 2000kbit and 3000kbit.
Result for a 85 minute animated movie: 2000kbit gave 773MB and 3000kbit gave 774MB.
Hmm, with sound, that meens about 880MB. I would like it to fit on 2 CD's, not have two 440MB parts.

My question: How can I get my animated movie bigger, in terms of quality and size ? My goal is 1400MB with sound, so about 1300MB for the video. The sound is about 85MB.
Sounds like you're using DivX3.11 Fast Motion. Just head over to Doom9's guide section. Everything you need to know is there. Isn't this a part of the forum rules that you should read the guides before posting? ;)

Sharkbyte
29th January 2002, 22:07
Sounds like you're using DivX3.11 Fast Motion. Just head over to Doom9's guide section. Isn't this a part of the forum rules that you should read the guides before posting?
Maybe I used DivX 4.12 :)

No I used Doom9's VERY good DivX4 "VirtualDub & VFAPI" Guide. Until now I haven't had to re-encode anything. I think it's because of the flat color scheme it encodes so good/small sized.

jggimi
29th January 2002, 22:31
Shark, Gknot 0.23 has a compressability test and calculator for Divx4. You might want to give that a try -- if you haven't already.

Foo
30th January 2002, 07:28
"I encoded The Emporer's New Groove @ 2000kbit and 3000kbit.
Result for a 85 minute animated movie: 2000kbit gave 773MB and 3000kbit gave 774MB.
Hmm, with sound, that meens about 880MB. I would like it to fit on 2 CD's, not have two 440MB parts. "

It will be the same size at 4000 too :). The codec can't use all the bits, so you can't bump up the size. Clean animation sources do compress very well. Given this films length, you could make a very nice one disc @ 640x352 (it's 1.85:1 IIRC). Use sharp bicubic, up your resolution (to 704x or 720x), include Dolby Digital audio etc. if you want to fill out the two cds. Depending on what resolution you are using now, the bump will allow the use of some of these left over bits, and the file size will grow as you'd expect.

Just remember resolution is a *secondary* factor for file size. That's why you can make a 640x and a 512x conversion that are the same exact size at the same bitrate. Resolution really only matters for file size at these boundary conditions that you have run into, where bitrate saturation can't be reached (the codec can't use all available bits at your chosen resolution).

Sharkbyte
30th January 2002, 12:47
It will be the same size at 4000 too :). The codec can't use all the bits, so you can't bump up the size. Clean animation sources do compress very well. Given this films length, you could make a very nice one disc @ 640x352 (it's 1.85:1 IIRC). Use sharp bicubic, up your resolution (to 704x or 720x), include Dolby Digital audio etc. if you want to fill out the two cds. Depending on what resolution you are using now, the bump will allow the use of some of these left over bits, and the file size will grow as you'd expect.

I suspected as much on the bitrate issue. The resolution of my rips are ALWAYS the same resolution (I do crop the black borders) as the original (the DVD that is). So this movie is 720x304 (16/9 Widescreen).
The sound is already of very high quality (VBR 32-320kbit LAME encoded --remix), but the picture looks to blurry...

Oh yes, 1 CD rips aren't an option: I'm a quality freak :D and I won't go any lower thean 2000kbit and certainly not the resolution.
So I have some more questions:

- How much of a difference in time is Precise Bicubic gonna take instead of Precise Bilinear ? Difference in file size ?

- Is there a way to put more color in the picture ? Like for example, a 16-bit photo and a 32-bit photo ? Can I use 24-bit color instead of YUV ?


And back on-topic:

I don't think animation is harder to compress because of the flat surfaces. Movies almost always have gradients because of the complexity of the lighting. Cartoons usually don't have that.

Foo
31st January 2002, 03:43
The file size difference between the bicubic and bilinear won't be huge, but it should solve that blurry problem. Since you've got the room, you might as well use sharp bicubic. As for the audio, yes r3mix is a great switch, but if you have the room, you may want to consider just dropping in the 5.1 channel Dolby Digital track. A true 5.1 channel stream at 384 or 448kbps can do wonders for viewing please :).

You can't alter the output like you can with a photo (at least I don't think you can).

I'd have to agree about *clean* animation, such as recent Disney/Pixar/etc. They compress extremely well.

cheers,

foo

duartix
31st January 2002, 13:24
Since the XVid codec features DRF (frame Detail Removal Factor) levels as low as 1 - divX 3.11 and divX 4 lowest DRF is 2 - you can still have your quality and filesize increased.

Tell us if it worked then.

Sharkbyte
31st January 2002, 18:47
Last night I encoded it with Sharp Bicubic and I also lowered the maximum key frame interval to 200ms instead of 300ms. Now the filesize was ~900MB, with sound 995MB. The picture looks great now, no more blurryness ! The extra time it took to encode is also pretty low: 40 minutes extra TOTAL. Pretty reasonable for sharp picture.

Some questions: can I insert a VBR MP3 sound track AND a AC3 soundtrack ? So that I have a stereo MP3 track and an AC3 5.1 track ?

Can I also improve the quality and thus filesize some more with the max./min. quantizer settings and rate control settings ? Picture of the screen (http://www.doom9.org/images/divx-config.gif)
Because the guide says it doens't alter much.

duartix
1st February 2002, 12:02
Abut the audio tracks I can't tell you anything (search the audio forum) but abut max/min quantizers (which is basically the same as the DRFs I was talking abut :sly:, no I'm not canadian :D) I'll say this:

Let me tell something else which you might or mightn't know: The lower the quantizer the better the quality.
So, with DivX4 you can set MAX and MIN quantizers both to 2 but you can't go below that. Now with XVid (which was derived from the OpenDivX project from which the DivX4 codec also derived and has a very similar interface) you can set quantizers as low as 1. So there you have it. A way to increase your file size. Will it increase quality in a visible way? I don't trully know because I don't have a clean animation source to test it upon.

Sharkbyte
1st February 2002, 19:14
I don't want to use another codec, because I occasionly lend my rips to friends and then I always would need to include another codec for every movie (not literally :) ), I usually stick to the latest codec that's popular. The movie is quite sharp now, by using Sharp Bicubic. Only the sound is a problem. I want to insert the AC3 stream directly and also the Dolby ProLogic Compatible Stereo stream as an MP3. But that's for the audio forum where I will post my question (I'll first read the guids ;) ).

Thanx for all the info people, you are really helpful !

pnl
3rd February 2002, 19:39
There is already an option for that in Gknot in the Bitrate tab (mp3 +ac3)