语言

MediaCodecInfo.CodecCapabilities.CreateFromProfileLevel 方法

定义

检索特定 mime 类型、配置文件和级别的编解码器功能。

[Android.Runtime.Register("createFromProfileLevel", "(Ljava/lang/String;II)Landroid/media/MediaCodecInfo$CodecCapabilities;", "")]
public static Android.Media.MediaCodecInfo.CodecCapabilities? CreateFromProfileLevel(string? mime, Android.Media.MediaCodecProfileLevel profile, int level);
[<Android.Runtime.Register("createFromProfileLevel", "(Ljava/lang/String;II)Landroid/media/MediaCodecInfo$CodecCapabilities;", "")>]
static member CreateFromProfileLevel : string * Android.Media.MediaCodecProfileLevel * int -> Android.Media.MediaCodecInfo.CodecCapabilities

参数

mime
String

用于生成功能说明的 MIME 类型。

profile
MediaCodecProfileLevel

用作编解码器配置文件标识符的基础整数值。 尽管托管参数使用 MediaCodecProfileLevel 枚举类型,但此值标识配置文件而不是级别。

level
Int32

放置在该描述符中的数字级别标识符。

返回

派生自提供的 MIME 类型和配置文件和级别值(而不是所选编解码器实例)的功能说明。

特性

注解

检索特定 MIME 类型、配置文件和级别的编解码器功能。 根据 Android 版本和实现,无法识别的类型或配置文件级组合可以返回 null 或引发 NullPointerException。 在 Android 6.0 上,在不事先调用 MediaCodecList 类的任何方法的情况下调用此方法会导致 NullPointerException。

Android 参考。android.media.MediaCodecInfo.CodecCapabilities.createFromProfileLevel

本页的某些部分是根据 创建和共享的工作进行的修改,并根据 许可证中所述的条款使用。

适用于