[Bf-blender-cvs] [532b33973bb] master: Cycles: Tidy of KernelData patchup code
Michael Jones
noreply at git.blender.org
Wed Jun 22 23:38:02 CEST 2022
Commit: 532b33973bb71f91a5962c9f9c63ff26bf51bd67
Author: Michael Jones
Date: Wed Jun 22 22:36:33 2022 +0100
Branches: master
https://developer.blender.org/rB532b33973bb71f91a5962c9f9c63ff26bf51bd67
Cycles: Tidy of KernelData patchup code
Reviewed By: sergey
Differential Revision: https://developer.blender.org/D15267
===================================================================
M intern/cycles/device/metal/device_impl.mm
===================================================================
diff --git a/intern/cycles/device/metal/device_impl.mm b/intern/cycles/device/metal/device_impl.mm
index 0954f586d40..8edcd8d118d 100644
--- a/intern/cycles/device/metal/device_impl.mm
+++ b/intern/cycles/device/metal/device_impl.mm
@@ -627,7 +627,7 @@ void MetalDevice::const_copy_to(const char *name, void *host, size_t size)
{
if (strcmp(name, "data") == 0) {
assert(size == sizeof(KernelData));
- memcpy((uint8_t *)&launch_params + offsetof(KernelParamsMetal, data), host, size);
+ memcpy((uint8_t *)&launch_params.data, host, sizeof(KernelData));
return;
}
More information about the Bf-blender-cvs
mailing list