|
HDK
|
#include <RV_OGLInteropTextureBase.h>
Classes | |
| struct | SemaphoreSet |
Public Types | |
| enum | RV_OGLInteropOwner { RV_VULKAN, RV_OPENGL } |
Public Member Functions | |
| RV_OGLInteropTextureBase () | |
| virtual | ~RV_OGLInteropTextureBase () |
| void | setCurrentState (RV_OGLInteropOwner owner) |
| RV_VKImage * | getRvImage () |
| const RV_VKImage * | getRvImage () const |
| RV_VKImage * | getRvImageBinding () |
| virtual RE_Texture * | getRe ()=0 |
| RV_OGLInteropOwner | getCurrentRenderType () const |
| bool | isValidAlloc () const |
| SemaphoreSet | getGLToVkSemaphore () |
| SemaphoreSet | getVkToGLSemaphore () |
| bool | beginTransferToVk (RE_Render *r) |
| bool | finishTransferToVk (RV_Render *r) |
| bool | beginTransferToGL (RV_Render *r) |
| bool | finishTransferToGL (RE_Render *r) |
| bool | submitTransferToGL (RE_RenderContext r) |
| bool | submitTransferToVk (RE_RenderContext r) |
| bool | allocateImage (RV_Instance *inst, RV_ImageDim image_type, VkFormat format, size_t width, size_t height, size_t depth=1, int levels=1, int layers=1, int samples=1) |
| bool | checkImageParams (RV_Instance *inst, RV_ImageDim image_type, VkFormat format, size_t width, size_t height, size_t depth=1, int levels=1, int layers=1, int samples=1) |
Static Public Member Functions | |
| static RV_OGLInteropTexturePtr | create (RE_TextureDimension dim) |
Public Attributes | |
| enum RV_OGLInteropTextureBase::RV_OGLInteropOwner | myCurOwner |
Protected Member Functions | |
| bool | allocateResources (RV_Instance *inst, RE_Render *re, void *opt_mem_ptr, RV_ImageDim image_type, VkFormat format, size_t width, size_t height, size_t depth=1, int levels=1, int layers=1, int samples=1) |
| bool | assignMemory (RV_Instance *inst, VE_Memory *mem) |
| void | deleteImage (RV_Instance *inst) |
| bool | allocateSemaphores (RV_Instance *inst) |
| void | deleteSemaphores (RV_Instance *inst) |
| bool | importMemory (RE_Render *r) |
| bool | importOglSemaphores (RE_Render *r) |
| void | deleteMemory (RE_Render *r) |
| void | deleteOglSemaphores (RE_Render *r) |
| void | deleteMemoryHandle () |
| void | deleteSemaphoreHandles () |
Static Protected Member Functions | |
| static bool | queryMemoryHandleValid (RV_Instance *inst, RV_VKInteropImageCreateInfo *info) |
Protected Attributes | |
| UT_UniquePtr< RV_VKImage > | myRvImg |
| VE_Memory * | myRvMem |
| VkDeviceMemory | myVkMem = VK_NULL_HANDLE |
| VkDeviceSize | myMemSize = 0 |
| VkDeviceSize | myMemOffset = 0 |
| VkImage | myVkImg = VK_NULL_HANDLE |
| VkImageLayout | myLastLayout = VK_IMAGE_LAYOUT_UNDEFINED |
| VkAccessFlags | myLastAccess = 0 |
| VkPipelineStageFlags | myLastStage = 0 |
| std::atomic_bool | myIsTransferToGLWaiting = false |
| VkSemaphore | myVkSemVkToGL = VK_NULL_HANDLE |
| VkSemaphore | myVkSemGLToVk = VK_NULL_HANDLE |
| int | myRERenderID = -1 |
| handle | myShareSemVkToGL = 0 |
| handle | myShareSemGLToVk = 0 |
| GLuint | myOglSemVkToGL = 0 |
| GLuint | myOglSemGLToVk = 0 |
| handle | myShareMem = 0 |
| GLuint | myOglMem = 0 |
| GLuint | myOglID = 0 |
| UT_Array< uint8 > | myTransferBuffer |
Set of resources needed to share a texture between OpenGL and Vulkan. Can create a vulkan image, or recieve an alloacted memory. Creates semaphores for sync, and exports the handles for the memory and semaphores then imports them into an openGL context.
Definition at line 87 of file RV_OGLInteropTextureBase.h.
| Enumerator | |
|---|---|
| RV_VULKAN | |
| RV_OPENGL | |
Definition at line 97 of file RV_OGLInteropTextureBase.h.
| RV_OGLInteropTextureBase::RV_OGLInteropTextureBase | ( | ) |
|
virtual |
| bool RV_OGLInteropTextureBase::allocateImage | ( | RV_Instance * | inst, |
| RV_ImageDim | image_type, | ||
| VkFormat | format, | ||
| size_t | width, | ||
| size_t | height, | ||
| size_t | depth = 1, |
||
| int | levels = 1, |
||
| int | layers = 1, |
||
| int | samples = 1 |
||
| ) |
|
protected |
|
protected |
|
protected |
| bool RV_OGLInteropTextureBase::beginTransferToGL | ( | RV_Render * | r | ) |
| bool RV_OGLInteropTextureBase::beginTransferToVk | ( | RE_Render * | r | ) |
| bool RV_OGLInteropTextureBase::checkImageParams | ( | RV_Instance * | inst, |
| RV_ImageDim | image_type, | ||
| VkFormat | format, | ||
| size_t | width, | ||
| size_t | height, | ||
| size_t | depth = 1, |
||
| int | levels = 1, |
||
| int | layers = 1, |
||
| int | samples = 1 |
||
| ) |
|
static |
|
protected |
|
protected |
|
protected |
|
protected |
| bool RV_OGLInteropTextureBase::finishTransferToGL | ( | RE_Render * | r | ) |
| bool RV_OGLInteropTextureBase::finishTransferToVk | ( | RV_Render * | r | ) |
|
inline |
Definition at line 130 of file RV_OGLInteropTextureBase.h.
|
inline |
Definition at line 134 of file RV_OGLInteropTextureBase.h.
|
pure virtual |
|
inline |
Definition at line 114 of file RV_OGLInteropTextureBase.h.
|
inline |
Definition at line 119 of file RV_OGLInteropTextureBase.h.
|
inline |
Definition at line 124 of file RV_OGLInteropTextureBase.h.
|
inline |
Definition at line 143 of file RV_OGLInteropTextureBase.h.
|
protected |
|
protected |
|
inline |
Definition at line 132 of file RV_OGLInteropTextureBase.h.
|
staticprotected |
|
inline |
Definition at line 111 of file RV_OGLInteropTextureBase.h.
| bool RV_OGLInteropTextureBase::submitTransferToGL | ( | RE_RenderContext | r | ) |
| bool RV_OGLInteropTextureBase::submitTransferToVk | ( | RE_RenderContext | r | ) |
| enum RV_OGLInteropTextureBase::RV_OGLInteropOwner RV_OGLInteropTextureBase::myCurOwner |
|
protected |
Definition at line 217 of file RV_OGLInteropTextureBase.h.
|
protected |
Definition at line 210 of file RV_OGLInteropTextureBase.h.
|
protected |
Definition at line 209 of file RV_OGLInteropTextureBase.h.
|
protected |
Definition at line 211 of file RV_OGLInteropTextureBase.h.
|
protected |
Definition at line 206 of file RV_OGLInteropTextureBase.h.
|
protected |
Definition at line 205 of file RV_OGLInteropTextureBase.h.
|
protected |
Definition at line 249 of file RV_OGLInteropTextureBase.h.
|
protected |
Definition at line 248 of file RV_OGLInteropTextureBase.h.
|
protected |
Definition at line 243 of file RV_OGLInteropTextureBase.h.
|
protected |
Definition at line 242 of file RV_OGLInteropTextureBase.h.
|
protected |
Definition at line 235 of file RV_OGLInteropTextureBase.h.
|
protected |
Definition at line 201 of file RV_OGLInteropTextureBase.h.
|
protected |
Definition at line 202 of file RV_OGLInteropTextureBase.h.
|
protected |
Definition at line 245 of file RV_OGLInteropTextureBase.h.
|
protected |
Definition at line 239 of file RV_OGLInteropTextureBase.h.
|
protected |
Definition at line 238 of file RV_OGLInteropTextureBase.h.
Definition at line 254 of file RV_OGLInteropTextureBase.h.
|
protected |
Definition at line 207 of file RV_OGLInteropTextureBase.h.
|
protected |
Definition at line 204 of file RV_OGLInteropTextureBase.h.
|
protected |
Definition at line 230 of file RV_OGLInteropTextureBase.h.
|
protected |
Definition at line 229 of file RV_OGLInteropTextureBase.h.