ExternalTexture
Texture which displays the content of an external buffer.
Texture which displays the content of an external buffer.
Displays the content of an external buffer provided by the platform. Requires the OES_EGL_image_external(https://registry.khronos.org/OpenGL/extensions/OES/OES_EGL_image_external.txt) extension (OpenGL) or VK_ANDROID_external_memory_android_hardware_buffer(https://registry.khronos.org/vulkan/specs/1.1-extensions/html/vkspec.html#VK_ANDROID_external_memory_android_hardware_buffer) extension (Vulkan). Note: This is currently only supported in Android builds.
Declarations checked against C# SDK 1.0.0. Expand a name to see declarations and documentation.
Constructors1
ExternalTextureConstructor
public ExternalTexture();Properties1
SizeProperty
public Vector2 Size { get; set; }External texture size.
Methods3
GetExternalTextureIdulong
public ulong GetExternalTextureId();Returns the external texture ID.
Depending on your use case, you may need to pass this to platform APIs, for example, when creating an android.graphics.SurfaceTexture on Android.
ulongSetExternalBufferIdvoid
public void SetExternalBufferId(ulong externalBufferId);Sets the external buffer ID.
Depending on your use case, you may need to call this with data received from a platform API, for example, SurfaceTexture.getHardwareBuffer() on Android.
| Name | Type | Default |
|---|---|---|
externalBufferId | ulong | — |
SetSizevoid
public void SetSize(Vector2 size);| Name | Type | Default |
|---|---|---|
size | Vector2 | — |