VideoMetadata

class VideoMetadata(title: String? = null, duration: Long? = null, width: Int? = null, height: Int? = null, bitrate: Long? = null, frameRate: Float? = null, mimeType: String? = null, audioChannels: Int? = null, audioSampleRate: Int? = null)

Represents metadata information of a video file.

Properties are backed by mutableStateOf so mutations trigger Compose recomposition. This matters when callers update fields in place (e.g. on onVideoSizeChanged or HLS resolution changes) while the metadata instance is read from a composable.

Constructors

Link copied to clipboard
constructor(title: String? = null, duration: Long? = null, width: Int? = null, height: Int? = null, bitrate: Long? = null, frameRate: Float? = null, mimeType: String? = null, audioChannels: Int? = null, audioSampleRate: Int? = null)

Properties

Link copied to clipboard

The number of audio channels in the video's audio track, if available.

Link copied to clipboard

The sample rate of the audio track in the video, measured in Hz.

Link copied to clipboard

The average data rate of the video in bits per second, if known.

Link copied to clipboard

The length of the video in milliseconds, if known.

Link copied to clipboard

The frame rate of the video in frames per second, if available.

Link copied to clipboard
var height: Int?

The height of the video in pixels, if available.

Link copied to clipboard

The MIME type of the video file, indicating the format used.

Link copied to clipboard

The title of the video, if available.

Link copied to clipboard
var width: Int?

The width of the video in pixels, if available.

Functions

Link copied to clipboard
fun copy(title: String? = this.title, duration: Long? = this.duration, width: Int? = this.width, height: Int? = this.height, bitrate: Long? = this.bitrate, frameRate: Float? = this.frameRate, mimeType: String? = this.mimeType, audioChannels: Int? = this.audioChannels, audioSampleRate: Int? = this.audioSampleRate): VideoMetadata
Link copied to clipboard
open operator override fun equals(other: Any?): Boolean
Link copied to clipboard
open override fun hashCode(): Int
Link copied to clipboard

Checks if all properties of this metadata object are null.

Link copied to clipboard
open override fun toString(): String