Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bit rate mode #54

Open
Telecino opened this issue Nov 2, 2021 · 5 comments
Open

Bit rate mode #54

Telecino opened this issue Nov 2, 2021 · 5 comments

Comments

@Telecino
Copy link

Telecino commented Nov 2, 2021

Hi,

First question, is this project still supported?
If so, it would be of great value to everyone to expose the bit rate mode to support "constant" bit rate, It would improve the overall playback instead of the default VBR mode.

Thank you,

Stéphane
https://oasis.im

@VuiMuich
Copy link

VuiMuich commented Nov 2, 2021

I might be wrong but afaik HAP is an intra-frame codec and as such should not suffer from the typical VBR issues, right?

Since each frame is encoded in its own texture image the encoder wouldn't even know about the size of its neighbor frames.

The metadata need to flag it VBR though, exactly because byte sizes of frames may vary.

@Telecino
Copy link
Author

Telecino commented Nov 7, 2021

I might be wrong but afaik HAP is an intra-frame codec and as such should not suffer from the typical VBR issues, right?

Since each frame is encoded in its own texture image the encoder wouldn't even know about the size of its neighbor frames.

The metadata need to flag it VBR though, exactly because byte sizes of frames may vary.

I wish I knew the answer, but I couldn't find any info on the HAP site regarding how its encoding, but you look to be more informed than I.
Thank you for your help,

@VuiMuich
Copy link

VuiMuich commented Nov 8, 2021

You are very welcome.
I can recommend the hap codec documentation for a deeper dive, if you're interested.

And maybe have also a look at the older Adobe Plugin from Vidvox, I believe in this implementation it was stated that HAP entirely relies on input Bitrate in general.

@GregBakker
Copy link
Contributor

GregBakker commented Nov 9, 2021

@VuiMuich is correct - this is a not a variable bitrate codec, and the quality / compression is the same for every frame in the entire export.

One of the goals of this style of codec is that it's easy for playback software to locate and present any frame at will.

@bangnoise
Copy link
Contributor

bangnoise commented Nov 9, 2021

To be clear, the encoded bitrate of Hap does vary due to the use of a secondary compressor - this secondary compressor does a better job of compressing some frames than others, so the bitrate varies between frames.

The bitrate is not, however, variable by the encoder in the sense of VBR: we cannot increase compression to achieve a constant rate at encode time. The secondary compressor is lossless so it can't make the trade-off between visual quality and bitrate that some other codecs can.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

4 participants