Navigation
API > API/Runtime > API/Runtime/Engine
| Name | FRawStaticIndexBuffer16or32 |
| Type | class |
| Header File | /Engine/Source/Runtime/Engine/Public/RawIndexBuffer.h |
| Include Path | #include "RawIndexBuffer.h" |
Syntax
template<typename INDEX_TYPE>
class FRawStaticIndexBuffer16or32 : public FRawStaticIndexBuffer16or32Interface
Inheritance Hierarchy
- FRenderResource → FIndexBuffer → FRawStaticIndexBuffer16or32Interface → FRawStaticIndexBuffer16or32
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FRawStaticIndexBuffer16or32
(
bool InNeedsCPUAccess |
Constructor | RawIndexBuffer.h |
Variables
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| CachedNumIndices | int32 | RawIndexBuffer.h | ||
| Indices | TResourceArray< INDEX_TYPE, INDEXBUFFER_ALIGNMENT > | RawIndexBuffer.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void AssignNewBuffer
(
const TArray< INDEX_TYPE >& Buffer |
RawIndexBuffer.h | ||
void CacheOptimize() |
Orders a triangle list for better vertex cache coherency. | RawIndexBuffer.h | |
FBufferRHIRef CreateRHIBuffer
(
FRHICommandListBase& RHICmdList |
Create an RHI index buffer with CPU data. | RawIndexBuffer.h | |
void InitRHIForStreaming
(
FRHIBuffer* IntermediateBuffer, |
Similar to Init/ReleaseRHI but only update existing SRV so references to the SRV stays valid | RawIndexBuffer.h | |
void ReleaseRHIForStreaming
(
FRHIResourceReplaceBatcher& Batcher |
RawIndexBuffer.h |
Overridden from FRawStaticIndexBuffer16or32Interface
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual int32 AddItem
(
uint32 Val |
RawIndexBuffer.h | ||
virtual void Empty
(
int32 Slack |
RawIndexBuffer.h | ||
virtual uint32 Get
(
uint32 Idx |
RawIndexBuffer.h | ||
virtual bool GetNeedsCPUAccess() |
The following methods are basically just accessors that allow us to hide the implementation by making the index array a private member | RawIndexBuffer.h | |
virtual FShaderResourceViewRHIRef GetOrCreateSRV
(
FRHICommandListBase& RHICmdList |
Allows for creating SRV on demand Note: consider cache the SRV locally if multiple compute tasks all need access to one in a single frame | RawIndexBuffer.h | |
virtual void * GetPointerTo
(
uint32 Idx |
RawIndexBuffer.h | ||
virtual int32 GetResourceDataSize() |
RawIndexBuffer.h | ||
virtual void Insert
(
int32 Idx, |
RawIndexBuffer.h | ||
virtual int32 Num() |
Number of indices (e.g. 4 triangles would result in 12 elements) | RawIndexBuffer.h | |
virtual void Remove
(
int32 Idx, |
RawIndexBuffer.h | ||
virtual void Serialize
(
FArchive& Ar |
Serializer for this class | RawIndexBuffer.h | |
virtual void SerializeMetaData
(
FArchive& Ar |
RawIndexBuffer.h | ||
virtual void SetMetaData
(
int32 InCachedNumIndices |
RawIndexBuffer.h |
Overridden from FRenderResource
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void InitRHI
(
FRHICommandListBase& RHICmdList |
Create the index buffer RHI resource and initialize its data | RawIndexBuffer.h | |
virtual void ReleaseRHI() |
RawIndexBuffer.h |