One Logo Pool Ball
CreateMLComponents · IOS API REFERENCE

VideoReader

struct · iOS 16.0+ · SDK 27.1

struct VideoReader

A video file reader.

Members (5)

static · iOS 16.0+

readCamera

TypeScript
static readCamera(configuration: VideoReader_CameraConfiguration): Promise<VideoReader_CameraAsyncBuffers>
Swift declaration
static func readCamera(configuration: VideoReader.CameraConfiguration) async throws -> VideoReader.CameraAsyncBuffers

Reads an async sequence of video frames captured with a video camera. - Parameter configuration: The camera configuration - Returns: An async sequence of camera video frames.

static · iOS 16.0+

read

TypeScript
static readContentsOf(url: string): Promise<VideoReader_AsyncFrames>
Swift declaration
static func read(contentsOf url: URL) async throws -> VideoReader.AsyncFrames

Reads a video file as an async sequence of video frames. - Parameter url: A video file URL. - Returns: An async sequence of `VideoFrames`.

static · iOS 16.0+

read

TypeScript
static read(files: Array<string>): Promise<Array<VideoReader_AsyncFrames>>
Swift declaration
static func read<S>(_ files: S) async throws -> [VideoReader.AsyncFrames] where S : Sequence, S.Element == URL

Reads a sequence of files as an array of async sequences of video frames. - Parameter files: A sequence of URLs. - Returns: An array of async sequences of video frames.

method · iOS 16.0+

applied

TypeScript
applied(url: string, eventHandler?: (((arg0: Event) => void)) | null): Promise<VideoReader_AsyncFrames>
Swift declaration
func applied(to url: URL, eventHandler: EventHandler?) async throws -> VideoReader.AsyncFrames

Reads a video file as an async sequence of video frames. - Parameters: - url: A video file URL. - eventHandler: An event handler. - Returns: An async sequence of `VideoFrames`.

init · iOS 16.0+

init

TypeScript
static init(): VideoReader
Swift declaration
init()

Creates a video reader.

Skipped declarations

1 declarations were excluded from these bindings. Each reason comes from the generator or the iOS SDK compiler.

VideoReader.read(_:)

This declaration needs Swift generic type arguments. (no canonical witness for Annotation)

All CreateMLComponents types →