Skip to content

LiteFX::Rendering::GraphicsDevice::computeAccelerationStructureSizes

computeAccelerationStructureSizes overloads

Synopses

Declared in <litefx/rendering.hpp>

Computes the required amount of device memory for an IBottomLevelAccelerationStructure.

[[dllimport, dllexport]] void computeAccelerationStructureSizes(
    IBottomLevelAccelerationStructure const& blas,
    UInt64& bufferSize,
    UInt64& scratchSize,
    bool forUpdate = false) const;

» more...

Computes the required amount of device memory for an ITopLevelAccelerationStructure.

[[dllimport, dllexport]] void computeAccelerationStructureSizes(
    ITopLevelAccelerationStructure const& tlas,
    UInt64& bufferSize,
    UInt64& scratchSize,
    bool forUpdate = false) const;

» more...

Computes the required amount of device memory for an IBottomLevelAccelerationStructure.

virtual void computeAccelerationStructureSizes(
    bottom_level_acceleration_structure_type const& blas,
    UInt64& bufferSize,
    UInt64& scratchSize,
    bool forUpdate = false) const = 0;

» more...

Computes the required amount of device memory for an ITopLevelAccelerationStructure.

virtual void computeAccelerationStructureSizes(
    top_level_acceleration_structure_type const& tlas,
    UInt64& bufferSize,
    UInt64& scratchSize,
    bool forUpdate = false) const = 0;

» more...

Parameters

NameDescription
blasThe bottom-level acceleration structure to compute the memory requirements for.
bufferSizeThe size of the acceleration structure buffer.
scratchSizeThe size of the scratch memory buffer.
forUpdateIf set to true, scratchSize will contain the amount of scratch memory required for an update.
tlasThe top-level acceleration structure to compute the memory requirements for.