![]() |
VR-Forces Developer's Guide
|
GPU op that allocates a GL texture name and uninitialised RGBA8 storage.
On execute(): glGenTextures, sets standard atlas texture parameters (NEAREST min, LINEAR mag, CLAMP_TO_EDGE wrap), glTexImage2D with null pixels, then writes the new GL name into the shared handle so a scenegraph face that holds the same shared_ptr can begin binding it on the next frame.

Public Member Functions | |
| DtTextureAllocOp (DtDe &de, std::shared_ptr< GLuint > handle, int width, int height) | |
| virtual void | execute () override |
| virtual unsigned int | textureByteCount () const override |
Public Member Functions inherited from makVrv::DtGlTextureOp | |
| DtGlTextureOp (const std::string &name, DtDe &de) | |
| virtual | ~DtGlTextureOp () |
| virtual void | execute (DtGpuArenaUploadState &uploadState) override |
Public Member Functions inherited from makVrv::DtGpuOperation | |
| DtGpuOperation (const std::string &name, DtDe &de) | |
| virtual | ~DtGpuOperation () |
Private Attributes | |
| std::shared_ptr< GLuint > | myHandle |
| int | myWidth |
| int | myHeight |
Additional Inherited Members | |
Protected Attributes inherited from makVrv::DtGpuOperation | |
| DtDe & | myDe |
| const std::string | myName |
| makVrv::DtTextureAllocOp::DtTextureAllocOp | ( | DtDe & | de, |
| std::shared_ptr< GLuint > | handle, | ||
| int | width, | ||
| int | height | ||
| ) |
Construct an allocation op.
| de | Engine context (passed to the base). |
| handle | Shared GL handle slot. Set to non-zero on successful execute(). |
| width | Texture width in pixels (must be > 0). |
| height | Texture height in pixels (must be > 0). |
|
overridevirtual |
Allocate the GL texture and write the new name into the shared handle.
Implements makVrv::DtGpuOperation.
|
private |
|
private |
|
private |