Fix #126749: HIP-RT Memory leak in Cycles viewport

hiprtScene object wasn't being freed between frames.

Pull Request: https://projects.blender.org/blender/blender/pulls/127473
This commit is contained in:
salipourto
2024-09-12 15:05:08 +02:00
committed by Sergey Sharybin
parent 610cf11bee
commit 4bfee1936c

View File

@@ -1089,6 +1089,9 @@ void HIPRTDevice::build_bvh(BVH *bvh, Progress &progress, bool refit)
else {
const vector<Object *> objects = bvh_rt->objects;
if (scene) {
hiprtDestroyScene(hiprt_context, scene);
}
scene = build_tlas(bvh_rt, objects, options, refit);
}
}