# GetDirectBufferCapacity(IntPtr)

> Fetches and returns the capacity of the memory region referenced by the given direct java.nio.Buffer.

## Definition

* **Type:** Method
* **Namespace:** [UnityEngine](/engine/6000.0/script-reference/unityengine.md)
* **Assembly:** UnityEngine.AndroidJNIModule

```csharp
public static long GetDirectBufferCapacity(IntPtr buffer)
```

### Parameters

**** (\[IntPtr]\(https\://learn.microsoft.com/dotnet/api/system.intptr)):&#x20;

### Returns

| Type                                                        | Description |
| ----------------------------------------------------------- | ----------- |
| [long](https://learn.microsoft.com/dotnet/api/system.int64) |             |

### Remarks

Additional Resources: [Java Native Interface Specification (Oracle)](http://download.oracle.com/javase/1.5.0/docs/guide/jni/spec/jniTOC.html)
