Stay organized with collections Save and categorize content based on your preferences.

MediaItem.ClippingConfiguration

class MediaItem.ClippingConfiguration : Bundleable

Known direct subclasses
MediaItem.ClippingProperties

This class is deprecated.

Use ClippingConfiguration instead.


Optionally clips the media item to a custom start and end position.

Summary

Nested types

class MediaItem.ClippingConfiguration.Builder

Builder for ClippingConfiguration instances.

Constants

const Bundleable.Creator<MediaItem.ClippingProperties!>!

Object that can restore ClippingConfiguration from a Bundle.

const MediaItem.ClippingConfiguration!

A clipping configuration with default values.

Public constructors

Public functions

MediaItem.ClippingConfiguration.Builder!

Returns a Builder initialized with the values of this instance.

Boolean
equals(obj: Any?)
Int
Bundle!

Returns a Bundle representing the information stored in this object.

Public properties

Long

The end position in milliseconds.

Boolean

Whether startPositionMs and endPositionMs are relative to the default position.

Boolean

Whether the clipping of active media periods moves with a live window.

@IntRange(from = 0) Long

The start position in milliseconds.

Boolean

Sets whether the start point is guaranteed to be a key frame.

Constants

CREATOR

@UnstableApi
const val CREATORBundleable.Creator<MediaItem.ClippingProperties!>!

Object that can restore ClippingConfiguration from a Bundle.

UNSET

const val UNSETMediaItem.ClippingConfiguration!

A clipping configuration with default values.

Public constructors

ClippingConfiguration

ClippingConfiguration()

Public functions

buildUpon

fun buildUpon(): MediaItem.ClippingConfiguration.Builder!

Returns a Builder initialized with the values of this instance.

equals

fun equals(obj: Any?): Boolean

hashCode

fun hashCode(): Int

toBundle

@UnstableApi
fun toBundle(): Bundle!

Returns a Bundle representing the information stored in this object.

Public properties

endPositionMs

val endPositionMsLong

The end position in milliseconds. This is a value larger than or equal to zero or TIME_END_OF_SOURCE to play to the end of the stream.

relativeToDefaultPosition

val relativeToDefaultPositionBoolean

Whether startPositionMs and endPositionMs are relative to the default position.

relativeToLiveWindow

val relativeToLiveWindowBoolean

Whether the clipping of active media periods moves with a live window. If false, playback ends when it reaches endPositionMs.

startPositionMs

val startPositionMs: @IntRange(from = 0) Long

The start position in milliseconds. This is a value larger than or equal to zero.

startsAtKeyFrame

val startsAtKeyFrameBoolean

Sets whether the start point is guaranteed to be a key frame.