Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Video Encoding > MPEG-4 ASP

Reply
 
Thread Tools Search this Thread Display Modes
Old 15th April 2017, 03:48   #21  |  Link
Katie Boundary
Registered User
 
Katie Boundary's Avatar
 
Join Date: Jan 2015
Posts: 1,048
1.3.4

I'm currently converting season 2 of Modern Family to VCD-compliant Mpeg-1, but once that's done, I'll dust off some of ye olde Andromeda or Birds of Prey scripts and see if changing the minimum quantizer from 1 to 2 has much of an effect.
__________________
I ask unusual questions but always give proper thanks to those who give correct and useful answers.
Katie Boundary is offline   Reply With Quote
Old 15th April 2017, 09:59   #22  |  Link
Sharc
Registered User
 
Join Date: May 2006
Posts: 3,997
Quote:
...and see if changing the minimum quantizer from 1 to 2 has much of an effect.
It depends on the matrix. See for example the discussion here
http://forum.doom9.org/showthread.ph...775#post787775
Looking forward to seeing your findings.
Sharc is offline   Reply With Quote
Old 16th April 2017, 22:47   #23  |  Link
Katie Boundary
Registered User
 
Katie Boundary's Avatar
 
Join Date: Jan 2015
Posts: 1,048
Unfortunately, upping the minimum quantizer did not fix the problem.
__________________
I ask unusual questions but always give proper thanks to those who give correct and useful answers.
Katie Boundary is offline   Reply With Quote
Old 16th April 2017, 23:10   #24  |  Link
Sharc
Registered User
 
Join Date: May 2006
Posts: 3,997
Same problem with single-pass and target bitrate?
Sharc is offline   Reply With Quote
Old 17th April 2017, 15:09   #25  |  Link
hello_hello
Registered User
 
Join Date: Mar 2011
Posts: 4,823
Katie probably won't read this post, or pretend not to, because I think I'm one of the "other forum members" she refers to in her signature which means I'm on her ignore list so I can't learn from her reading my posts..... or however it works according to her signature...... but...
she probably should try what I did here and run a CQ2.0 single pass encode to see what the resulting bitrate will be, and whether it's in the same ballpark as the bitrate she's using for 2 pass encoding. Or she could at least run a compression test. I'd explain how to run one but I probably haven't got it wrong enough to learn how.... or however it works according to her signature..... but it's just guessing without any further details.

I played around a little more with the sample I'd been using for testing a couple of days ago, and this time Xvid wasn't overshooting the requested bitrate. After hunting through log files to see WTF, it turned out I somehow reset the overflow percentage. I don't remember doing that, but with it increased to 10% again today the target bitrate was almost exact.

Highlights from yesterday's log file:

Quote:
--[Information] [14/04/17 7:09:27 PM] Avisynth input script
--[Information] [14/04/17 7:09:27 PM] resolution: 960x396
--[Information] [14/04/17 7:09:27 PM] frame rate: 24000/1001
--[Information] [14/04/17 7:09:27 PM] aspect ratio: 80:33 (2.424)
--[Information] [14/04/17 7:09:27 PM] custom command line: -vbvsize 3145728 -vbvmax 4854000 -vbvpeak 2359296
--[Information] [14/04/17 7:09:27 PM] Job command line: "C:\Program Files\MeGUI\tools\xvid_encraw\xvid_encraw.exe" -i "D:\Test.avs" -o "D:\h263.m4v" -pass2 "D:\h263.stats" -bitrate 2000 -max_key_interval 240 -max_bframes 1 -bvhq -masking 2 -imin 1 -bmin 1 -pmin 1 -par 1 -vbvsize 3145728 -vbvmax 4854000 -vbvpeak 2359296
--[Information] [14/04/17 7:09:49 PM] Final statistics
---[Information] [14/04/17 7:09:49 PM] Video Bitrate Desired: 2000 kbit/s
---[Information] [14/04/17 7:09:49 PM] Video Bitrate Obtained (approximate): 2936 kbit/s
And today's:

Quote:
--[Information] [17/04/17 10:01:35 PM] Avisynth input script
--[Information] [17/04/17 10:01:35 PM] resolution: 960x396
--[Information] [17/04/17 10:01:35 PM] frame rate: 24000/1001
--[Information] [17/04/17 10:01:35 PM] aspect ratio: 80:33 (2.424)
--[Information] [17/04/17 10:01:35 PM] custom command line: -vbvsize 3145728 -vbvmax 4854000 -vbvpeak 2359296
--[Information] [17/04/17 10:01:35 PM] Job command line: "C:\Program Files\MeGUI\tools\xvid_encraw\xvid_encraw.exe" -i "D:\Test.avs" -o "D:\Test megui 2050.m4v" -pass2 "D:\Test megui 2050.stats" -bitrate 2050 -max_key_interval 240 -ostrength 10 -oimprove 10 -odegrade 10 -max_bframes 1 -bvhq -masking 2 -imin 1 -bmin 1 -pmin 1 -par 1 -vbvsize 3145728 -vbvmax 4854000 -vbvpeak 2359296
--[Information] [17/04/17 10:01:51 PM] Final statistics
---[Information] [17/04/17 10:01:51 PM] Video Bitrate Desired: 2050 kbit/s
---[Information] [17/04/17 10:01:51 PM] Video Bitrate Obtained (approximate): 2058 kbit/s
That's Xvid 1.3.4.

Out of curiosity, I tried the same encode using AutoGK and Xvid 1.2.1. AutoGK wasn't happy about the bitrate.

Quote:
[17/04/17 10:06:48 PM] Custom resolution settings: fixed width of 960 pixels
[17/04/17 10:06:48 PM] Standalone support enabled: ESS
[17/04/17 10:06:48 PM] Started encoding.
[17/04/17 10:06:48 PM] Source resolution: 960x396
[17/04/17 10:06:48 PM] Source fps: 23.976
[17/04/17 10:06:48 PM] Output will contain 1001 frames
[17/04/17 10:06:48 PM] Using VAQ in XviD
[17/04/17 10:06:48 PM] Overhead: 0 bytes (0.00 Mb)
[17/04/17 10:06:48 PM] Video size: 10,485,760 bytes (10.00 Mb)
[17/04/17 10:06:48 PM] Running compressibility test.
[17/04/17 10:06:48 PM] Writing the following script to D:\agk_tmp\test 2050_agk_comptest.avs
===========================================================
[17/04/17 10:07:10 PM] Duration was: 21 seconds
[17/04/17 10:07:10 PM] Speed was: 46.59 fps.
[17/04/17 10:07:10 PM] Compressibility percentage is: 191.70
[17/04/17 10:07:10 PM] Using sharper matrix
[17/04/17 10:07:10 PM] Switching b-frames off
[17/04/17 10:07:10 PM] Chosen resolution is: 960x400 ( AR: 2.40 )
[17/04/17 10:07:10 PM] Predicted comptest value is: 129.65%
[17/04/17 10:07:10 PM] Running first pass.
[17/04/17 10:07:10 PM] Writing the following script to D:\agk_tmp\test 2050_agk_movie.avs
===========================================================
[17/04/17 10:07:31 PM] Duration was: 20 seconds
[17/04/17 10:07:31 PM] Speed was: 47.70 fps.
[17/04/17 10:07:31 PM] Expected quality of first pass size: 133.54%
[17/04/17 10:07:31 PM] Trying to adjust settings.
[17/04/17 10:07:31 PM] No adjustment is possible
[17/04/17 10:07:31 PM] Warning: final AVI will likely be undersized.
[17/04/17 10:07:31 PM] Running second pass.
[17/04/17 10:07:52 PM] Duration was: 20 seconds
[17/04/17 10:07:52 PM] Speed was: 47.70 fps.
[17/04/17 10:07:52 PM] Job finished. Total time: 1 minute, 3 seconds
It lied about using the sharper (mpeg) matrix, probably because I have the most strict hardware compatibility setting enabled, but the resulting bitrate was 1438kbps, however visually it wasn't that far off the encode I ran at 2050kbps in respect to detail retention. Maybe about 95%, but the bitrate was about 600kbps less.

AutoGK doesn't set the min quantizer to 1. Instead, when the quality is high, it actually does this (for lower quality it might reduce the min and max to 2 and 4 respectively etc.)....
Would the following really force the same quantizer for all frames (assuming B-Frames were still enabled)?


Last edited by hello_hello; 17th April 2017 at 15:11.
hello_hello is offline   Reply With Quote
Old 16th August 2017, 15:31   #26  |  Link
Katie Boundary
Registered User
 
Katie Boundary's Avatar
 
Join Date: Jan 2015
Posts: 1,048
Old thread, but I thought I'd let you all know how I ultimately fixed the problem:

Remember when upping a few key variables from 5% to 10% helped a little bit, but not enough? Well, I tried cranking them up to around 50% to see what would happen... and that worked! Now I'm playing around with restricting the range of permitted quantizers in order to minimize the "spoiling" of the quantizer distribution.

Special thanks to Selur for providing the one response that was actually helpful.
__________________
I ask unusual questions but always give proper thanks to those who give correct and useful answers.
Katie Boundary is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 13:44.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.