GPUOpen-LibrariesAndSDKs / AMF

The Advanced Media Framework (AMF) SDK provides developers with optimal access to AMD devices for multimedia processing
Other
603 stars 151 forks source link

Feature Request for future AMF version #151

Closed Xaymar closed 4 years ago

Xaymar commented 5 years ago

I'd like to see the following features in the future for AMF. These might all not be possible on older generations, but that is pretty much expected when making an encoder better.

Features

Region of Interest (ROI) for encoding

This feature would allow a user/developer to specify the region of interest for encoding, so as to focus most of the bitrate in that region. Some encoders allow up to four regions, with the priority being the order in which they were specified in. This region should be specified per frame.

Sub-feature: Region of no Interest (RONI)

This is something I came up with and basically is the opposite of ROI. In this region, the encoder should attempt to allocate the least bits, or even outright skip those macroblocks and just make it copy one of the reference macroblocks or LTR macroblocks.

Sub-feature: Reference Region (RR)

Used to specify a region which should be using another frame as reference, either LTR or the last keyframe.

Per-Frame QP Limits

It would be great if the user/developer has a way to specify a specific compression limit per frame in addition to the one specified globally. By doing this it would be possible to create an assisted encoder that uses some GPU time to figure out the best compression, essentially making a lookahead pass possible with AMF.

Why?

With these features exposed, a user/developer could work on drastically improving the AMD encoding quality beyond x264 superfast, as it currently falls way short of x264 superfast. A lookahead pass would allow controlling the bitrate into better regions and even allow better control of QP per frame, so that overall the quality should land somewhat above x264 superfast or at least be equal to x264 superfast.

MikhailAMD commented 5 years ago

I cannot comment on upcoming features but I understand the need. We've got many requests like this and I am working with codec team. Note that LTR feature is supported.