Skip to content

Commit 03ea0ea

Browse files
committed
Implements Device::create_acceleration_structure().
1 parent 1515e90 commit 03ea0ea

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

wgpu-hal/src/metal/device.rs

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1613,9 +1613,13 @@ impl crate::Device for super::Device {
16131613

16141614
unsafe fn create_acceleration_structure(
16151615
&self,
1616-
_desc: &crate::AccelerationStructureDescriptor,
1616+
descriptor: &crate::AccelerationStructureDescriptor,
16171617
) -> Result<super::AccelerationStructure, crate::DeviceError> {
1618-
unimplemented!()
1618+
// self.counters.acceleration_structures.add(1);
1619+
let device = self.shared.device.lock();
1620+
Ok(super::AccelerationStructure {
1621+
raw: device.new_acceleration_structure_with_size(descriptor.size),
1622+
})
16191623
}
16201624

16211625
unsafe fn destroy_acceleration_structure(

0 commit comments

Comments
 (0)