diff options
author | Patrick Mours <pmours@nvidia.com> | 2021-01-05 16:39:29 +0300 |
---|---|---|
committer | Patrick Mours <pmours@nvidia.com> | 2021-01-05 19:59:38 +0300 |
commit | 166c0db3f9412925b501b7172875cb8ee2eb6958 (patch) | |
tree | 90b87b06a9039d67384888f86708e08bf3e8f9f9 /intern/cycles/render/geometry.h | |
parent | da9d471e1d9ac451929340cfe8aa5a8c5b268a75 (diff) |
Fix T83915: Subdivision Surface modifier causes visual artifacts in Cycles rendered viewport - CPU and OptiX
Changing the geometry in the current scene caused the primitive offsets for all geometry to
change, but the values would not be updated in all bottom-level BVH structures. Rendering
artifacts and crashes where the result. This fixes that by ensuring all BVH structures are
updated when the primitive offsets change.
Diffstat (limited to 'intern/cycles/render/geometry.h')
-rw-r--r-- | intern/cycles/render/geometry.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/intern/cycles/render/geometry.h b/intern/cycles/render/geometry.h index d3daf0cc809..b124e950ad2 100644 --- a/intern/cycles/render/geometry.h +++ b/intern/cycles/render/geometry.h @@ -157,6 +157,8 @@ class Geometry : public Node { /* Updates */ void tag_update(Scene *scene, bool rebuild); + + void tag_bvh_update(bool rebuild); }; /* Geometry Manager */ @@ -198,7 +200,7 @@ class GeometryManager { vector<AttributeRequestSet> &object_attributes); /* Compute verts/triangles/curves offsets in global arrays. */ - void mesh_calc_offset(Scene *scene); + void mesh_calc_offset(Scene *scene, BVHLayout bvh_layout); void device_update_object(Device *device, DeviceScene *dscene, Scene *scene, Progress &progress); |