Google在Android Q 引入Codec 2.0 ,与MediaCodec 合作,用于decoding/encoding,之前的版本是MediaCodec 与ACodec/OMX 合作来进行decoding/encoding,两种Flow并存,通过debug.stagefright.ccodec 这个property 以及rank 来决定使用哪个flow。
1.debug.stagefright.ccodec
AndroidS 下,这个property 有5个值,分别定义如下。
Codec2InfoBuilder.cpp
// debug.stagefright.ccodec supports 5 values.
// 0 - No Codec 2.0 components are available.
// 1 - Audio decoders and encoders with prefix "c2.android." are available
// and ranked first.
// All other components with prefix "c2.android." are available with
// their normal ranks.
// Components with prefix "c2.vda." are available with their normal
// ranks.
// All other components with suffix ".avc.decoder" or ".avc.encoder"
// are available but ranked last.
// 2 - Components with prefix "c2.android.&#