MediaCodecInfo.CodecCapabilities.FEATURERoi Field
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
<b>video encoder only</b>: codec supports region of interest encoding.
[Android.Runtime.Register("FEATURE_Roi", ApiSince=35)]
public const string FEATURERoi;
[<Android.Runtime.Register("FEATURE_Roi", ApiSince=35)>]
val mutable FEATURERoi : string
Field Value
- Attributes
Remarks
<b>video encoder only</b>: codec supports region of interest encoding.
RoI encoding support means the codec accepts information that specifies the relative importance of different portions of each video frame. This allows the encoder to separate a video frame into critical and non-critical regions, and use more bits (better quality) to represent the critical regions and de-prioritize non-critical regions. In other words, the encoder chooses a negative qp bias for the critical portions and a zero or positive qp bias for the non-critical portions.
At a basic level, if the encoder decides to encode each frame with a uniform quantization value 'qpFrame' and a 'qpBias' is chosen/suggested for an LCU of the frame, then the actual qp of the LCU will be 'qpFrame + qpBias', although this value can be clamped basing on the min-max configured qp bounds for the current encoding session.
In a shot, if a group of LCUs pan out quickly they can be marked as non-critical thereby enabling the encoder to reserve fewer bits during their encoding. Contrarily, LCUs that remain in shot for a prolonged duration can be encoded at better quality in one frame thereby setting-up an excellent long-term reference for all future frames.
Note that by offsetting the quantization of each LCU, the overall bit allocation will differ from the originally estimated bit allocation, and the encoder will adjust the frame quantization for subsequent frames to meet the bitrate target. An effective selection of critical regions can set-up a golden reference and this can compensate for the bit burden that was introduced due to encoding RoI's at better quality. On the other hand, an ineffective choice of critical regions might increase the quality of certain parts of the image but this can hamper quality in subsequent frames.
Java documentation for android.media.MediaCodecInfo.CodecCapabilities.FEATURE_Roi
.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.