# BufferInfo

# BufferInfo

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

*** ** * ** ***

Kotlin\|[Java](https://developer.android.com/reference/androidx/media3/muxer/BufferInfo "View this page in Java")

<br />

```
@UnstableApi
class BufferInfo
```

<br />

*** ** * ** ***

Contains metadata of a sample[ByteBuffer](https://developer.android.com/reference/java/nio/ByteBuffer.html).

## Summary

|                                                                                                                                                                                                                                                        ### Public constructors                                                                                                                                                                                                                                                        |
|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [BufferInfo](https://developer.android.com/reference/kotlin/androidx/media3/muxer/BufferInfo#BufferInfo(long,int,int))`(presentationTimeUs: `[Long](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html)`, size: `[Int](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)`, @`[C.BufferFlags](https://developer.android.com/reference/kotlin/androidx/media3/common/C.BufferFlags)` flags: `[Int](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)`)` Creates an instance. |

|                             ### Public properties                             |
|-------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [Int](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)   | `@`[C.BufferFlags](https://developer.android.com/reference/kotlin/androidx/media3/common/C.BufferFlags) [flags](https://developer.android.com/reference/kotlin/androidx/media3/muxer/BufferInfo#flags()) The buffer flags, which should be a combination of the`C.BUFFER_FLAG_*`. |
| [Long](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html) | [presentationTimeUs](https://developer.android.com/reference/kotlin/androidx/media3/muxer/BufferInfo#presentationTimeUs()) The presentation timestamp of sample (in microseconds).                                                                                                |
| [Int](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)   | [size](https://developer.android.com/reference/kotlin/androidx/media3/muxer/BufferInfo#size()) The amount of data (in bytes) in the buffer.                                                                                                                                       |

## Public constructors

### BufferInfo

```
BufferInfo(presentationTimeUs: Long, size: Int, @C.BufferFlags flags: Int)
```

Creates an instance.  

|                                                                                          Parameters                                                                                          |
|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------|
| `presentationTimeUs: `[Long](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html)                                                                                          | The presentation timestamp of sample (in microseconds).                  |
| `size: `[Int](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)                                                                                                          | The amount of data (in bytes) in the buffer.                             |
| `@`[C.BufferFlags](https://developer.android.com/reference/kotlin/androidx/media3/common/C.BufferFlags)` flags: `[Int](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html) | The buffer flags, which should be a combination of the`C.BUFFER_FLAG_*`. |

## Public properties

### flags

```
@C.BufferFlags
val flags: Int
```

The buffer flags, which should be a combination of the`C.BUFFER_FLAG_*`.  

### presentationTimeUs

```
val presentationTimeUs: Long
```

The presentation timestamp of sample (in microseconds).  

### size

```
val size: Int
```

The amount of data (in bytes) in the buffer.