FGPUSortManager

A manager that handles different GPU sort tasks.

Windows
MacOS
Linux

Inheritance Hierarchy

FRefCountedObject

FGPUSortManager

References

Module

Engine

Header

/Engine/Source/Runtime/Engine/Public/GPUSortManager.h

Include

#include "GPUSortManager.h"

Syntax

class FGPUSortManager : public FRefCountedObject

Remarks

A manager that handles different GPU sort tasks. Each task has different constraints about when the data can be generated and when the sorted results need to be available. The usecase involes registering a sort task through AddTask() and then initializing the sort data through the KeyGen callback. The sort manager can be enabled or disabled through "fx.AllowGPUSorting"

Constructors

Name Description

Public function

FGPUSortManager

(
    ERHIFeatureLevel::Type InFeatureLev...
)

Creates the sort manager, this is when the settings are configured.

Destructors

Name Description

Public function

~FGPUSortManager()

Functions

Name Description

Public function

bool

 

AddTask

(
    FAllocationInfo & OutInfo,
    int32 ValueCount,
    EGPUSortFlags TaskFlags
)

Add a GPU sort task to process this frame.

Public function

void

 

OnPostRenderOpaque

(
    FRHICommandListImmediate & RHICmdLi...
)

Callback that needs to be called in the rendering loop, after calls to FFXSystemInterface::PostRenderOpaque() are issued.

Public function

void

 

OnPreRender

(
    FRHICommandListImmediate & RHICmdLi...
)

Callback that needs to be called in the rendering loop, after calls to FFXSystemInterface::PreRender() are issued.

Public function

void

 

Register

(
    const FGPUSortKeyGenDelegate & Call...,
    EGPUSortFlags UsedFlags,
    const FName & InName
)

Register a client system into the sort manager.

Classes

Name

Description

Public struct

FAllocationInfo

Information about the bindings for a given sort task.

Public struct

FKeyGenInfo

A little helper to generate the batch element keys based on the number of elements in the batch and the sort precision.

Enums

Name

Description

Private enum

ESortBatchProcessingOrder

Defines the order in which sort batches are processed every frame.

Typedefs

Name

Description

FCallbackArray

FDynamicValueBufferArray

FSortBatchArray

Expected that few will be enough, since we only need severals batches when ESortBatchProcessingOrder::KeyGenAfterPreRenderAndSortAfterPostRenderOpaque.

FValueBufferArray

Select Skin
Light
Dark

Welcome to the new Unreal Engine 4 Documentation site!

We're working on lots of new features including a feedback system so you can tell us how we are doing. It's not quite ready for use in the wild yet, so head over to the Documentation Feedback forum to tell us about this page or call out any issues you are encountering in the meantime.

We'll be sure to let you know when the new system is up and running.

Post Feedback