# VideoFrameProcessingException

Artifact: [androidx.media3:media3-common](https://developer.android.com/jetpack/androidx/releases/media3) [View Source](https://cs.android.com/search?q=file:androidx/media3/common/VideoFrameProcessingException.java+class:androidx.media3.common.VideoFrameProcessingException)

*** ** * ** ***


```
@UnstableApi
class VideoFrameProcessingException : Exception
```

<br />

|---|---|---|---|
| [kotlin.Any](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-any/index.html) ||||
| ↳ | [kotlin.Throwable](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/index.html) |||
|   | ↳ | [java.lang.Exception](https://developer.android.com/reference/java/lang/Exception.html) ||
|   |   | ↳ | [androidx.media3.common.VideoFrameProcessingException](https://developer.android.com/reference/kotlin/androidx/media3/common/VideoFrameProcessingException) |

*** ** * ** ***

Thrown when an exception occurs while preparing an `https://developer.android.com/reference/kotlin/androidx/media3/common/Effect`, or applying an `https://developer.android.com/reference/kotlin/androidx/media3/common/Effect` to video frames.

## Summary

| ### Public constructors |
|---|
| `https://developer.android.com/reference/kotlin/androidx/media3/common/VideoFrameProcessingException#VideoFrameProcessingException(java.lang.Throwable)(cause: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/index.html!)` Creates an instance. |
| `https://developer.android.com/reference/kotlin/androidx/media3/common/VideoFrameProcessingException#VideoFrameProcessingException(java.lang.String)(message: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!)` Creates an instance. |
| `https://developer.android.com/reference/kotlin/androidx/media3/common/VideoFrameProcessingException#VideoFrameProcessingException(java.lang.Throwable,long)(cause: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/index.html!, presentationTimeUs: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html)` Creates an instance. |
| `https://developer.android.com/reference/kotlin/androidx/media3/common/VideoFrameProcessingException#VideoFrameProcessingException(java.lang.String,java.lang.Throwable)(message: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!, cause: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/index.html!)` Creates an instance. |
| `https://developer.android.com/reference/kotlin/androidx/media3/common/VideoFrameProcessingException#VideoFrameProcessingException(java.lang.String,long)(message: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!, presentationTimeUs: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html)` Creates an instance. |
| `https://developer.android.com/reference/kotlin/androidx/media3/common/VideoFrameProcessingException#VideoFrameProcessingException(java.lang.String,java.lang.Throwable,long)( message: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!, cause: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/index.html!, presentationTimeUs: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html )` Creates an instance. |

| ### Public functions |
|---|---|
| `java-static https://developer.android.com/reference/kotlin/androidx/media3/common/VideoFrameProcessingException!` | `https://developer.android.com/reference/kotlin/androidx/media3/common/VideoFrameProcessingException#from(java.lang.Exception)(exception: https://developer.android.com/reference/java/lang/Exception.html!)` Wraps the given exception in a `VideoFrameProcessingException` if it is not already a `VideoFrameProcessingException` and returns the exception otherwise. |
| `java-static https://developer.android.com/reference/kotlin/androidx/media3/common/VideoFrameProcessingException!` | `https://developer.android.com/reference/kotlin/androidx/media3/common/VideoFrameProcessingException#from(java.lang.Exception,long)(exception: https://developer.android.com/reference/java/lang/Exception.html!, presentationTimeUs: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html)` Wraps the given exception in a `VideoFrameProcessingException` with the given timestamp if it is not already a `VideoFrameProcessingException` and returns the exception otherwise. |

| ### Public properties |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html` | `https://developer.android.com/reference/kotlin/androidx/media3/common/VideoFrameProcessingException#presentationTimeUs()` The microsecond timestamp of the frame being processed while the exception occurred or `https://developer.android.com/reference/kotlin/androidx/media3/common/C#TIME_UNSET()` if unknown. |

| ### Inherited functions |
|---|
| From [java.lang.Throwable](https://developer.android.com/reference/java/lang/Throwable.html) |---|---| | `synchronized https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/add-suppressed.html(exception: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/index.html!)` | | `synchronized https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/index.html!` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/fill-in-stack-trace.html()` | | `synchronized https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/index.html!` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/get-cause.html()` | | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/get-localized-message.html()` | | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/get-message.html()` | | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://developer.android.com/reference/java/lang/StackTraceElement.html!>!` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/get-stack-trace.html()` | | `synchronized https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/index.html!>!` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/get-suppressed.html()` | | `synchronized https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/index.html!` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/init-cause.html(cause: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/index.html!)` | | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/print-stack-trace.html()` | | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/set-stack-trace.html(stackTrace: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://developer.android.com/reference/java/lang/StackTraceElement.html!>!)` | | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` | `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/to-string.html()` | |

## Public constructors

### VideoFrameProcessingException

```
VideoFrameProcessingException(cause: Throwable!)
```

Creates an instance.

| Parameters |
|---|---|
| `cause: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/index.html!` | The cause of this exception. |

### VideoFrameProcessingException

```
VideoFrameProcessingException(message: String!)
```

Creates an instance.

| Parameters |
|---|---|
| `message: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` | The detail message for this exception. |

### VideoFrameProcessingException

```
VideoFrameProcessingException(cause: Throwable!, presentationTimeUs: Long)
```

Creates an instance.

| Parameters |
|---|---|
| `cause: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/index.html!` | The cause of this exception. |
| `presentationTimeUs: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html` | The timestamp of the frame for which the exception occurred. |

### VideoFrameProcessingException

```
VideoFrameProcessingException(message: String!, cause: Throwable!)
```

Creates an instance.

| Parameters |
|---|---|
| `message: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` | The detail message for this exception. |
| `cause: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/index.html!` | The cause of this exception. |

### VideoFrameProcessingException

```
VideoFrameProcessingException(message: String!, presentationTimeUs: Long)
```

Creates an instance.

| Parameters |
|---|---|
| `message: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` | The detail message for this exception. |
| `presentationTimeUs: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html` | The timestamp of the frame for which the exception occurred. |

### VideoFrameProcessingException

```
VideoFrameProcessingException(
    message: String!,
    cause: Throwable!,
    presentationTimeUs: Long
)
```

Creates an instance.

| Parameters |
|---|---|
| `message: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-string/index.html!` | The detail message for this exception. |
| `cause: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-throwable/index.html!` | The cause of this exception. |
| `presentationTimeUs: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html` | The timestamp of the frame for which the exception occurred. |

## Public functions

### from

```
java-static fun from(exception: Exception!): VideoFrameProcessingException!
```

Wraps the given exception in a `VideoFrameProcessingException` if it is not already a `VideoFrameProcessingException` and returns the exception otherwise.

### from

```
java-static fun from(exception: Exception!, presentationTimeUs: Long): VideoFrameProcessingException!
```

Wraps the given exception in a `VideoFrameProcessingException` with the given timestamp if it is not already a `VideoFrameProcessingException` and returns the exception otherwise.

## Public properties

### presentationTimeUs

```
val presentationTimeUs: Long
```

The microsecond timestamp of the frame being processed while the exception occurred or `https://developer.android.com/reference/kotlin/androidx/media3/common/C#TIME_UNSET()` if unknown.