AVCaptureDevice.RequestAccessForMediaTypeAsync 方法

定义

重载

RequestAccessForMediaTypeAsync(NSString)

如有必要,请求应用程序用户的权限来捕获 avMediaTypeToken

RequestAccessForMediaTypeAsync(AVAuthorizationMediaType)

RequestAccessForMediaTypeAsync(NSString)

如有必要,请求应用程序用户的权限来捕获 avMediaTypeToken

[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.iOS, 7, 0, ObjCRuntime.PlatformArchitecture.All, null)]
[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.MacOSX, 10, 14, ObjCRuntime.PlatformArchitecture.Arch64, null)]
public static System.Threading.Tasks.Task<bool> RequestAccessForMediaTypeAsync (Foundation.NSString avMediaTypeToken);
static member RequestAccessForMediaTypeAsync : Foundation.NSString -> System.Threading.Tasks.Task<bool>

参数

avMediaTypeToken
NSString

请求访问的媒体类型。 应为 中定义的值。

返回

表示异步 RequestAccessForMediaType 操作的任务。 TResult 参数的值为 AVFoundation.AVRequestAccessStatus。

属性

适用于

RequestAccessForMediaTypeAsync(AVAuthorizationMediaType)

[ObjCRuntime.Introduced(ObjCRuntime.PlatformName.iOS, 7, 0, ObjCRuntime.PlatformArchitecture.All, null)]
public static System.Threading.Tasks.Task<bool> RequestAccessForMediaTypeAsync (AVFoundation.AVAuthorizationMediaType mediaType);
static member RequestAccessForMediaTypeAsync : AVFoundation.AVAuthorizationMediaType -> System.Threading.Tasks.Task<bool>

参数

返回

属性

适用于