Viskores
1.0
|
Viskores OpenGL Interoperability. More...
Namespaces | |
anari | |
cuda | |
Classes | |
class | BufferState |
Manages the state for transferring an ArrayHandle to opengl. More... | |
Functions | |
template<typename ValueType , class StorageTag , class DeviceAdapterTag > | |
void | TransferToOpenGL (const viskores::cont::ArrayHandle< ValueType, StorageTag > &handle, BufferState &state, DeviceAdapterTag) |
Manages transferring an ArrayHandle to opengl . More... | |
template<typename ValueType , typename StorageTag > | |
void | TransferToOpenGL (const viskores::cont::ArrayHandle< ValueType, StorageTag > &handle, BufferState &state) |
Manages transferring an ArrayHandle to opengl . More... | |
Viskores OpenGL Interoperability.
viskores::interop defines the publicly accessible API for interoperability between viskores and OpenGL.
void viskores::interop::TransferToOpenGL | ( | const viskores::cont::ArrayHandle< ValueType, StorageTag > & | handle, |
BufferState & | state | ||
) |
Manages transferring an ArrayHandle to opengl .
TransferToOpenGL
manages to transfer the contents of an ArrayHandle to OpenGL as efficiently as possible. Will use the given state
to determine what buffer handle to use, and the type to bind the buffer handle too. If the type of buffer hasn't been determined the transfer will use deduceAndSetBufferType to do so. Lastly state also holds on to per backend resources that allow for efficient updating to open gl
This function keeps the buffer as the active buffer of the input type.
This function will throw exceptions if the transfer wasn't possible
void viskores::interop::TransferToOpenGL | ( | const viskores::cont::ArrayHandle< ValueType, StorageTag > & | handle, |
BufferState & | state, | ||
DeviceAdapterTag | |||
) |
Manages transferring an ArrayHandle to opengl .
TransferToOpenGL
manages to transfer the contents of an ArrayHandle to OpenGL as efficiently as possible. Will use the given state
to determine what buffer handle to use, and the type to bind the buffer handle too. Lastly state also holds on to per backend resources that allow for efficient updating to open gl.
This function keeps the buffer as the active buffer of the input type.