nvnDeviceCalculateAccelerationStructureMemoryRequirements Switch 2

Device

void nvnDeviceCalculateAccelerationStructureMemoryRequirements(NVNdevice* d, const void* info, u64* size, u64* scratch, u64* update_scratch)

Get the memory an acceleration structure needs: 0x10000 for each size (guess: made up, no ray tracing yet)

Parameters

ParameterTypeDescription
dNVNdevice*Pointer to the device, not read
infoconst void*Build info, not read
sizeu64*Pointer to where the structure's size goes, NULL is invalid
scratchu64*Pointer to where the build scratch size goes, NULL is invalid
update_scratchu64*Pointer to where the update scratch size goes, NULL is invalid
DriversSwitch 2 (NVN2)
Declarednvn.hook
Handlernvn_DeviceCalculateAccelerationStructureMemoryRequirements (nvn_object.c)

Types as nvn.hook writes them: i32, u32, i64, u64: integers of that many bits; f32: float; bool: NVNboolean; usize, isize: size_t, ptrdiff_t.


Made from ScarletNX's Sail at 166ad3910f80. nvn.h is h1k421's reconstruction (MIT); nvn.hook, the handlers and the format table ScarletNX's (GPL-3.0-or-later). The Switch 2 marks are the drivers' procedure tables (tools/manual/nvn-drivers.txt).