TOpenGLTexture

Textures.

Choose your operating system:

Windows

macOS

Linux

Inheritance Hierarchy

BaseType

FOpenGLTextureBase

TOpenGLTexture

References

Module

OpenGLDrv

Header

/Engine/Source/Runtime/OpenGLDrv/Public/OpenGLResources.h

Include

#include "OpenGLResources.h"

Syntax

template<typename BaseType>
class TOpenGLTexture :
    public BaseType,
    public FOpenGLTextureBase

Remarks

Textures.

Constructors

Name Description

Public function

TOpenGLTexture

(
    FOpenGLDynamicRHI* InOpenGLRHI,
    GLuint InResource,
    GLenum InTarget,
    GLenum InAttachment,
    uint32 InSizeX,
    uint32 InSizeY,
    uint32 InSizeZ,
    uint32 InNumMips,
    uint32 InNumSamples,
    uint32 InNumSamplesTileMem,
    uint32 InArraySize,
    EPixelFormat InFormat,
    bool bInCubemap,
    bool bInAllocatedStorage,
    ETextureCreateFlags InFlags,
    const FClearValueBinding& InClearV...
)

Initialization constructor.

Destructors

Name Description

Public function Virtual

~TOpenGLTexture()

Functions

Name Description

Public function

void

 

CloneViaCopyImage

(
    TOpenGLTexture* Src,
    uint32 InNumMips,
    int32 SrcOffset,
    int32 DstOffset
)

Clone texture from a source using CopyImageSubData

Public function

void

 

CloneViaPBO

(
    TOpenGLTexture* Src,
    uint32 InNumMips,
    int32 SrcOffset,
    int32 DstOffset
)

Clone texture from a source going via PBOs

Public function Const

bool

 

GetAllocatedStorageForMip

(
    uint32 MipIndex,
    uint32 FaceIndex
)

Accessors to mark whether or not we have allocated storage for each mip/face.

Public function

uint32

 

GetLockSize

(
    uint32 MipIndex,
    uint32 ArrayIndex,
    EResourceLockMode LockMode,
    uint32& DestStride
)

Returns the size of the memory block that is returned from Lock, threadsafe

Public function Virtual Const

void *

 

GetNativeResource()

FRHITexture override.

Public function Virtual

void *

 

GetTextureBaseRHI()

Public function Const

bool

 

IsCubemap()

Public function Const

bool

 

IsDynamic()

Accessors.

Public function Const

bool

 

IsStaging()

Public function

void *

 

Lock

(
    uint32 MipIndex,
    uint32 ArrayIndex,
    EResourceLockMode LockMode,
    uint32& DestStride
)

Locks one of the texture's mip-maps.

Public function

void

 

Resolve

(
    uint32 MipIndex,
    uint32 ArrayIndex
)

Resolved the specified face for a read Lock, for non-renderable, CPU readable surfaces this eliminates the readback inside Lock itself.

Public function

void

 

SetAllocatedStorage

(
    bool bInAllocatedStorage
)

Set allocated storage state for all mip/faces.

Public function

void

 

SetAllocatedStorageForMip

(
    uint32 MipIndex,
    uint32 FaceIndex
)

Public function

void

 

Unlock

(
    uint32 MipIndex,
    uint32 ArrayIndex
)

Unlocks a previously locked mip-map.

Overridden from FTextureEvictionInterface