# GPUHardwareBufferTexture

Artifact: [androidx.webgpu:webgpu](https://developer.android.com/jetpack/androidx/releases/webgpu) [View Source](https://cs.android.com/search?q=file:androidx/webgpu/GPUHardwareBufferTexture.kt+class:androidx.webgpu.GPUHardwareBufferTexture) Added in [1.0.0-alpha06](https://developer.android.com/jetpack/androidx/releases/webgpu#1.0.0-alpha06)

*** ** * ** ***


```
@ExperimentalWebGpuApi
class GPUHardwareBufferTexture : GPUHardwareBufferWrapper
```

<br />

|---|---|---|
| [kotlin.Any](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-any/index.html) |||
| ↳ | [androidx.webgpu.GPUHardwareBufferWrapper](https://developer.android.com/reference/kotlin/androidx/webgpu/GPUHardwareBufferWrapper) ||
|   | ↳ | [androidx.webgpu.GPUHardwareBufferTexture](https://developer.android.com/reference/kotlin/androidx/webgpu/GPUHardwareBufferTexture) |

*** ** * ** ***

## Summary

| ### Public constructors |
|---|
| `https://developer.android.com/reference/kotlin/androidx/webgpu/GPUHardwareBufferTexture#GPUHardwareBufferTexture(kotlin.Long,androidx.webgpu.GPUTexture)(handle: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html, texture: https://developer.android.com/reference/kotlin/androidx/webgpu/GPUTexture)` |

| ### Public functions |
|---|---|
| `open https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` | `https://developer.android.com/reference/kotlin/androidx/webgpu/GPUHardwareBufferTexture#close()()` |

| ### Public properties |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/webgpu/GPUTexture` | `https://developer.android.com/reference/kotlin/androidx/webgpu/GPUHardwareBufferTexture#texture()` |

### Inherited functions

From [androidx.webgpu.GPUHardwareBufferWrapper](https://developer.android.com/reference/kotlin/androidx/webgpu/GPUHardwareBufferWrapper) `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` `https://developer.android.com/reference/kotlin/androidx/webgpu/GPUHardwareBufferWrapper#beginAccess(kotlin.Array)(fences: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html<https://developer.android.com/reference/kotlin/androidx/webgpu/GPUSyncFence>?)`

Begins access to the hardware buffer, passing any wait fences to the native layer.
`https://developer.android.com/reference/kotlin/androidx/webgpu/GPUSyncFence?` `https://developer.android.com/reference/kotlin/androidx/webgpu/GPUHardwareBufferWrapper#endAccess()()`

Ends access to the hardware buffer, returning a signal fence from the native layer.
`external https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` `https://developer.android.com/reference/kotlin/androidx/webgpu/GPUHardwareBufferWrapper#nativeBeginAccess(kotlin.Long,kotlin.IntArray)(handle: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html, fences: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int-array/index.html?)` `external https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html` `https://developer.android.com/reference/kotlin/androidx/webgpu/GPUHardwareBufferWrapper#nativeDestroy(kotlin.Long)(handle: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html)` `external https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` `https://developer.android.com/reference/kotlin/androidx/webgpu/GPUHardwareBufferWrapper#nativeEndAccess(kotlin.Long)(handle: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html)`

## Public constructors

### GPUHardwareBufferTexture

Added in [1.0.0-alpha06](https://developer.android.com/jetpack/androidx/releases/webgpu#1.0.0-alpha06)

```
GPUHardwareBufferTexture(handle: Long, texture: GPUTexture)
```

## Public functions

### close

```
open fun close(): Unit
```

## Public properties

### texture

Added in [1.0.0-alpha06](https://developer.android.com/jetpack/androidx/releases/webgpu#1.0.0-alpha06)

```
val texture: GPUTexture
```