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 > High Efficiency Video Coding (HEVC)

Reply
 
Thread Tools Search this Thread Display Modes
Old 8th May 2023, 04:11   #1  |  Link
HD MOVIE SOURCE
Registered User
 
HD MOVIE SOURCE's Avatar
 
Join Date: Mar 2021
Location: North Carolina
Posts: 138
IP BP Ratios - Hurt Iframe Quality?

Hi,

If you go below 1.0, like ipratio=0.90, pbratio=0.90, does this hurt iframe quality?

Or a different question is, does this allow more data to be pushed into p and b frames. And yes it lowers iframe quality, but allows a much higher quality of p and b frames?

Another thought I've had is, does lowering beyond 1 hurt reference frame quality? Or does using P and B frames as reference frames clear up that issue?


My thought here is to shift some of the data hog that an iframe represents and push slightly higher into p and b frames because they offer much high compression. And with x265, p and bframe quality is exceptionally good.

Thanks
HD MOVIE SOURCE is offline   Reply With Quote
Old 17th May 2023, 18:29   #2  |  Link
benwaggoner
Moderator
 
Join Date: Jan 2006
Location: Portland, OR
Posts: 4,750
Quote:
Originally Posted by HD MOVIE SOURCE View Post
Hi,

If you go below 1.0, like ipratio=0.90, pbratio=0.90, does this hurt iframe quality?
It absolutely would if VBV limited. I've never tried values <1.0, and struggle to think of any scenario where that would be beneficial.

Quote:
Or a different question is, does this allow more data to be pushed into p and b frames. And yes it lowers iframe quality, but allows a much higher quality of p and b frames?
P and B frames will reference the I-frame, so poor quality there gets rippled through the GOP. It's almost always better to optimize quality more the higher up in the reference hierarchy a frame is, as those benefit the most dependent frames. So I>P>B>b. For grainy content having the ratios smaller can help reduce strobing, but the cleaner the content, the bigger default ratios are optimum.

Quote:
Another thought I've had is, does lowering beyond 1 hurt reference frame quality? Or does using P and B frames as reference frames clear up that issue?
I would not expect it to be helpful. You can test and report your findings.


Quote:
My thought here is to shift some of the data hog that an iframe represents and push slightly higher into p and b frames because they offer much high compression. And with x265, p and bframe quality is exceptionally good.
Ah! I frames aren't data hogs because they are worse somehow. They are data hogs because they are all intra coded. Intra needs to be coded somewhere! If a reference frame is poorer quality, then frames that reference it need to spend more bits to "repair" that quality, and rarely get as good as if they started with a clean reference. Pushed far enough, you'd wind up with having more intra coded blocks in P and B frames because the I frame was a poor reference, and that's using more bits than getting the I frame correct in the first place.
__________________
Ben Waggoner
Principal Video Specialist, Amazon Prime Video

My Compression Book
benwaggoner is offline   Reply With Quote
Old 24th May 2023, 13:28   #3  |  Link
PoeBear
Registered User
 
Join Date: Jan 2017
Posts: 48
Quote:
Originally Posted by benwaggoner View Post
P and B frames will reference the I-frame, so poor quality there gets rippled through the GOP. It's almost always better to optimize quality more the higher up in the reference hierarchy a frame is, as those benefit the most dependent frames. So I>P>B>b
I understand the ranking of the frame types, but how far are the gaps between each ranking, which is more important to focus on? When encoding something, and it gives out QP values in my log, if we're targeting something near transparent, would we want the the P-frames closer in QP value to the I-frames, or the B-frames closer in QP value to the P-frames, or should their numerical QP value gap be equal in both directions? Or that something that would change based on the source-type? Like would grainy movies would be better to have similar gap sizes, and animation would be better to have a larger gap between B and P, and smaller between I and P? Or vice-versa
PoeBear is offline   Reply With Quote
Old 26th May 2023, 02:25   #4  |  Link
benwaggoner
Moderator
 
Join Date: Jan 2006
Location: Portland, OR
Posts: 4,750
Quote:
Originally Posted by PoeBear View Post
I understand the ranking of the frame types, but how far are the gaps between each ranking, which is more important to focus on? When encoding something, and it gives out QP values in my log, if we're targeting something near transparent, would we want the the P-frames closer in QP value to the I-frames, or the B-frames closer in QP value to the P-frames, or should their numerical QP value gap be equal in both directions? Or that something that would change based on the source-type? Like would grainy movies would be better to have similar gap sizes, and animation would be better to have a larger gap between B and P, and smaller between I and P? Or vice-versa
The noisier the content, the lower --ipratio and --pbratio should be. Clean animation can be higher, given lots of repeated frames and repeated elements between frames.

Generally --ipratio will be lower than --pbratio.
__________________
Ben Waggoner
Principal Video Specialist, Amazon Prime Video

My Compression Book
benwaggoner 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 16:31.


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