MCPcopy Create free account
hub / github.com/KhronosGroup/Vulkan-Samples / get_device_address

Method get_device_address

framework/core/buffer.h:263–273  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

261
262template <vkb::BindingType bindingType>
263inline uint64_t Buffer<bindingType>::get_device_address() const
264{
265 if constexpr (bindingType == vkb::BindingType::Cpp)
266 {
267 return this->get_device().get_handle().getBufferAddressKHR({.buffer = this->get_handle()});
268 }
269 else
270 {
271 return static_cast<vk::Device>(this->get_device().get_handle()).getBufferAddressKHR({.buffer = static_cast<vk::Buffer>(this->get_handle())});
272 }
273}
274
275template <vkb::BindingType bindingType>
276inline typename Buffer<bindingType>::DeviceSizeType Buffer<bindingType>::get_size() const

Calls 1

get_handleMethod · 0.45

Tested by

no test coverage detected