Post Reply 
MPEG-4 AVC/AAC
Perfect format?
Author Message
bboy_sonik
Byeeeeeeeeee

Posts: 132.3019
Threads: 8
Joined: 9th Aug 2007
Reputation: 0.76198
E-Pigs: 2.8344
Offline
Post: #1
MPEG-4 AVC/AAC
Quick post. Nothing specific, looking for a discussion. I do know quite a bit about video encoding, and I want to start using AVC instead of DivX and/or MKV for my personal video/movie collection.

Sadly, I don't have "the original copy" for some of these videos, and they are already compressed - i know that converting from one lossy codec to another lossy codec is a BAD thing to do for quality, but I REALLY want my videos to play on PSP, PC and PS3 natively! Plus, AVC is 10 times more advanced than DivX or XviD too :D

So I'm wondering if anyone has any tips or advice in this regard. In particular, I use TMPGEnc 4 Xpress to create my AVC videos for the PSP with the settings below - if anyone has any tips/corrections/optimizations for what I use, let me know what you think is best!

Also, does anyone know of a video file freely downloadable that is really good for comparing video conversion quality and stuff? You know like... something high-def with lots of motion and everything that'd really "stress" codecs quality level and can give a good indication of just how efficient and effective the video format is at certain bitrates. I hope that makes sense.

Oh ONE LAST THING; does anybody know what the FULL FORMAT SUPPORT is for the PSP v5.00 firmware???? I had to guess my AVC encoder settings and trial-and-error to get it to work and don't know if its the best encode! Anyway those TMPGEnc 4 settings are here...

Code:
1
2
3
4
5
6
7
MPEG-4 AVC [480 x 272, 25 fps, 2 pass Variable bitrate 1024 kb/s (max. 2048 kb/s)]
 - Profile = Main [other options are Baseline and High]
 - Level = Level 3 [IT GOES UP TO 5.1 WHY CANT THE PSP SUPPORT A HIGHER LEVEL]
 - Size = 480x272 [I want it to be higher but then it the PSP cant play it right.....?]
 - Other = 16:9, 25fps progressive, motion search range 64
 - AVC SPECIFIC = GOP Length at 33; B frame count at 0; Reference grame count at 1; Quantiziations 24/25/27 [I Picture/P Picture/B Picture]; entropy encoding CABAC [better and newer than CAVLC]; and motion estimation subpel mode is quarter pixel.
AAC audio, doesnt matter what it is its VIDEO i'm worried about and AVC only supports AAC audiostream in the same MP4 container anyway.



Thanks in advance guys. While I wait for a reply, I will read the "MPEG-4 AVC/H.264 Information" article and learn more about the technicals, found here. Peace! :)

01/11/2008 07:49 PM
Find all posts by this user Quote this message in a reply
ZiNgA BuRgA
Smart Alternative

Posts: 17,023.4213
Threads: 1,174
Joined: 19th Jan 2007
Reputation: -1.71391
E-Pigs: 446.0333
Offline
Post: #2
RE: MPEG-4 AVC/AAC
bboy_sonik Wrote:So I'm wondering if anyone has any tips or advice in this regard. In particular, I use TMPGEnc 4 Xpress to create my AVC videos for the PSP with the settings below - if anyone has any tips/corrections/optimizations for what I use, let me know what you think is best!
x264 is one of the best H.264 encoders out there - dunno what your TMPGEnc is using.

bboy_sonik Wrote:Oh ONE LAST THING; does anybody know what the FULL FORMAT SUPPORT is for the PSP v5.00 firmware???? I had to guess my AVC encoder settings and trial-and-error to get it to work and don't know if its the best encode! Anyway those TMPGEnc 4 settings are here...
Limitations for PSP:
- Main profile
- Level 3.0
- Max reference frames = 3
- Appears to have no b-frame limit
- Resolutions up to 480x272; supports some resolutions above that (640x480, 720x480 and some other one), however, for playback on the PSP, there's no need to exceed 480x272, since that's the size of the PSP screen
- Not sure what framerate limitations it has, but anything under 30fps (majority of videos) should work fine
- Any LC-AAC audio seems to work (probably doesn't accept sampling rates above 48kHz, but I've yet to see anything that exceeds that)



As for efficiency of compression, the rest depends on your preference for quality, and how slow you're willing to make the encoder go.
02/11/2008 12:39 AM
Visit this user's website Find all posts by this user Quote this message in a reply
bboy_sonik
Byeeeeeeeeee

Posts: 132.3019
Threads: 8
Joined: 9th Aug 2007
Reputation: 0.76198
E-Pigs: 2.8344
Offline
Post: #3
RE: MPEG-4 AVC/AAC
Cheers :) So most of my settings are true. In regards to Reference Frames, is setting it to anything above 1 benificial at all? Or would I be better off asking such a question on doom9 do you think? Everything else is pretty much what I already use :) and TMPGEnc uses CoreAVC I was told. They recently added AVCHD support :D now all i need is a BluRay burner....!

Well thanks for the feedback. AVC does indeed encode slowly [GREAT compression though] and I will definately have to do some tests as to what I decide is best :)
02/11/2008 02:24 AM
Find all posts by this user Quote this message in a reply
Assassinator
...

Posts: 6,646.6190
Threads: 176
Joined: 24th Apr 2007
Reputation: 8.53695
E-Pigs: 140.8363
Offline
Post: #4
RE: MPEG-4 AVC/AAC
bboy_sonik Wrote:In regards to Reference Frames, is setting it to anything above 1 benificial at all?

Definitely.

bboy_sonik Wrote:Or would I be better off asking such a question on doom9 do you think? Everything else is pretty much what I already use :) and TMPGEnc uses CoreAVC I was told. They recently added AVCHD support :D now all i need is a BluRay burner....!

No, CoreAVC is a decoder, not encoder. CoreAVC can't encode.
02/11/2008 03:29 AM
Find all posts by this user Quote this message in a reply
bboy_sonik
Byeeeeeeeeee

Posts: 132.3019
Threads: 8
Joined: 9th Aug 2007
Reputation: 0.76198
E-Pigs: 2.8344
Offline
Post: #5
RE: MPEG-4 AVC/AAC
Yeah i checked it out my source was a douche, it uses the MainConcept technology to encode MPEG-4 ISO/AVC which did have non-compliency problems in the past but has been long fixed and is now nice and good. Failing to find a "better" encoder - by that I mean one can encode higher quality than others, speed aint an issue. In my own tests, I used the exact same options in the TMPGEnc/MainConcept encoder and the x264 one, but MainConcept encode seemed to handle super-high motion/action better. I think that might be because TMPGEnc has better 'scene change detection' though and that's not a codec thing its the VME technology in TMPGEnc that handles that but x264 is definately better than every other commercial AVC encoder I've tried! Its actually a little faster than what im using :) but quality is more important to me.

OK, i will try Reference frames to 3 and compare :) thanks

Well I want the HIGHEST quality and have ZERO care about encoding speed so if anyone has any tips on how to "encode slower" let me know! I am using 2-pass VBR, and my "Medium Quality" profile is 1024kbps average and 2048kbps max, Motion Search Range I have changed from 64 to 256 [good?]

Also I know that it REALLY depends on the source or what is actually 'in' the video, as to the "best" settings to use... but I'm just trying to get a rough idea here. Will try some more personal tests and comparisons tonight. Thanks guys :)

EDIT: I know I said HIGHEST quality but space is also important to me as I only have a 2GB stick and don't have a massive harddisk either [320GB] hence why i decided to use H.264 instead of DivX - to get higher quality at lower bitrates ;)

P.S. Assassinator, your Sig is very cool! What's that from? I don't know much anime :)
(This post was last modified: 04/11/2008 01:38 AM by bboy_sonik.)
04/11/2008 01:37 AM
Find all posts by this user Quote this message in a reply
blessedhands
Paradigmatic Entity

Posts: 199.7880
Threads: 18
Joined: 15th Dec 2007
Reputation: -1.64513
E-Pigs: 26.8526
Offline
Post: #6
RE: MPEG-4 AVC/AAC
i am using gomencoder. it has better quality when converting cartoons(anime). i havent tried encoding with higher settings(1024 bitrate, 2 pass) like you do. but i think the output format will not turn you down. i encoded some of my movies at 380 kbps and the output is still above acceptable. it supports subtitles to be hardsubbed to the output file. check it out at gomlab.com. the best of all its free.

i tried using tmgpenc encoding my bleach series(i used the same settings when encoding with gom), it is damn slow T_T (compared to gomencoder)  and still gives  me a crappy ouput.
04/11/2008 02:56 AM
Visit this user's website Find all posts by this user Quote this message in a reply
bboy_sonik
Byeeeeeeeeee

Posts: 132.3019
Threads: 8
Joined: 9th Aug 2007
Reputation: 0.76198
E-Pigs: 2.8344
Offline
Post: #7
RE: MPEG-4 AVC/AAC
OK I've downloaded GOM Encoder and given it a shot. Here are my comments in order of discovery:

- It is only a Beta, and a Demo [puts a watermark on the first 10 seconds of video]
- It uses the term "Keyframe" under the AVC encoder. AVC video doesn't have keyframes, only ASP video does [DivX, XviD, etc] which is the predecessor to AVC. AVC takes the IBP frames and GOP length to make psuedo keyframes
- The AAC encoder is confusing, what the hell is Quality 30 @ 192kbps compared to Quality 100 @ 192kbps???
- "Create an MP4 file that's playable on the PSP" option worries me. Only pre-2.80 firmwares needed a special container, after that they were 100% compatible with the AVC ISO standard [with some restrictions of course due to the portable/low power nature of the PSP eg max level 3, etc]. I unticked that because then it wouldnt be playable on 360, Quicktime/Apple devices, etc.
- Doesn't support 640x480 with a pixel ratio of 16:9 which is what I REALLY LIKE TO USE. Why? It's a good high resolution, and even though its a 4:3 resolution any display that has a 16:9 screen will draw it properly without having to press "screen mode" or "zoom" on the TV/console, and anything that Isn't 4:3 will still draw in letterbox [the black bars]. It's extremely handy.
- Doesn't support changing of quantizations or reference frame count. I assume it does all this for you according to the "Keyframe" so im going to set Keyframe to "1 second".
- Has nowhere near the power of TMPGEnc in regards to subtitle burning, filters, plugins, etc. BUT the Winamp DSP support is actually pretty cool on the audio side of things.

I encoded the same video as I have been in my tests and with all settings as close as I could between the two. Here were the results:
- Encoding actually took about 30 seconds longer for me. But its Beta so i guess that's not an issue. And of course that's not much difference - im sure it varies from computer to computer dramatically.
- Fastforwarding and rewinding with my player and decoder [Media Player Classic Homecinema, Cyberlink H.264 decoder with nVidia PureVideo SD/HD GPU Acceleration] didn't work. I've experienced this with other MP4 encoders when trying to play them on the PC.
- The quality was, yes, actually pretty good. But it was ~700kb bigger than the file TMPGEnc produced? The Audio and Video were the same quality so I'm a little confused. It handled motion a little better, but dark scenes a little worse. [Less blocking in the super fast shooting scene, but more blocking on the sneaking in the dark scene].

AFTER ANALYSING with AVInaptic i found that the GOM Encoder outputs an "Apple QuickTime movie" container as opposed to "MP4/MOV" container. Odd.


Regardless, thanks a lot for your suggestion blessedhands. Even though I'll pass on GOM Encoder as I don't want to pay for it, you have made me realize that the MainConcept/TMPGEnc encoder might not be the best after all! I am going to spend a few more days researching this ;) peace
04/11/2008 04:58 AM
Find all posts by this user Quote this message in a reply
squee666
Grand Warlock

Posts: 3,566.4225
Threads: 351
Joined: 4th May 2007
Reputation: 12.17831
E-Pigs: 555.8899
Offline
Post: #8
RE: MPEG-4 AVC/AAC
ok lets just settle this

if you want quality and an encoder that's free

use xvid4psp

or use what sensei uses MeGui

[Image: IuZelj2.png]
Spoiler for anime watched:
[Image: squee666.jpg]
04/11/2008 05:07 AM
Find all posts by this user Quote this message in a reply
blessedhands
Paradigmatic Entity

Posts: 199.7880
Threads: 18
Joined: 15th Dec 2007
Reputation: -1.64513
E-Pigs: 26.8526
Offline
Post: #9
RE: MPEG-4 AVC/AAC
bboy_sonik Wrote:- The quality was, yes, actually pretty good. But it was ~700kb bigger than the file TMPGEnc produced? The Audio and Video were the same quality so I'm a little confused. It handled motion a little better, but dark scenes a little worse. [Less blocking in the super fast shooting scene, but more blocking on the sneaking in the dark scene].

you noticed its quality in dark scenes, i thought it was because i encoded my vids at lower bitrates(now you proved me wrong..xD). and deblocking is really troublesome. that's why i only use it for my cartoon series which i am not really bothered by its quality.

hey by the way, i tried TMGEnc, played with the settings, encoded a full movie, and im quite satisfied with it. i use 1 pass constant quantization instead of my previous (1 pass constant), I Picture/P Picture/B Picture = 27, motion detection i set it to 256 i guess. video length 1:46:00(apprx) encoding time 1:42:00 almost 1.0x speed

i guess for movies ill use tmpgenc and for my cartoon series ill use gomencoder(still a lot faster for me, i encoded nine 20-min long episodes for about 1 hr and 20 min long)

mind sharing your avrge encoding speed? do you know how to add subs in TMPGenc?

squee666 Wrote:ok lets just settle this

if you want quality and an encoder that's free

use xvid4psp

or use what sensei uses MeGui

Xvid4PSP has audio sync Issue. i don't know if im the only one experiencing it though.
(This post was last modified: 04/11/2008 06:00 AM by blessedhands.)
04/11/2008 05:57 AM
Visit this user's website Find all posts by this user Quote this message in a reply
squee666
Grand Warlock

Posts: 3,566.4225
Threads: 351
Joined: 4th May 2007
Reputation: 12.17831
E-Pigs: 555.8899
Offline
Post: #10
RE: MPEG-4 AVC/AAC
blessedhands Wrote:Xvid4PSP has audio sync Issue. i don't know if im the only one experiencing it though.

that is solved if you use 44.1k vbr audio and vbr video


but for normal CBR encodes i advise to decode with FFDSHOW it solves all my audio desync problems

ecenthough i don't seem to get them any more

decodng with FFDSHOW also solvethat frameskip jump for the first few seconds i used to get

[Image: IuZelj2.png]
Spoiler for anime watched:
[Image: squee666.jpg]
04/11/2008 06:05 AM
Find all posts by this user Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)

 Quick Theme: